diff mbox series

drm/i915: remove duplicate typedef for intel_wakeref_t

Message ID 20190522103505.2082-1-jani.nikula@intel.com (mailing list archive)
State New, archived
Headers show
Series drm/i915: remove duplicate typedef for intel_wakeref_t | expand

Commit Message

Jani Nikula May 22, 2019, 10:35 a.m. UTC
Fix the duplicate typedef for intel_wakeref_t leading to Clang build
issues. While at it, actually make the intel_runtime_pm.h header
self-contained, which was claimed in the commit being fixed.

Reported-by: Nathan Chancellor <natechancellor@gmail.com>
Cc: Nathan Chancellor <natechancellor@gmail.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
References: http://mid.mail-archive.com/20190521183850.GA9157@archlinux-epyc
References: https://travis-ci.com/ClangBuiltLinux/continuous-integration/jobs/201754420#L2435
Fixes: 0d5adc5f2f01 ("drm/i915: extract intel_runtime_pm.h from intel_drv.h")
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
---
 drivers/gpu/drm/i915/Makefile.header-test | 1 +
 drivers/gpu/drm/i915/intel_runtime_pm.h   | 8 +++++---
 2 files changed, 6 insertions(+), 3 deletions(-)

Comments

Chris Wilson May 22, 2019, 10:41 a.m. UTC | #1
Quoting Jani Nikula (2019-05-22 11:35:05)
> Fix the duplicate typedef for intel_wakeref_t leading to Clang build
> issues. While at it, actually make the intel_runtime_pm.h header
> self-contained, which was claimed in the commit being fixed.
> 
> Reported-by: Nathan Chancellor <natechancellor@gmail.com>
> Cc: Nathan Chancellor <natechancellor@gmail.com>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> References: http://mid.mail-archive.com/20190521183850.GA9157@archlinux-epyc
> References: https://travis-ci.com/ClangBuiltLinux/continuous-integration/jobs/201754420#L2435
> Fixes: 0d5adc5f2f01 ("drm/i915: extract intel_runtime_pm.h from intel_drv.h")
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
> ---
>  drivers/gpu/drm/i915/Makefile.header-test | 1 +
>  drivers/gpu/drm/i915/intel_runtime_pm.h   | 8 +++++---
>  2 files changed, 6 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/Makefile.header-test b/drivers/gpu/drm/i915/Makefile.header-test
> index 2ca4a5f..3a9663 100644
> --- a/drivers/gpu/drm/i915/Makefile.header-test
> +++ b/drivers/gpu/drm/i915/Makefile.header-test
> @@ -55,6 +55,7 @@ header_test := \
>         intel_pm.h \
>         intel_psr.h \
>         intel_quirks.h \
> +       intel_runtime_pm.h \
>         intel_sdvo.h \
>         intel_sideband.h \
>         intel_sprite.h \
> diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.h b/drivers/gpu/drm/i915/intel_runtime_pm.h
> index b964ca..0a4c4b 100644
> --- a/drivers/gpu/drm/i915/intel_runtime_pm.h
> +++ b/drivers/gpu/drm/i915/intel_runtime_pm.h
> @@ -6,12 +6,14 @@
>  #ifndef __INTEL_RUNTIME_PM_H__
>  #define __INTEL_RUNTIME_PM_H__
>  
> -#include <linux/stackdepot.h>
>  #include <linux/types.h>
>  
> -struct drm_i915_private;
> +#include "intel_display.h"
> +#include "intel_wakeref.h"

Heh, I was thinking the other way but whichever works :)

Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
-Chris
Nathan Chancellor May 22, 2019, 7:57 p.m. UTC | #2
On Wed, May 22, 2019 at 01:35:05PM +0300, Jani Nikula wrote:
> Fix the duplicate typedef for intel_wakeref_t leading to Clang build
> issues. While at it, actually make the intel_runtime_pm.h header
> self-contained, which was claimed in the commit being fixed.
> 
> Reported-by: Nathan Chancellor <natechancellor@gmail.com>
> Cc: Nathan Chancellor <natechancellor@gmail.com>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> References: http://mid.mail-archive.com/20190521183850.GA9157@archlinux-epyc
> References: https://travis-ci.com/ClangBuiltLinux/continuous-integration/jobs/201754420#L2435
> Fixes: 0d5adc5f2f01 ("drm/i915: extract intel_runtime_pm.h from intel_drv.h")
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>

Reviewed-by: Nathan Chancellor <natechancellor@gmail.com>
Tested-by: Nathan Chancellor <natechancellor@gmail.com>

