summaryrefslogtreecommitdiffstats
path: root/drivers/platform
diff options
context:
space:
mode:
authorHeikki Krogerus <heikki.krogerus@linux.intel.com>2021-03-29 13:50:41 +0300
committerWolfram Sang <wsa@kernel.org>2021-04-10 21:43:01 +0200
commit3a3438e594bf8b2d8fcfd11f3aa2a93e215b92b7 (patch)
treee2722b4dd32e127cc819abea374cc96e95174d27 /drivers/platform
parentdc317fb81b57ba36cd7e15c8bd98c3d6be013f5f (diff)
downloadlinux-stable-3a3438e594bf8b2d8fcfd11f3aa2a93e215b92b7.tar.gz
linux-stable-3a3438e594bf8b2d8fcfd11f3aa2a93e215b92b7.tar.bz2
linux-stable-3a3438e594bf8b2d8fcfd11f3aa2a93e215b92b7.zip
platform/x86: intel_cht_int33fe_microb: Constify the software node
Additional device properties are always just a part of a software fwnode. If the device properties are constant, the software node can also be constant. Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Reviewed-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Wolfram Sang <wsa@kernel.org>
Diffstat (limited to 'drivers/platform')
-rw-r--r--drivers/platform/x86/intel_cht_int33fe_microb.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/platform/x86/intel_cht_int33fe_microb.c b/drivers/platform/x86/intel_cht_int33fe_microb.c
index 20b11e0d9a75..673f41cd14b5 100644
--- a/drivers/platform/x86/intel_cht_int33fe_microb.c
+++ b/drivers/platform/x86/intel_cht_int33fe_microb.c
@@ -35,6 +35,10 @@ static const struct property_entry bq27xxx_props[] = {
{ }
};
+static const struct software_node bq27xxx_node = {
+ .properties = bq27xxx_props,
+};
+
int cht_int33fe_microb_probe(struct cht_int33fe_data *data)
{
struct device *dev = data->dev;
@@ -43,7 +47,7 @@ int cht_int33fe_microb_probe(struct cht_int33fe_data *data)
memset(&board_info, 0, sizeof(board_info));
strscpy(board_info.type, "bq27542", ARRAY_SIZE(board_info.type));
board_info.dev_name = "bq27542";
- board_info.properties = bq27xxx_props;
+ board_info.swnode = &bq27xxx_node;
data->battery_fg = i2c_acpi_new_device(dev, 1, &board_info);
return PTR_ERR_OR_ZERO(data->battery_fg);