public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, Daniel Vetter <daniel@ffwll.ch>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915: simplify check for I915G/I945G in bit 6 swizzling detection
Date: Wed, 14 Dec 2016 15:22:35 +0200	[thread overview]
Message-ID: <87twa6r6g4.fsf@intel.com> (raw)
In-Reply-To: <20161214131415.GC29871@nuc-i3427.alporthouse.com>

On Wed, 14 Dec 2016, Chris Wilson <chris@chris-wilson.co.uk> wrote:
> On Wed, Dec 14, 2016 at 02:00:11PM +0100, Daniel Vetter wrote:
>> On Tue, Dec 13, 2016 at 01:10:59PM +0200, Jani Nikula wrote:
>> > c9c4b6f6c283 ("drm/i915: fix swizzle detection for gen3") added a
>> > complicated check for I915G/I945G. Pineview and other gen3 devices match
>> > IS_MOBILE() anyway. Simplify.
>> > 
>> > Cc: Daniel Vetter <daniel@ffwll.ch>
>> > Signed-off-by: Jani Nikula <jani.nikula@intel.com>
>> > ---
>> >  drivers/gpu/drm/i915/i915_gem_fence_reg.c | 3 +--
>> >  1 file changed, 1 insertion(+), 2 deletions(-)
>> > 
>> > diff --git a/drivers/gpu/drm/i915/i915_gem_fence_reg.c b/drivers/gpu/drm/i915/i915_gem_fence_reg.c
>> > index 09193cfb5d8b..e03983973252 100644
>> > --- a/drivers/gpu/drm/i915/i915_gem_fence_reg.c
>> > +++ b/drivers/gpu/drm/i915/i915_gem_fence_reg.c
>> > @@ -513,8 +513,7 @@ i915_gem_detect_bit_6_swizzle(struct drm_i915_private *dev_priv)
>> >  		swizzle_x = I915_BIT_6_SWIZZLE_NONE;
>> >  		swizzle_y = I915_BIT_6_SWIZZLE_NONE;
>> >  	} else if (IS_MOBILE(dev_priv) ||
>> > -		   (IS_GEN3(dev_priv) &&
>> > -		    !IS_G33(dev_priv) && !IS_PINEVIEW(dev_priv))) {
>> > +		   IS_I915G(dev_priv) || IS_I945G(dev_priv)) {
>> 
>> Seems to miss i915gm and i945gm. Hm, but then you mention those are
>> mobile. Then I guess it's a bikeshed, but at least a correct one.
>
> Considering the discussion over the last few days, I'd rather see
> IS_MOBILE() phased out and not relied upon even more.
> /bikeshed

I'm afraid I already pushed (thanks for the review Daniel).

Last I looked, IS_MOBILE() seems like difficult to untangle, and this is
not one of the hard spots. Simpler conditions should actually be
helpful.

BR,
Jani.



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

      reply	other threads:[~2016-12-14 13:22 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-13 11:10 [PATCH] drm/i915: simplify check for I915G/I945G in bit 6 swizzling detection Jani Nikula
2016-12-13 11:53 ` ✗ Fi.CI.BAT: failure for " Patchwork
2016-12-14 13:00 ` [PATCH] " Daniel Vetter
2016-12-14 13:14   ` Chris Wilson
2016-12-14 13:22     ` Jani Nikula [this message]

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=87twa6r6g4.fsf@intel.com \
    --to=jani.nikula@intel.com \
    --cc=chris@chris-wilson.co.uk \
    --cc=daniel@ffwll.ch \
    --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