public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled
@ 2014-12-11 12:07 Michel Thierry
  2014-12-11 18:45 ` shuang.he
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Michel Thierry @ 2014-12-11 12:07 UTC (permalink / raw)
  To: intel-gfx

When execlists submission is enabled, try full ppgtt by default.

Note, this patch considers that execlist support has been enabled by
default on Gen8.

Signed-off-by: Michel Thierry <michel.thierry@intel.com>
---
 drivers/gpu/drm/i915/i915_gem_gtt.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
index 171f6ea..4ed3904 100644
--- a/drivers/gpu/drm/i915/i915_gem_gtt.c
+++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
@@ -40,8 +40,8 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
 
 	has_aliasing_ppgtt = INTEL_INFO(dev)->gen >= 6;
 	has_full_ppgtt = INTEL_INFO(dev)->gen >= 7;
-	if (IS_GEN8(dev))
-		has_full_ppgtt = false; /* XXX why? */
+	if (IS_GEN8(dev) && !i915.enable_execlists)
+		has_full_ppgtt = false; /* Only enforce with execlists */
 
 	/*
 	 * We don't allow disabling PPGTT for gen9+ as it's a requirement for
@@ -72,7 +72,10 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
 		return 0;
 	}
 
-	return has_aliasing_ppgtt ? 1 : 0;
+	if (INTEL_INFO(dev)->gen < 8)
+		return has_aliasing_ppgtt ? 1 : 0;
+	else
+		return has_full_ppgtt ? 2 : has_aliasing_ppgtt ? 1 : 0;
 }
 
 
-- 
2.1.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled
  2014-12-11 12:07 [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled Michel Thierry
@ 2014-12-11 18:45 ` shuang.he
  2014-12-15 10:11 ` Daniel Vetter
  2014-12-15 14:58 ` [PATCH v2] drm/i915: Use true PPGTT in Gen8+ when " Michel Thierry
  2 siblings, 0 replies; 11+ messages in thread
From: shuang.he @ 2014-12-11 18:45 UTC (permalink / raw)
  To: shuang.he, intel-gfx, michel.thierry

Tested-By: PRC QA PRTS (Patch Regression Test System Contact: shuang.he@intel.com)
-------------------------------------Summary-------------------------------------
Platform          Delta          drm-intel-nightly          Series Applied
PNV                                  364/364              364/364
ILK              +1-1              364/366              364/366
SNB                                  448/450              448/450
IVB                                  497/498              497/498
BYT                                  289/289              289/289
HSW                                  563/564              563/564
BDW                                  417/417              417/417
-------------------------------------Detailed-------------------------------------
Platform  Test                                drm-intel-nightly          Series Applied
*ILK  igt_gem_fenced_exec_thrash_no-spare-fences-busy      PASS(2, M26M37)      DMESG_WARN(1, M37)
 ILK  igt_kms_flip_wf_vblank-ts-check      DMESG_WARN(7, M26)PASS(23, M26M37)      PASS(1, M37)
