public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Jani Nikula <jani.nikula@intel.com>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915: make Pineview a platform of its own
Date: Wed, 7 Dec 2016 16:15:27 +0200	[thread overview]
Message-ID: <20161207141527.GL31595@intel.com> (raw)
In-Reply-To: <1481119608-7146-1-git-send-email-jani.nikula@intel.com>

On Wed, Dec 07, 2016 at 04:06:48PM +0200, Jani Nikula wrote:
> Pineview deserves to use its own platform enum (which was already added,
> unused, previously).
> 
> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
> 
> ---
> 
> The wrinkle here is that IS_G33() still has to match both G33 and
> Pineview. I'd prefer it if G33 *only* matched G33 and *not* Pineview. To
> fix this, the alternatives are to a) add an additional IS_FOO() that
> matches both, or b) replaces all references to IS_G33() with IS_G33() ||
> IS_PINEVIEW().

This would be in line with what we did for VLV vs. CHV. So I think it
would be OK.

> I don't like either, but I also don't like
> .is_pineview. We should reserve those for feature-ish things. Or just
> apply this and leave it at that. Opinions?
> ---
>  drivers/gpu/drm/i915/i915_drv.h | 6 +++---
>  drivers/gpu/drm/i915/i915_pci.c | 2 +-
>  2 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
> index 8daa4fb13b52..4236cdd25b32 100644
> --- a/drivers/gpu/drm/i915/i915_drv.h
> +++ b/drivers/gpu/drm/i915/i915_drv.h
> @@ -688,7 +688,6 @@ struct intel_csr {
>  
>  #define DEV_INFO_FOR_EACH_FLAG(func) \
>  	func(is_mobile); \
> -	func(is_pineview); \
>  	func(is_lp); \
>  	func(is_alpha_support); \
>  	/* Keep has_* in alphabetical order */ \
> @@ -2530,8 +2529,9 @@ intel_info(const struct drm_i915_private *dev_priv)
>  #define IS_G4X(dev_priv)	(IS_G45(dev_priv) || IS_GM45(dev_priv))
>  #define IS_PINEVIEW_G(dev_priv)	(INTEL_DEVID(dev_priv) == 0xa001)
>  #define IS_PINEVIEW_M(dev_priv)	(INTEL_DEVID(dev_priv) == 0xa011)
> -#define IS_PINEVIEW(dev_priv)	((dev_priv)->info.is_pineview)
> -#define IS_G33(dev_priv)	((dev_priv)->info.platform == INTEL_G33)
> +#define IS_PINEVIEW(dev_priv)	((dev_priv)->info.platform == INTEL_PINEVIEW)
> +#define IS_G33(dev_priv)	((dev_priv)->info.platform == INTEL_G33 || \
> +				 IS_PINEVIEW(dev_priv))
>  #define IS_IRONLAKE_M(dev_priv)	(INTEL_DEVID(dev_priv) == 0x0046)
>  #define IS_IVYBRIDGE(dev_priv)	((dev_priv)->info.platform == INTEL_IVYBRIDGE)
>  #define IS_IVB_GT1(dev_priv)	(INTEL_DEVID(dev_priv) == 0x0156 || \
> diff --git a/drivers/gpu/drm/i915/i915_pci.c b/drivers/gpu/drm/i915/i915_pci.c
> index f7ec6e944e09..93f50ef2a309 100644
> --- a/drivers/gpu/drm/i915/i915_pci.c
> +++ b/drivers/gpu/drm/i915/i915_pci.c
> @@ -141,7 +141,7 @@ static const struct intel_device_info intel_g33_info = {
>  
>  static const struct intel_device_info intel_pineview_info = {
>  	GEN3_FEATURES,
> -	.platform = INTEL_G33, .is_pineview = 1, .is_mobile = 1,
> +	.platform = INTEL_PINEVIEW, .is_mobile = 1,
>  	.has_hotplug = 1,
>  	.has_overlay = 1,
>  };
> -- 
> 2.1.4

-- 
Ville Syrjälä
Intel OTC
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2016-12-07 14:15 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-07 14:06 [PATCH] drm/i915: make Pineview a platform of its own Jani Nikula
2016-12-07 14:15 ` Ville Syrjälä [this message]
2016-12-07 16:45 ` ✗ Fi.CI.BAT: warning for " Patchwork
2016-12-07 18:44   ` Saarinen, Jani

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=20161207141527.GL31595@intel.com \
    --to=ville.syrjala@linux.intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@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