> ---
>  drivers/gpu/drm/i915/Makefile.header-test | 1 +
>  drivers/gpu/drm/i915/intel_runtime_pm.h   | 8 +++++---
>  2 files changed, 6 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/Makefile.header-test b/drivers/gpu/drm/i915/Makefile.header-test
> index 2ca4a5f..3a9663 100644
> --- a/drivers/gpu/drm/i915/Makefile.header-test
> +++ b/drivers/gpu/drm/i915/Makefile.header-test
> @@ -55,6 +55,7 @@ header_test := \
>  	intel_pm.h \
>  	intel_psr.h \
>  	intel_quirks.h \
> +	intel_runtime_pm.h \
>  	intel_sdvo.h \
>  	intel_sideband.h \
>  	intel_sprite.h \
> diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.h b/drivers/gpu/drm/i915/intel_runtime_pm.h
> index b964ca..0a4c4b 100644
> --- a/drivers/gpu/drm/i915/intel_runtime_pm.h
> +++ b/drivers/gpu/drm/i915/intel_runtime_pm.h
> @@ -6,12 +6,14 @@
>  #ifndef __INTEL_RUNTIME_PM_H__
>  #define __INTEL_RUNTIME_PM_H__
>  
> -#include <linux/stackdepot.h>
>  #include <linux/types.h>
>  
> -struct drm_i915_private;
> +#include "intel_display.h"
> +#include "intel_wakeref.h"
>  
> -typedef depot_stack_handle_t intel_wakeref_t;
> +struct drm_i915_private;
> +struct drm_printer;
> +struct intel_encoder;
>  
>  enum i915_drm_suspend_mode {
>  	I915_DRM_SUSPEND_IDLE,
> -- 
> 2.20.1
>
Jani Nikula May 23, 2019, 12:49 p.m. UTC | #3
On Wed, 22 May 2019, Nathan Chancellor <natechancellor@gmail.com> wrote:
> On Wed, May 22, 2019 at 01:35:05PM +0300, Jani Nikula wrote:
>> Fix the duplicate typedef for intel_wakeref_t leading to Clang build
>> issues. While at it, actually make the intel_runtime_pm.h header
>> self-contained, which was claimed in the commit being fixed.
>> 
>> Reported-by: Nathan Chancellor <natechancellor@gmail.com>
>> Cc: Nathan Chancellor <natechancellor@gmail.com>
>> Cc: Chris Wilson <chris@chris-wilson.co.uk>
>> References: http://mid.mail-archive.com/20190521183850.GA9157@archlinux-epyc
>> References: https://travis-ci.com/ClangBuiltLinux/continuous-integration/jobs/201754420#L2435
>> Fixes: 0d5adc5f2f01 ("drm/i915: extract intel_runtime_pm.h from intel_drv.h")
>> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
>
> Reviewed-by: Nathan Chancellor <natechancellor@gmail.com>
> Tested-by: Nathan Chancellor <natechancellor@gmail.com>

Pushed to dinq, thanks for the reviews and testing.

BR,
Jani.

>
>> ---
>>  drivers/gpu/drm/i915/Makefile.header-test | 1 +
>>  drivers/gpu/drm/i915/intel_runtime_pm.h   | 8 +++++---
>>  2 files changed, 6 insertions(+), 3 deletions(-)
>> 
>> diff --git a/drivers/gpu/drm/i915/Makefile.header-test b/drivers/gpu/drm/i915/Makefile.header-test
>> index 2ca4a5f..3a9663 100644
>> --- a/drivers/gpu/drm/i915/Makefile.header-test
>> +++ b/drivers/gpu/drm/i915/Makefile.header-test
>> @@ -55,6 +55,7 @@ header_test := \
>>  	intel_pm.h \
>>  	intel_psr.h \
>>  	intel_quirks.h \
>> +	intel_runtime_pm.h \
>>  	intel_sdvo.h \
>>  	intel_sideband.h \
>>  	intel_sprite.h \
>> diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.h b/drivers/gpu/drm/i915/intel_runtime_pm.h
>> index b964ca..0a4c4b 100644
>> --- a/drivers/gpu/drm/i915/intel_runtime_pm.h
>> +++ b/drivers/gpu/drm/i915/intel_runtime_pm.h
>> @@ -6,12 +6,14 @@
>>  #ifndef __INTEL_RUNTIME_PM_H__
>>  #define __INTEL_RUNTIME_PM_H__
>>  
>> -#include <linux/stackdepot.h>
>>  #include <linux/types.h>
>>  
>> -struct drm_i915_private;
>> +#include "intel_display.h"
>> +#include "intel_wakeref.h"
>>  
>> -typedef depot_stack_handle_t intel_wakeref_t;
>> +struct drm_i915_private;
>> +struct drm_printer;
>> +struct intel_encoder;
>>  
>>  enum i915_drm_suspend_mode {
>>  	I915_DRM_SUSPEND_IDLE,
>> -- 
>> 2.20.1
>>
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/Makefile.header-test b/drivers/gpu/drm/i915/Makefile.header-test
index 2ca4a5f..3a9663 100644
--- a/drivers/gpu/drm/i915/Makefile.header-test
+++ b/drivers/gpu/drm/i915/Makefile.header-test
@@ -55,6 +55,7 @@  header_test := \
 	intel_pm.h \
 	intel_psr.h \
 	intel_quirks.h \
+	intel_runtime_pm.h \
 	intel_sdvo.h \
 	intel_sideband.h \
 	intel_sprite.h \
diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.h b/drivers/gpu/drm/i915/intel_runtime_pm.h
index b964ca..0a4c4b 100644
--- a/drivers/gpu/drm/i915/intel_runtime_pm.h
+++ b/drivers/gpu/drm/i915/intel_runtime_pm.h
@@ -6,12 +6,14 @@ 
 #ifndef __INTEL_RUNTIME_PM_H__
 #define __INTEL_RUNTIME_PM_H__
 
-#include <linux/stackdepot.h>
 #include <linux/types.h>
 
-struct drm_i915_private;
+#include "intel_display.h"
+#include "intel_wakeref.h"
 
-typedef depot_stack_handle_t intel_wakeref_t;
+struct drm_i915_private;
+struct drm_printer;
+struct intel_encoder;
 
 enum i915_drm_suspend_mode {
 	I915_DRM_SUSPEND_IDLE,