From f116320137b0eb835bcbf704d34fc8f7880595d2 Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Fri, 31 Mar 2017 13:11:29 -0700 Subject: gpu: nvgpu: Add wrapper for linux/types.h Add wrapper header nvgpu/types.h. It checks if build is for Linux kernel and pulls in linux/types.h. Delete also all #includes for linux/types.h which are not strictly necessary, and change the remaining ones to use the new wrapper. JIRA NVGPU-13 Change-Id: I1ddfef0b0b9d840e3e41a62f69c7cb9148d2d5fa Signed-off-by: Terje Bergstrom Reviewed-on: http://git-master/r/1453371 Reviewed-by: mobile promotions Tested-by: mobile promotions --- drivers/gpu/nvgpu/include/nvgpu/bios.h | 2 +- drivers/gpu/nvgpu/include/nvgpu/types.h | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 drivers/gpu/nvgpu/include/nvgpu/types.h (limited to 'drivers/gpu/nvgpu/include') diff --git a/drivers/gpu/nvgpu/include/nvgpu/bios.h b/drivers/gpu/nvgpu/include/nvgpu/bios.h index 6fbf068c..edd4e08c 100644 --- a/drivers/gpu/nvgpu/include/nvgpu/bios.h +++ b/drivers/gpu/nvgpu/include/nvgpu/bios.h @@ -14,7 +14,7 @@ #ifndef NVGPU_BIOS_H #define NVGPU_BIOS_H -#include +#include struct gk20a; diff --git a/drivers/gpu/nvgpu/include/nvgpu/types.h b/drivers/gpu/nvgpu/include/nvgpu/types.h new file mode 100644 index 00000000..4bfdddb7 --- /dev/null +++ b/drivers/gpu/nvgpu/include/nvgpu/types.h @@ -0,0 +1,20 @@ +/* + * Copyright (c) 2017, NVIDIA CORPORATION. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms and conditions of the GNU General Public License, + * version 2, as published by the Free Software Foundation. + * + * This program is distributed in the hope it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for + * more details. + */ +#ifndef __NVGPU_TYPES_H__ +#define __NVGPU_TYPES_H__ + +#ifdef __KERNEL__ +#include +#endif + +#endif -- cgit v1.2.2