Re: [Intel-gfx] [PATCH] drm/i915: fix i386 build of 64b raw_uncore functions

2019-03-26 Thread Chris Wilson
Quoting Daniele Ceraolo Spurio (2019-03-26 23:38:17)
> When building with ARCH=i386, readq and writeq are not defined,
> resulting in:
> 
> intel_uncore.h: In function ‘__raw_uncore_read64’:
> intel_uncore.h:257:9: error: implicit declaration of function ‘readq’;
> did you mean ‘readl’? [-Werror=implicit-function-declaration]
>   return read##s__(uncore->regs + i915_mmio_reg_offset(reg)); \
>  ^
> 
> and:
> 
> intel_uncore.h: In function ‘__raw_uncore_write64’:
> intel_uncore.h:264:2: error: implicit declaration of function ‘writeq’;
> did you mean ‘writel’? [-Werror=implicit-function-declaration]
>   write##s__(val, uncore->regs + i915_mmio_reg_offset(reg)); \
>   ^
> 
> Add the io-64-nonatomic-lo-hi include to have readq and writeq available
> for all builds. This header internally includes linux/io.h, so the
> native readq and writeq definitions will be used when available.
> 
> Fixes: 6cc5ca768825 ("drm/i915: rename raw reg access functions")
> Signed-off-by: Daniele Ceraolo Spurio 
> Cc: Chris Wilson 
> Cc: Paulo Zanoni 
> ---
>  drivers/gpu/drm/i915/intel_uncore.h | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/gpu/drm/i915/intel_uncore.h 
> b/drivers/gpu/drm/i915/intel_uncore.h
> index 06762501e9ee..50d226f68753 100644
> --- a/drivers/gpu/drm/i915/intel_uncore.h
> +++ b/drivers/gpu/drm/i915/intel_uncore.h
> @@ -28,6 +28,7 @@
>  #include 
>  #include 
>  #include 
> +#include 

Yeah, can't see a better way as it does what we need for the fallback.

Reviewed-by: Chris Wilson 
-Chris
___
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

[Intel-gfx] [PATCH] drm/i915: fix i386 build of 64b raw_uncore functions

2019-03-26 Thread Daniele Ceraolo Spurio
When building with ARCH=i386, readq and writeq are not defined,
resulting in:

intel_uncore.h: In function ‘__raw_uncore_read64’:
intel_uncore.h:257:9: error: implicit declaration of function ‘readq’;
did you mean ‘readl’? [-Werror=implicit-function-declaration]
  return read##s__(uncore->regs + i915_mmio_reg_offset(reg)); \
 ^

and:

intel_uncore.h: In function ‘__raw_uncore_write64’:
intel_uncore.h:264:2: error: implicit declaration of function ‘writeq’;
did you mean ‘writel’? [-Werror=implicit-function-declaration]
  write##s__(val, uncore->regs + i915_mmio_reg_offset(reg)); \
  ^

Add the io-64-nonatomic-lo-hi include to have readq and writeq available
for all builds. This header internally includes linux/io.h, so the
native readq and writeq definitions will be used when available.

Fixes: 6cc5ca768825 ("drm/i915: rename raw reg access functions")
Signed-off-by: Daniele Ceraolo Spurio 
Cc: Chris Wilson 
Cc: Paulo Zanoni 
---
 drivers/gpu/drm/i915/intel_uncore.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/i915/intel_uncore.h 
b/drivers/gpu/drm/i915/intel_uncore.h
index 06762501e9ee..50d226f68753 100644
--- a/drivers/gpu/drm/i915/intel_uncore.h
+++ b/drivers/gpu/drm/i915/intel_uncore.h
@@ -28,6 +28,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include "i915_reg.h"
 
-- 
2.20.1

___
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx