From: Jani Nikula <jani.nikula@intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH v2 2/2] drm/i915/bios: reduce the scope of some local variables in parse_ddi_port()
Date: Thu, 12 Apr 2018 12:29:42 +0300 [thread overview]
Message-ID: <87lgdsg4c9.fsf@intel.com> (raw)
In-Reply-To: <152345265763.13225.18014047201030023125@mail.alporthouse.com>
On Wed, 11 Apr 2018, Chris Wilson <chris@chris-wilson.co.uk> wrote:
> Quoting Jani Nikula (2018-04-11 14:15:19)
>> No functional changes.
>>
>> Cc: Chris Wilson <chris@chris-wilson.co.uk>
>> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
>> ---
>> drivers/gpu/drm/i915/intel_bios.c | 10 ++++------
>> 1 file changed, 4 insertions(+), 6 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/i915/intel_bios.c b/drivers/gpu/drm/i915/intel_bios.c
>> index 447b721c3be9..036307af8419 100644
>> --- a/drivers/gpu/drm/i915/intel_bios.c
>> +++ b/drivers/gpu/drm/i915/intel_bios.c
>> @@ -1215,10 +1215,8 @@ static void parse_ddi_port(struct drm_i915_private *dev_priv, enum port port,
>> {
>> struct child_device_config *it, *child = NULL;
>> struct ddi_vbt_port_info *info = &dev_priv->vbt.ddi_port_info[port];
>> - uint8_t hdmi_level_shift;
>> int i, j;
>> bool is_dvi, is_hdmi, is_dp, is_edp, is_crt;
>> - uint8_t aux_channel, ddc_pin;
>> /* Each DDI port can have more than one value on the "DVO Port" field,
>> * so look for all the possible values for each port.
>> */
>> @@ -1255,8 +1253,6 @@ static void parse_ddi_port(struct drm_i915_private *dev_priv, enum port port,
>> if (!child)
>> return;
>>
>> - aux_channel = child->aux_channel;
>> -
>> is_dvi = child->device_type & DEVICE_TYPE_TMDS_DVI_SIGNALING;
>> is_dp = child->device_type & DEVICE_TYPE_DISPLAYPORT_OUTPUT;
>> is_crt = child->device_type & DEVICE_TYPE_ANALOG_OUTPUT;
>> @@ -1302,6 +1298,8 @@ static void parse_ddi_port(struct drm_i915_private *dev_priv, enum port port,
>> DRM_DEBUG_KMS("Port %c is internal DP\n", port_name(port));
>>
>> if (is_dvi) {
>> + u8 ddc_pin;
>> +
>> ddc_pin = map_ddc_pin(dev_priv, child->ddc_pin);
>> if (intel_gmbus_is_valid_pin(dev_priv, ddc_pin)) {
>> info->alternate_ddc_pin = ddc_pin;
>> @@ -1314,14 +1312,14 @@ static void parse_ddi_port(struct drm_i915_private *dev_priv, enum port port,
>> }
>>
>> if (is_dp) {
>> - info->alternate_aux_channel = aux_channel;
>> + info->alternate_aux_channel = child->aux_channel;
>>
>> sanitize_aux_ch(dev_priv, port);
>> }
>>
>> if (bdb_version >= 158) {
>> /* The VBT HDMI level shift values match the table we have. */
>> - hdmi_level_shift = child->hdmi_level_shifter_value;
>> + u8 hdmi_level_shift = child->hdmi_level_shifter_value;
>
> checkpatch will ask for a \n,
Happily not, pushed as-is, thanks for the review.
BR,
Jani.
>
> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
> -Chris
--
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2018-04-12 9:28 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-11 13:15 [PATCH v2 1/2] drm/i915/bios: filter out invalid DDC pins from VBT child devices Jani Nikula
2018-04-11 13:15 ` [PATCH v2 2/2] drm/i915/bios: reduce the scope of some local variables in parse_ddi_port() Jani Nikula
2018-04-11 13:17 ` Chris Wilson
2018-04-12 9:29 ` Jani Nikula [this message]
2018-04-11 14:28 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [v2,1/2] drm/i915/bios: filter out invalid DDC pins from VBT child devices Patchwork
2018-04-11 14:44 ` ✓ Fi.CI.BAT: success " Patchwork
2018-04-11 18:12 ` ✓ Fi.CI.IGT: " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87lgdsg4c9.fsf@intel.com \
--to=jani.nikula@intel.com \
--cc=chris@chris-wilson.co.uk \
--cc=intel-gfx@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox