[PATCH -next 1/8] dax/bus.c: Make dax_region_rwsem and dax_dev_rwsem static
From: Jinjie Ruan
Date: Mon Aug 19 2024 - 07:52:34 EST
The sparse tool complains as follows:
drivers/dax/bus.c:19:1: warning:
symbol 'dax_region_rwsem' was not declared. Should it be static?
drivers/dax/bus.c:25:1: warning:
symbol 'dax_dev_rwsem' was not declared. Should it be static?
These symbols are not used outside bus.c, so marks them static.
Signed-off-by: Jinjie Ruan <ruanjinjie@xxxxxxxxxx>
---
drivers/dax/bus.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/dax/bus.c b/drivers/dax/bus.c
index fde29e0ad68b..e783e14a99b2 100644
--- a/drivers/dax/bus.c
+++ b/drivers/dax/bus.c
@@ -16,13 +16,13 @@ static DEFINE_MUTEX(dax_bus_lock);
* All changes to the dax region configuration occur with this lock held
* for write.
*/
-DECLARE_RWSEM(dax_region_rwsem);
+static DECLARE_RWSEM(dax_region_rwsem);
/*
* All changes to the dax device configuration occur with this lock held
* for write.
*/
-DECLARE_RWSEM(dax_dev_rwsem);
+static DECLARE_RWSEM(dax_dev_rwsem);
#define DAX_NAME_LEN 30
struct dax_id {
--
2.34.1