All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ben Widawsky <ben@bwidawsk.net>
To: Kenneth Graunke <kenneth@whitecape.org>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] Update generation checks to provide basic support for Ivybridge.
Date: Wed, 08 Feb 2012 21:25:00 +0100	[thread overview]
Message-ID: <4F32DA1C.7050104@bwidawsk.net> (raw)
In-Reply-To: <1328731505-1212-1-git-send-email-kenneth@whitecape.org>

On 02/08/2012 09:05 PM, Kenneth Graunke wrote:
> There may be some updates required, but assuming Ivybridge is similar to
> Sandybridge is a decent start; previously it fell through to the Gen2/3
> case and nothing worked.

I didn't think anyone actually used this register map... so I never
bothered to update it myself :-).

For the record, I bet if I did this someone would yell at me that this
should be two patches, since you also moved to the new intel_gen stuff.
But you're definitely cooler than me.

> 
> Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ben Widawsky <ben@bwidawsk.net>

> ---
>  lib/intel_reg_map.c |    5 +++--
>  1 files changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/lib/intel_reg_map.c b/lib/intel_reg_map.c
> index 86cf9a6..0c8d49c 100644
> --- a/lib/intel_reg_map.c
> +++ b/lib/intel_reg_map.c
> @@ -128,14 +128,15 @@ struct intel_register_map
>  intel_get_register_map(uint32_t devid)
>  {
>  	struct intel_register_map map;
> +	const int gen = intel_gen(devid);
>  
> -	if (IS_GEN6(devid)) {
> +	if (gen >= 6) {
>  		map.map = gen6_gt_register_map;
>  		map.top = 0x180000;
>  	} else if (IS_BROADWATER(devid) || IS_CRESTLINE(devid)) {
>  		map.map = gen_bwcl_register_map;
>  		map.top = 0x80000;
> -	} else if (IS_GEN4(devid) || IS_GEN5(devid)) {
> +	} else if (gen >= 4) {
>  		map.map = gen4_register_map;
>  		map.top = 0x80000;
>  	} else {

  reply	other threads:[~2012-02-08 20:26 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-08 20:05 [PATCH] Update generation checks to provide basic support for Ivybridge Kenneth Graunke
2012-02-08 20:25 ` Ben Widawsky [this message]
2012-02-08 20:38 ` Daniel Vetter

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=4F32DA1C.7050104@bwidawsk.net \
    --to=ben@bwidawsk.net \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=kenneth@whitecape.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.