Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@intel.com>
To: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>,
	intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 6/6] drm/i915: rename dev_priv info to __info to avoid usage
Date: Wed, 02 Jan 2019 12:44:36 +0200	[thread overview]
Message-ID: <87ftubl4ob.fsf@intel.com> (raw)
In-Reply-To: <15697264-c655-2134-86e5-48dcb5d8efe3@linux.intel.com>

On Wed, 02 Jan 2019, Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> wrote:
> On 31/12/2018 14:56, Jani Nikula wrote:
>> Encourage use of INTEL_INFO() to access dev_priv->info to not accumulate
>> more direct users of ->info, making further changes easier.
>> 
>> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
>> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
>> ---
>>   drivers/gpu/drm/i915/i915_drv.h | 10 ++--------
>>   1 file changed, 2 insertions(+), 8 deletions(-)
>> 
>> diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
>> index ce8d7a97e26b..18e67aaef764 100644
>> --- a/drivers/gpu/drm/i915/i915_drv.h
>> +++ b/drivers/gpu/drm/i915/i915_drv.h
>> @@ -1431,7 +1431,7 @@ struct drm_i915_private {
>>   	struct kmem_cache *dependencies;
>>   	struct kmem_cache *priorities;
>>   
>> -	const struct intel_device_info info;
>> +	const struct intel_device_info __info; /* Use INTEL_INFO() to access. */
>>   	struct intel_runtime_info __runtime; /* Use RUNTIME_INFO() to access. */
>>   	struct intel_driver_caps caps;
>>   
>> @@ -2192,13 +2192,7 @@ static inline unsigned int i915_sg_segment_size(void)
>>   	return size;
>>   }
>>   
>> -static inline const struct intel_device_info *
>> -intel_info(const struct drm_i915_private *dev_priv)
>> -{
>> -	return &dev_priv->info;
>> -}
>> -
>
> What was this helper for, who remembers? :)

Didn't dig through the git logs, but I presume it's a leftover from the
days we were migrating to subclassing drm_device in drm_i915_private...

BR,
Jani.


>
> Regards,
>
> Tvrtko
>
>> -#define INTEL_INFO(dev_priv)	intel_info((dev_priv))
>> +#define INTEL_INFO(dev_priv)	(&(dev_priv)->__info)
>>   #define RUNTIME_INFO(dev_priv)	(&(dev_priv)->__runtime)
>>   #define DRIVER_CAPS(dev_priv)	(&(dev_priv)->caps)
>>   
>> 
>

-- 
Jani Nikula, Intel Open Source Graphics Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2019-01-02 10:44 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-31 14:56 [PATCH 0/6] drm/i915: start splitting off runtime device info Jani Nikula
2018-12-31 14:56 ` [PATCH 1/6] drm/i915: start moving runtime device info to a separate struct Jani Nikula
2019-01-02  9:27   ` Tvrtko Ursulin
2019-01-02 10:21     ` Jani Nikula
2018-12-31 14:56 ` [PATCH 2/6] drm/i915/reg: abstract display_mmio_offset access Jani Nikula
2019-01-02  9:37   ` Tvrtko Ursulin
2018-12-31 14:56 ` [PATCH 3/6] drm/i915: pass dev_priv to intel_device_info_runtime_init() Jani Nikula
2019-01-02  9:38   ` Tvrtko Ursulin
2018-12-31 14:56 ` [PATCH 4/6] drm/i915: always use INTEL_INFO() to access device info Jani Nikula
2019-01-02  9:58   ` Tvrtko Ursulin
2018-12-31 14:56 ` [PATCH 5/6] drm/i915: drop intel_device_info_dump() Jani Nikula
2019-01-02 10:02   ` Tvrtko Ursulin
2019-01-02 10:42     ` Jani Nikula
2019-01-02 11:09       ` Tvrtko Ursulin
2018-12-31 14:56 ` [PATCH 6/6] drm/i915: rename dev_priv info to __info to avoid usage Jani Nikula
2019-01-02 10:04   ` Tvrtko Ursulin
2019-01-02 10:44     ` Jani Nikula [this message]
2019-01-02 11:10       ` Tvrtko Ursulin
2018-12-31 15:07 ` ✗ Fi.CI.CHECKPATCH: warning for drm/i915: start splitting off runtime device info Patchwork
2018-12-31 15:10 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-12-31 15:43 ` ✓ Fi.CI.BAT: success " Patchwork
2018-12-31 17:53 ` ✓ Fi.CI.IGT: " Patchwork
2019-01-01 10:31 ` [PATCH 0/6] " Chris Wilson
2019-01-02  9:13   ` Jani Nikula
2019-01-02 10:17     ` Tvrtko Ursulin
2019-01-02 11:19       ` Jani Nikula

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=87ftubl4ob.fsf@intel.com \
    --to=jani.nikula@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=tvrtko.ursulin@linux.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