Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@linux.intel.com>
To: Rodrigo Vivi <rodrigo.vivi@intel.com>, Nirmoy Das <nirmoy.das@intel.com>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH] drm/i915: Remove unused variable
Date: Thu, 19 Jan 2023 11:21:36 +0200	[thread overview]
Message-ID: <878rhydgm7.fsf@intel.com> (raw)
In-Reply-To: <Y8g7zhs8DXmMZbSA@intel.com>

On Wed, 18 Jan 2023, Rodrigo Vivi <rodrigo.vivi@intel.com> wrote:
> On Wed, Jan 18, 2023 at 06:06:24PM +0100, Nirmoy Das wrote:
>> Removed unused i915 var.
>> 
>> Fixes: a273e95721e9 ("drm/i915: Allow switching away via vga-switcheroo if uninitialized")
>> Signed-off-by: Nirmoy Das <nirmoy.das@intel.com>
>
> Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
>
> and pushed to drm-misc-fixes.
>
> Thanks for the patch.

I guess this was a quick fix to avoid warnings about it.

But really, for i915 the way to go would be to have i915 local var, and
pass that around instead of struct drm_device *dev.

BR,
Jani.


>
>> ---
>>  drivers/gpu/drm/i915/i915_driver.c | 2 --
>>  1 file changed, 2 deletions(-)
>> 
>> diff --git a/drivers/gpu/drm/i915/i915_driver.c b/drivers/gpu/drm/i915/i915_driver.c
>> index 33e231b120c1..6469c7c1e154 100644
>> --- a/drivers/gpu/drm/i915/i915_driver.c
>> +++ b/drivers/gpu/drm/i915/i915_driver.c
>> @@ -1071,8 +1071,6 @@ static int i915_driver_open(struct drm_device *dev, struct drm_file *file)
>>   */
>>  static void i915_driver_lastclose(struct drm_device *dev)
>>  {
>> -	struct drm_i915_private *i915 = to_i915(dev);
>> -
>>  	intel_fbdev_restore_mode(dev);
>>  
>>  	vga_switcheroo_process_delayed_switch();
>> -- 
>> 2.39.0
>> 

-- 
Jani Nikula, Intel Open Source Graphics Center

  parent reply	other threads:[~2023-01-19  9:21 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-18 17:06 [Intel-gfx] [PATCH] drm/i915: Remove unused variable Nirmoy Das
2023-01-18 18:34 ` Rodrigo Vivi
2023-01-18 18:39   ` Rodrigo Vivi
2023-01-19  9:21   ` Jani Nikula [this message]
2023-01-19  9:59     ` Das, Nirmoy
2023-01-19  0:45 ` [Intel-gfx] ✗ Fi.CI.SPARSE: warning for " Patchwork
2023-01-19  0:58 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2023-01-19 23:30 ` [Intel-gfx] ✓ 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=878rhydgm7.fsf@intel.com \
    --to=jani.nikula@linux.intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=nirmoy.das@intel.com \
    --cc=rodrigo.vivi@intel.com \
    /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