Message ID | 1308256588-8026-5-git-send-email-ajax@redhat.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Thu, 16 Jun 2011 16:36:27 -0400, Adam Jackson <ajax@redhat.com> wrote: > It's not wrong, but the text and the code describe different predicates > and my brain kept stumbling over it. > > Signed-off-by: Adam Jackson <ajax@redhat.com> > --- > drivers/gpu/drm/i915/intel_sdvo.c | 5 +---- > 1 files changed, 1 insertions(+), 4 deletions(-) > > diff --git a/drivers/gpu/drm/i915/intel_sdvo.c b/drivers/gpu/drm/i915/intel_sdvo.c > index 193919e..c2272f7 100644 > --- a/drivers/gpu/drm/i915/intel_sdvo.c > +++ b/drivers/gpu/drm/i915/intel_sdvo.c > @@ -1320,10 +1320,7 @@ intel_sdvo_tmds_sink_detect(struct drm_connector *connector) > if (edid) > break; > } > - /* > - * If we found the EDID on the other bus, > - * assume that is the correct DDC bus. > - */ > + How about? If we foudn the EDID on another bus, presume that is the correct DDC bus and keep using that bus for future queries. Otherwise, restore the original value. > if (edid == NULL) > intel_sdvo->ddc_bus = saved_ddc; > }
diff --git a/drivers/gpu/drm/i915/intel_sdvo.c b/drivers/gpu/drm/i915/intel_sdvo.c index 193919e..c2272f7 100644 --- a/drivers/gpu/drm/i915/intel_sdvo.c +++ b/drivers/gpu/drm/i915/intel_sdvo.c @@ -1320,10 +1320,7 @@ intel_sdvo_tmds_sink_detect(struct drm_connector *connector) if (edid) break; } - /* - * If we found the EDID on the other bus, - * assume that is the correct DDC bus. - */ + if (edid == NULL) intel_sdvo->ddc_bus = saved_ddc; }
It's not wrong, but the text and the code describe different predicates and my brain kept stumbling over it. Signed-off-by: Adam Jackson <ajax@redhat.com> --- drivers/gpu/drm/i915/intel_sdvo.c | 5 +---- 1 files changed, 1 insertions(+), 4 deletions(-)