tee: add forward declaration for struct device
authorJerome Forissier <jerome.forissier@linaro.org>
Wed, 31 May 2017 08:50:27 +0000 (10:50 +0200)
committerNitin Garg <nitin.garg@nxp.com>
Mon, 19 Mar 2018 20:55:39 +0000 (15:55 -0500)
tee_drv.h references struct device, but does not include device.h nor
platform_device.h. Therefore, if tee_drv.h is included by some file
that does not pull device.h nor platform_device.h beforehand, we have a
compile warning. Fix this by adding a forward declaration.

Submitted upstream, see link below.

Link: http://lists.infradead.org/pipermail/linux-arm-kernel/2017-May/509790.html
Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org>
Reviewed-by: Joakim Bech <joakim.bech@linaro.org>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
(cherry picked from commit 2e26af92fd860371fd65a2c16306cce4508285a1)

include/linux/tee_drv.h

index 8614713..07bd226 100644 (file)
@@ -29,6 +29,7 @@
 #define TEE_SHM_DMA_BUF                BIT(1)  /* Memory with dma-buf handle */
 #define TEE_SHM_EXT_DMA_BUF    BIT(2)  /* Memory with dma-buf handle */
 
+struct device;
 struct tee_device;
 struct tee_shm;
 struct tee_shm_pool;