]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commitdiff
iio: light: make a couple of config structures static
authorColin Ian King <colin.king@canonical.com>
Mon, 4 Dec 2017 12:04:06 +0000 (12:04 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 8 Jan 2018 15:03:41 +0000 (16:03 +0100)
Structures st_uvis25_i2c_regmap_config and st_uvis25_spi_regmap_config are
local to the source and do not need to be in global scope, so make them
both static.

Cleans up sparse warnings:
warning: symbol 'st_uvis25_i2c_regmap_config' was not declared. Should
it be static?
warning: symbol 'st_uvis25_spi_regmap_config' was not declared. Should
it be static?

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/iio/light/st_uvis25_i2c.c
drivers/iio/light/st_uvis25_spi.c

index c939c0b0ff10c8258b7e970dfddcc177cc168b90..afd6eb01a202c8433ed2de2c91138759076e3728 100644 (file)
@@ -19,7 +19,7 @@
 
 #define UVIS25_I2C_AUTO_INCREMENT      BIT(7)
 
-const struct regmap_config st_uvis25_i2c_regmap_config = {
+static const struct regmap_config st_uvis25_i2c_regmap_config = {
        .reg_bits = 8,
        .val_bits = 8,
        .write_flag_mask = UVIS25_I2C_AUTO_INCREMENT,
index e697e14e7952f40c172ead3d34fd0f55572bb0f1..cdfee5e84d5e7346eaec24c85fb436377f20d7fb 100644 (file)
@@ -19,7 +19,7 @@
 #define UVIS25_SENSORS_SPI_READ                BIT(7)
 #define UVIS25_SPI_AUTO_INCREMENT      BIT(6)
 
-const struct regmap_config st_uvis25_spi_regmap_config = {
+static const struct regmap_config st_uvis25_spi_regmap_config = {
        .reg_bits = 8,
        .val_bits = 8,
        .read_flag_mask = UVIS25_SENSORS_SPI_READ | UVIS25_SPI_AUTO_INCREMENT,