diff mbox series

[v2,2/3] scsi: core: Fix invisible definition compilation warning

Message ID 20230108224057.354438-3-beanhuo@iokpp.de
State New
Headers show
Series Several compilation warnings fixes for UFS Advanced RPMB | expand

Commit Message

Bean Huo Jan. 8, 2023, 10:40 p.m. UTC
From: Bean Huo <beanhuo@micron.com>

In 'include/ufs/ufshcd.h' file, 'enum dma_data_direction' will be used,
which is defined in linux/dma-direction.h, however, this header file is
not included in ufshcd.h, thus causing the following compilation warning:

"warning: ‘enum dma_data_direction’ declared inside parameter list will
not be visible outside of this definition or declaration"

Fix this warning by including 'linux/dma-direction.h'.

Fixes: 6ff265fc5ef6 ("scsi: ufs: core: bsg: Add advanced RPMB support in ufs_bsg")
Reported-by: Xiaosen He <quic_xiaosenh@quicinc.com>
Reported-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Bean Huo <beanhuo@micron.com>
---
 include/ufs/ufshcd.h | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/include/ufs/ufshcd.h b/include/ufs/ufshcd.h
index dd5912b4db77..e44a41abcc05 100644
--- a/include/ufs/ufshcd.h
+++ b/include/ufs/ufshcd.h
@@ -17,6 +17,7 @@ 
 #include <linux/blk-mq.h>
 #include <linux/devfreq.h>
 #include <linux/pm_runtime.h>
+#include <linux/dma-direction.h>
 #include <scsi/scsi_device.h>
 #include <ufs/unipro.h>
 #include <ufs/ufs.h>