Note: You need to pay more attention to line start with '*'
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled
  2014-12-11 12:07 [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled Michel Thierry
  2014-12-11 18:45 ` shuang.he
@ 2014-12-15 10:11 ` Daniel Vetter
  2014-12-15 12:47   ` Michel Thierry
  2014-12-15 14:58 ` [PATCH v2] drm/i915: Use true PPGTT in Gen8+ when " Michel Thierry
  2 siblings, 1 reply; 11+ messages in thread
From: Daniel Vetter @ 2014-12-15 10:11 UTC (permalink / raw)
  To: Michel Thierry; +Cc: intel-gfx

On Thu, Dec 11, 2014 at 12:07:18PM +0000, Michel Thierry wrote:
> When execlists submission is enabled, try full ppgtt by default.
> 
> Note, this patch considers that execlist support has been enabled by
> default on Gen8.
> 
> Signed-off-by: Michel Thierry <michel.thierry@intel.com>
> ---
>  drivers/gpu/drm/i915/i915_gem_gtt.c | 9 ++++++---
>  1 file changed, 6 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
> index 171f6ea..4ed3904 100644
> --- a/drivers/gpu/drm/i915/i915_gem_gtt.c
> +++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
> @@ -40,8 +40,8 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
>  
>  	has_aliasing_ppgtt = INTEL_INFO(dev)->gen >= 6;
>  	has_full_ppgtt = INTEL_INFO(dev)->gen >= 7;
> -	if (IS_GEN8(dev))
> -		has_full_ppgtt = false; /* XXX why? */
> +	if (IS_GEN8(dev) && !i915.enable_execlists)
> +		has_full_ppgtt = false; /* Only enforce with execlists */

Imo this has outlived it's usefulness - enable_ppgtt is an unsafe
parameter so everyone setting it themselves gets what they need.
Afair this was just because of the execlist depency on gen8 for ppgtt.
-Daniel

>  
>  	/*
>  	 * We don't allow disabling PPGTT for gen9+ as it's a requirement for
> @@ -72,7 +72,10 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
>  		return 0;
>  	}
>  
> -	return has_aliasing_ppgtt ? 1 : 0;
> +	if (INTEL_INFO(dev)->gen < 8)
> +		return has_aliasing_ppgtt ? 1 : 0;
> +	else
> +		return has_full_ppgtt ? 2 : has_aliasing_ppgtt ? 1 : 0;
>  }
>  
>  
> -- 
> 2.1.1
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled
  2014-12-15 10:11 ` Daniel Vetter
@ 2014-12-15 12:47   ` Michel Thierry
  2014-12-15 14:22     ` Daniel Vetter
  0 siblings, 1 reply; 11+ messages in thread
From: Michel Thierry @ 2014-12-15 12:47 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: intel-gfx


[-- Attachment #1.1: Type: text/plain, Size: 1534 bytes --]

On 12/15/2014 10:11 AM, Daniel Vetter wrote:
> On Thu, Dec 11, 2014 at 12:07:18PM +0000, Michel Thierry wrote:
>> When execlists submission is enabled, try full ppgtt by default.
>>
>> Note, this patch considers that execlist support has been enabled by
>> default on Gen8.
>>
>> Signed-off-by: Michel Thierry <michel.thierry@intel.com>
>> ---
>>   drivers/gpu/drm/i915/i915_gem_gtt.c | 9 ++++++---
>>   1 file changed, 6 insertions(+), 3 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
>> index 171f6ea..4ed3904 100644
>> --- a/drivers/gpu/drm/i915/i915_gem_gtt.c
>> +++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
>> @@ -40,8 +40,8 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
>>   
>>   	has_aliasing_ppgtt = INTEL_INFO(dev)->gen >= 6;
>>   	has_full_ppgtt = INTEL_INFO(dev)->gen >= 7;
>> -	if (IS_GEN8(dev))
>> -		has_full_ppgtt = false; /* XXX why? */
>> +	if (IS_GEN8(dev) && !i915.enable_execlists)
>> +		has_full_ppgtt = false; /* Only enforce with execlists */
> Imo this has outlived it's usefulness - enable_ppgtt is an unsafe
> parameter so everyone setting it themselves gets what they need.
> Afair this was just because of the execlist depency on gen8 for ppgtt.
> -Daniel
Not sure if I'm following you up on this...
The aim was to change the default value to _full_ only when execlists 
are also enable (after Thomas' patch).  In gen8, we don't want to have 
full ppgtt with legacy ring submission.


[-- Attachment #1.2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 5510 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled
  2014-12-15 12:47   ` Michel Thierry
@ 2014-12-15 14:22     ` Daniel Vetter
  2014-12-15 14:28       ` Daniel Vetter
  0 siblings, 1 reply; 11+ messages in thread
From: Daniel Vetter @ 2014-12-15 14:22 UTC (permalink / raw)
  To: Michel Thierry; +Cc: intel-gfx

On Mon, Dec 15, 2014 at 12:47:14PM +0000, Michel Thierry wrote:
> On 12/15/2014 10:11 AM, Daniel Vetter wrote:
> >On Thu, Dec 11, 2014 at 12:07:18PM +0000, Michel Thierry wrote:
> >>When execlists submission is enabled, try full ppgtt by default.
> >>
> >>Note, this patch considers that execlist support has been enabled by
> >>default on Gen8.
> >>
> >>Signed-off-by: Michel Thierry <michel.thierry@intel.com>
> >>---
> >>  drivers/gpu/drm/i915/i915_gem_gtt.c | 9 ++++++---
> >>  1 file changed, 6 insertions(+), 3 deletions(-)
> >>
> >>diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
> >>index 171f6ea..4ed3904 100644
> >>--- a/drivers/gpu/drm/i915/i915_gem_gtt.c
> >>+++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
> >>@@ -40,8 +40,8 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
> >>  	has_aliasing_ppgtt = INTEL_INFO(dev)->gen >= 6;
> >>  	has_full_ppgtt = INTEL_INFO(dev)->gen >= 7;
> >>-	if (IS_GEN8(dev))
> >>-		has_full_ppgtt = false; /* XXX why? */
> >>+	if (IS_GEN8(dev) && !i915.enable_execlists)
> >>+		has_full_ppgtt = false; /* Only enforce with execlists */
> >Imo this has outlived it's usefulness - enable_ppgtt is an unsafe
> >parameter so everyone setting it themselves gets what they need.
> >Afair this was just because of the execlist depency on gen8 for ppgtt.
> >-Daniel
> Not sure if I'm following you up on this...
> The aim was to change the default value to _full_ only when execlists are
> also enable (after Thomas' patch).  In gen8, we don't want to have full
> ppgtt with legacy ring submission.

Yeah I gotten confused. The comment is a bit misleading thought, maybe
"Full ppgtt needs execlist since otherwise the ctx switch can hang"?
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled
  2014-12-15 14:22     ` Daniel Vetter
@ 2014-12-15 14:28       ` Daniel Vetter
  2014-12-15 14:49         ` Michel Thierry
  0 siblings, 1 reply; 11+ messages in thread
From: Daniel Vetter @ 2014-12-15 14:28 UTC (permalink / raw)
  To: Michel Thierry; +Cc: intel-gfx

On Mon, Dec 15, 2014 at 03:22:08PM +0100, Daniel Vetter wrote:
> On Mon, Dec 15, 2014 at 12:47:14PM +0000, Michel Thierry wrote:
> > On 12/15/2014 10:11 AM, Daniel Vetter wrote:
> > >On Thu, Dec 11, 2014 at 12:07:18PM +0000, Michel Thierry wrote:
> > >>When execlists submission is enabled, try full ppgtt by default.
> > >>
> > >>Note, this patch considers that execlist support has been enabled by
> > >>default on Gen8.
> > >>
> > >>Signed-off-by: Michel Thierry <michel.thierry@intel.com>
> > >>---
> > >>  drivers/gpu/drm/i915/i915_gem_gtt.c | 9 ++++++---
> > >>  1 file changed, 6 insertions(+), 3 deletions(-)
> > >>
> > >>diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
> > >>index 171f6ea..4ed3904 100644
> > >>--- a/drivers/gpu/drm/i915/i915_gem_gtt.c
> > >>+++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
> > >>@@ -40,8 +40,8 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
> > >>  	has_aliasing_ppgtt = INTEL_INFO(dev)->gen >= 6;
> > >>  	has_full_ppgtt = INTEL_INFO(dev)->gen >= 7;
> > >>-	if (IS_GEN8(dev))
> > >>-		has_full_ppgtt = false; /* XXX why? */
> > >>+	if (IS_GEN8(dev) && !i915.enable_execlists)
> > >>+		has_full_ppgtt = false; /* Only enforce with execlists */
> > >Imo this has outlived it's usefulness - enable_ppgtt is an unsafe
> > >parameter so everyone setting it themselves gets what they need.
> > >Afair this was just because of the execlist depency on gen8 for ppgtt.
> > >-Daniel
> > Not sure if I'm following you up on this...
> > The aim was to change the default value to _full_ only when execlists are
> > also enable (after Thomas' patch).  In gen8, we don't want to have full
> > ppgtt with legacy ring submission.
> 
> Yeah I gotten confused. The comment is a bit misleading thought, maybe
> "Full ppgtt needs execlist since otherwise the ctx switch can hang"?

Actually I wasnt' confused: gen8+ has full ppgtt, like gen7. It's broken
without execlist though, so what we should do is just change the default
below. Otherwise if a user explicitly sets execlist=0 and ppgtt=2 we won't
obey that, which doesn't make sense - for isolating bugs this might be a
valid testcase (even when we know there's problems). So your patch should
do two things:
- Generally allow full ppgtt on gen8 - the current restriction doesn't
  make sense.
- Switch the default to full ppgtt when execlist is enabled on gen8+, leave
  the default to aliasing/disabled everywhere else as is.
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled
  2014-12-15 14:28       ` Daniel Vetter
@ 2014-12-15 14:49         ` Michel Thierry
  0 siblings, 0 replies; 11+ messages in thread
From: Michel Thierry @ 2014-12-15 14:49 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: intel-gfx


[-- Attachment #1.1: Type: text/plain, Size: 2653 bytes --]

On 12/15/2014 2:28 PM, Daniel Vetter wrote:
> On Mon, Dec 15, 2014 at 03:22:08PM +0100, Daniel Vetter wrote:
>> On Mon, Dec 15, 2014 at 12:47:14PM +0000, Michel Thierry wrote:
>>> On 12/15/2014 10:11 AM, Daniel Vetter wrote:
>>>> On Thu, Dec 11, 2014 at 12:07:18PM +0000, Michel Thierry wrote:
>>>>> When execlists submission is enabled, try full ppgtt by default.
>>>>>
>>>>> Note, this patch considers that execlist support has been enabled by
>>>>> default on Gen8.
>>>>>
>>>>> Signed-off-by: Michel Thierry <michel.thierry@intel.com>
>>>>> ---
>>>>>   drivers/gpu/drm/i915/i915_gem_gtt.c | 9 ++++++---
>>>>>   1 file changed, 6 insertions(+), 3 deletions(-)
>>>>>
>>>>> diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
>>>>> index 171f6ea..4ed3904 100644
>>>>> --- a/drivers/gpu/drm/i915/i915_gem_gtt.c
>>>>> +++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
>>>>> @@ -40,8 +40,8 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
>>>>>   	has_aliasing_ppgtt = INTEL_INFO(dev)->gen >= 6;
>>>>>   	has_full_ppgtt = INTEL_INFO(dev)->gen >= 7;
>>>>> -	if (IS_GEN8(dev))
>>>>> -		has_full_ppgtt = false; /* XXX why? */
>>>>> +	if (IS_GEN8(dev) && !i915.enable_execlists)
>>>>> +		has_full_ppgtt = false; /* Only enforce with execlists */
>>>> Imo this has outlived it's usefulness - enable_ppgtt is an unsafe
>>>> parameter so everyone setting it themselves gets what they need.
>>>> Afair this was just because of the execlist depency on gen8 for ppgtt.
>>>> -Daniel
>>> Not sure if I'm following you up on this...
>>> The aim was to change the default value to _full_ only when execlists are
>>> also enable (after Thomas' patch).  In gen8, we don't want to have full
>>> ppgtt with legacy ring submission.
>> Yeah I gotten confused. The comment is a bit misleading thought, maybe
>> "Full ppgtt needs execlist since otherwise the ctx switch can hang"?
> Actually I wasnt' confused: gen8+ has full ppgtt, like gen7. It's broken
> without execlist though, so what we should do is just change the default
> below. Otherwise if a user explicitly sets execlist=0 and ppgtt=2 we won't
> obey that, which doesn't make sense - for isolating bugs this might be a
> valid testcase (even when we know there's problems). So your patch should
> do two things:
> - Generally allow full ppgtt on gen8 - the current restriction doesn't
>    make sense.
> - Switch the default to full ppgtt when execlist is enabled on gen8+, leave
>    the default to aliasing/disabled everywhere else as is.
> -Daniel
Thanks for clarifying. I'll send a new patch.

-Michel


[-- Attachment #1.2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 5510 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [PATCH v2] drm/i915: Use true PPGTT in Gen8+ when execlists are enabled
  2014-12-11 12:07 [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled Michel Thierry
  2014-12-11 18:45 ` shuang.he
  2014-12-15 10:11 ` Daniel Vetter
@ 2014-12-15 14:58 ` Michel Thierry
  2014-12-15 15:08   ` Daniel Vetter
  2014-12-16  8:52   ` shuang.he
  2 siblings, 2 replies; 11+ messages in thread
From: Michel Thierry @ 2014-12-15 14:58 UTC (permalink / raw)
  To: intel-gfx

In Gen8+, full ppgtt needs execlist, otherwise the ctx switch can hang.

Also remove the current restriction, a user should be able to explicitly set
ppgtt=2.

Note, this patch considers that execlist support has been enabled by
default on Gen8.

v2: Remove non-default restriction and clarify comment (Daniel)

Cc: Daniel Vetter <daniel@ffwll.ch>
Signed-off-by: Michel Thierry <michel.thierry@intel.com>
---
 drivers/gpu/drm/i915/i915_gem_gtt.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
index 171f6ea..b64323b 100644
--- a/drivers/gpu/drm/i915/i915_gem_gtt.c
+++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
@@ -40,8 +40,6 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
 
 	has_aliasing_ppgtt = INTEL_INFO(dev)->gen >= 6;
 	has_full_ppgtt = INTEL_INFO(dev)->gen >= 7;
-	if (IS_GEN8(dev))
-		has_full_ppgtt = false; /* XXX why? */
 
 	/*
 	 * We don't allow disabling PPGTT for gen9+ as it's a requirement for
@@ -72,7 +70,10 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
 		return 0;
 	}
 
-	return has_aliasing_ppgtt ? 1 : 0;
+	if (INTEL_INFO(dev)->gen >= 8 && i915.enable_execlists)
+		return 2;
+	else
+		return has_aliasing_ppgtt ? 1 : 0;
 }
 
 
-- 
2.1.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH v2] drm/i915: Use true PPGTT in Gen8+ when execlists are enabled
  2014-12-15 14:58 ` [PATCH v2] drm/i915: Use true PPGTT in Gen8+ when " Michel Thierry
@ 2014-12-15 15:08   ` Daniel Vetter
  2014-12-15 15:32     ` Daniel Vetter
  2014-12-16  8:52   ` shuang.he
  1 sibling, 1 reply; 11+ messages in thread
From: Daniel Vetter @ 2014-12-15 15:08 UTC (permalink / raw)
  To: Michel Thierry; +Cc: intel-gfx

On Mon, Dec 15, 2014 at 02:58:00PM +0000, Michel Thierry wrote:
> In Gen8+, full ppgtt needs execlist, otherwise the ctx switch can hang.
> 
> Also remove the current restriction, a user should be able to explicitly set
> ppgtt=2.
> 
> Note, this patch considers that execlist support has been enabled by
> default on Gen8.
> 
> v2: Remove non-default restriction and clarify comment (Daniel)

Missing git add since there's no no comment any more?
-Daniel

> 
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Signed-off-by: Michel Thierry <michel.thierry@intel.com>
> ---
>  drivers/gpu/drm/i915/i915_gem_gtt.c | 7 ++++---
>  1 file changed, 4 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
> index 171f6ea..b64323b 100644
> --- a/drivers/gpu/drm/i915/i915_gem_gtt.c
> +++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
> @@ -40,8 +40,6 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
>  
>  	has_aliasing_ppgtt = INTEL_INFO(dev)->gen >= 6;
>  	has_full_ppgtt = INTEL_INFO(dev)->gen >= 7;
> -	if (IS_GEN8(dev))
> -		has_full_ppgtt = false; /* XXX why? */
>  
>  	/*
>  	 * We don't allow disabling PPGTT for gen9+ as it's a requirement for
> @@ -72,7 +70,10 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
>  		return 0;
>  	}
>  
> -	return has_aliasing_ppgtt ? 1 : 0;
> +	if (INTEL_INFO(dev)->gen >= 8 && i915.enable_execlists)
> +		return 2;
> +	else
> +		return has_aliasing_ppgtt ? 1 : 0;
>  }
>  
>  
> -- 
> 2.1.1
> 

-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH v2] drm/i915: Use true PPGTT in Gen8+ when execlists are enabled
  2014-12-15 15:08   ` Daniel Vetter
@ 2014-12-15 15:32     ` Daniel Vetter
  0 siblings, 0 replies; 11+ messages in thread
From: Daniel Vetter @ 2014-12-15 15:32 UTC (permalink / raw)
  To: Michel Thierry; +Cc: intel-gfx

On Mon, Dec 15, 2014 at 04:08:37PM +0100, Daniel Vetter wrote:
> On Mon, Dec 15, 2014 at 02:58:00PM +0000, Michel Thierry wrote:
> > In Gen8+, full ppgtt needs execlist, otherwise the ctx switch can hang.
> > 
> > Also remove the current restriction, a user should be able to explicitly set
> > ppgtt=2.
> > 
> > Note, this patch considers that execlist support has been enabled by
> > default on Gen8.
> > 
> > v2: Remove non-default restriction and clarify comment (Daniel)
> 
> Missing git add since there's no no comment any more?

Ok, Michel clarified on irc that he meant commit message. I've fixed that
up and merged the patch.
-Daniel

> -Daniel
> 
> > 
> > Cc: Daniel Vetter <daniel@ffwll.ch>
> > Signed-off-by: Michel Thierry <michel.thierry@intel.com>
> > ---
> >  drivers/gpu/drm/i915/i915_gem_gtt.c | 7 ++++---
> >  1 file changed, 4 insertions(+), 3 deletions(-)
> > 
> > diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
> > index 171f6ea..b64323b 100644
> > --- a/drivers/gpu/drm/i915/i915_gem_gtt.c
> > +++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
> > @@ -40,8 +40,6 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
> >  
> >  	has_aliasing_ppgtt = INTEL_INFO(dev)->gen >= 6;
> >  	has_full_ppgtt = INTEL_INFO(dev)->gen >= 7;
> > -	if (IS_GEN8(dev))
> > -		has_full_ppgtt = false; /* XXX why? */
> >  
> >  	/*
> >  	 * We don't allow disabling PPGTT for gen9+ as it's a requirement for
> > @@ -72,7 +70,10 @@ static int sanitize_enable_ppgtt(struct drm_device *dev, int enable_ppgtt)
> >  		return 0;
> >  	}
> >  
> > -	return has_aliasing_ppgtt ? 1 : 0;
> > +	if (INTEL_INFO(dev)->gen >= 8 && i915.enable_execlists)
> > +		return 2;
> > +	else
> > +		return has_aliasing_ppgtt ? 1 : 0;
> >  }
> >  
> >  
> > -- 
> > 2.1.1
> > 
> 
> -- 
> Daniel Vetter
> Software Engineer, Intel Corporation
> +41 (0) 79 365 57 48 - http://blog.ffwll.ch

-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH v2] drm/i915: Use true PPGTT in Gen8+ when execlists are enabled
  2014-12-15 14:58 ` [PATCH v2] drm/i915: Use true PPGTT in Gen8+ when " Michel Thierry
  2014-12-15 15:08   ` Daniel Vetter
@ 2014-12-16  8:52   ` shuang.he
  1 sibling, 0 replies; 11+ messages in thread
From: shuang.he @ 2014-12-16  8:52 UTC (permalink / raw)
  To: shuang.he, intel-gfx, michel.thierry

Tested-By: PRC QA PRTS (Patch Regression Test System Contact: shuang.he@intel.com)
-------------------------------------Summary-------------------------------------
Platform          Delta          drm-intel-nightly          Series Applied
PNV                                  366/366              366/366
ILK              +5                 360/366              365/366
SNB                                  448/450              448/450
IVB                                  497/498              497/498
BYT                                  289/289              289/289
HSW                                  563/564              563/564
BDW                                  417/417              417/417
-------------------------------------Detailed-------------------------------------
Platform  Test                                drm-intel-nightly          Series Applied
 ILK  igt_drv_suspend_fence-restore-untiled      DMESG_WARN(1, M26)PASS(7, M37M26)      PASS(1, M37)
 ILK  igt_kms_flip_bcs-flip-vs-modeset-interruptible      DMESG_WARN(1, M26)PASS(7, M37M26)      PASS(1, M37)
 ILK  igt_kms_flip_busy-flip-interruptible      DMESG_WARN(2, M26)PASS(6, M37M26)      PASS(1, M37)
 ILK  igt_kms_flip_flip-vs-rmfb-interruptible      DMESG_WARN(1, M26)PASS(7, M37M26)      PASS(1, M37)
 ILK  igt_kms_flip_rcs-flip-vs-dpms      DMESG_WARN(1, M26)PASS(6, M37M26)      PASS(1, M37)
Note: You need to pay more attention to line start with '*'
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2014-12-16  8:53 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-12-11 12:07 [PATCH] drm/i915: Use true PPGTT in Gen8 if execlists are enabled Michel Thierry
2014-12-11 18:45 ` shuang.he
2014-12-15 10:11 ` Daniel Vetter
2014-12-15 12:47   ` Michel Thierry
2014-12-15 14:22     ` Daniel Vetter
2014-12-15 14:28       ` Daniel Vetter
2014-12-15 14:49         ` Michel Thierry
2014-12-15 14:58 ` [PATCH v2] drm/i915: Use true PPGTT in Gen8+ when " Michel Thierry
2014-12-15 15:08   ` Daniel Vetter
2014-12-15 15:32     ` Daniel Vetter
2014-12-16  8:52   ` shuang.he

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox