From 3a032c33fb70453494e0b143a93db61f859381ea Mon Sep 17 00:00:00 2001 From: Shardar Shariff Md Date: Tue, 1 Nov 2016 19:09:46 +0530 Subject: gpu: nvgpu: gp10b: define fuse macro depend on kernel version - Define fuse macros depending on kernel version as fuse offset got changed in K4.4 and for K4.4 fuse defines are defined in common header file (tegra-fuse.h) - Use fuse control read/write APIs when reading control registers for K4.4 Bug 200243956 Change-Id: I34dabd1a307d10010cb89ac6a5f1e3f5b177c0fc Signed-off-by: Shardar Shariff Md Reviewed-on: http://git-master/r/1245825 Reviewed-by: Terje Bergstrom Tested-by: Terje Bergstrom GVS: Gerrit_Virtual_Submit --- drivers/gpu/nvgpu/gp10b/hal_gp10b.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'drivers/gpu/nvgpu/gp10b/hal_gp10b.c') diff --git a/drivers/gpu/nvgpu/gp10b/hal_gp10b.c b/drivers/gpu/nvgpu/gp10b/hal_gp10b.c index 2699dd7a..f0137a70 100644 --- a/drivers/gpu/nvgpu/gp10b/hal_gp10b.c +++ b/drivers/gpu/nvgpu/gp10b/hal_gp10b.c @@ -15,6 +15,7 @@ #include #include +#include #include @@ -46,7 +47,9 @@ #include "gk20a/dbg_gpu_gk20a.h" #include "gk20a/css_gr_gk20a.h" +#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 4, 0) #define FUSE_OPT_PRIV_SEC_EN_0 0x264 +#endif #define PRIV_SECURITY_ENABLED 0x01 static struct gpu_ops gp10b_ops = { -- cgit v1.2.2