[RFC PATCH linux-platform-drivers-x86] platform/x86: po_is_pass_set can be static

From: kernel test robot
Date: Mon Nov 02 2020 - 00:16:41 EST



Fixes: e8a60aa7404b ("platform/x86: Introduce support for Systems Management Driver over WMI for Dell Systems")
Signed-off-by: kernel test robot <lkp@xxxxxxxxx>
---
passobj-attributes.c | 14 +++++++-------
sysman.c | 2 +-
2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/drivers/platform/x86/dell-wmi-sysman/passobj-attributes.c b/drivers/platform/x86/dell-wmi-sysman/passobj-attributes.c
index e6199fb748a95a..81562b178c9cdd 100644
--- a/drivers/platform/x86/dell-wmi-sysman/passobj-attributes.c
+++ b/drivers/platform/x86/dell-wmi-sysman/passobj-attributes.c
@@ -35,7 +35,7 @@ static ssize_t is_enabled_show(struct kobject *kobj, struct kobj_attribute *attr
return ret;
}

-struct kobj_attribute po_is_pass_set =
+static struct kobj_attribute po_is_pass_set =
__ATTR_RO(is_enabled);

static ssize_t current_password_store(struct kobject *kobj,
@@ -67,7 +67,7 @@ static ssize_t current_password_store(struct kobject *kobj,
return count;
}

-struct kobj_attribute po_current_password =
+static struct kobj_attribute po_current_password =
__ATTR_WO(current_password);

static ssize_t new_password_store(struct kobject *kobj,
@@ -96,15 +96,15 @@ static ssize_t new_password_store(struct kobject *kobj,
return ret ? ret : count;
}

-struct kobj_attribute po_new_password =
+static struct kobj_attribute po_new_password =
__ATTR_WO(new_password);

attribute_n_property_show(min_password_length, po);
-struct kobj_attribute po_min_pass_length =
+static struct kobj_attribute po_min_pass_length =
__ATTR_RO(min_password_length);

attribute_n_property_show(max_password_length, po);
-struct kobj_attribute po_max_pass_length =
+static struct kobj_attribute po_max_pass_length =
__ATTR_RO(max_password_length);

static ssize_t mechanism_show(struct kobject *kobj, struct kobj_attribute *attr,
@@ -113,7 +113,7 @@ static ssize_t mechanism_show(struct kobject *kobj, struct kobj_attribute *attr,
return sprintf(buf, "password\n");
}

-struct kobj_attribute po_mechanism =
+static struct kobj_attribute po_mechanism =
__ATTR_RO(mechanism);

static ssize_t role_show(struct kobject *kobj, struct kobj_attribute *attr,
@@ -126,7 +126,7 @@ static ssize_t role_show(struct kobject *kobj, struct kobj_attribute *attr,
return -EIO;
}

-struct kobj_attribute po_role =
+static struct kobj_attribute po_role =
__ATTR_RO(role);

static struct attribute *po_attrs[] = {
diff --git a/drivers/platform/x86/dell-wmi-sysman/sysman.c b/drivers/platform/x86/dell-wmi-sysman/sysman.c
index 3842575a6c189f..c6862c3e9b491a 100644
--- a/drivers/platform/x86/dell-wmi-sysman/sysman.c
+++ b/drivers/platform/x86/dell-wmi-sysman/sysman.c
@@ -255,7 +255,7 @@ static ssize_t wmi_sysman_attr_store(struct kobject *kobj, struct attribute *att
return ret;
}

-const struct sysfs_ops wmi_sysman_kobj_sysfs_ops = {
+static const struct sysfs_ops wmi_sysman_kobj_sysfs_ops = {
.show = wmi_sysman_attr_show,
.store = wmi_sysman_attr_store,
};