ASoC: rt5682s: use 'static' qualifier
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Mon, 25 Oct 2021 18:59:27 +0000 (13:59 -0500)
committerMark Brown <broonie@kernel.org>
Wed, 27 Oct 2021 10:31:10 +0000 (11:31 +0100)
Sparse reports the following warnings:

sound/soc/codecs/rt5682s.c:44:12: error: symbol 'rt5682s_supply_names'
was not declared. Should it be static?

sound/soc/codecs/rt5682s.c:74:26: error: symbol 'rt5682s_reg' was not
declared. Should it be static?

sound/soc/codecs/rt5682s.c:2841:30: error: symbol
'rt5682s_aif1_dai_ops' was not declared. Should it be static?

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20211025185933.144327-3-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/rt5682s.c

index f6435b233a51366a75216ff48cddb966ef5fd5f8..470957fcad6b6bdf69a1565a94ee4c4c00acdc6d 100644 (file)
@@ -41,7 +41,7 @@ static const struct rt5682s_platform_data i2s_default_platform_data = {
        .dai_clk_names[RT5682S_DAI_BCLK_IDX] = "rt5682-dai-bclk",
 };
 
-const char *rt5682s_supply_names[RT5682S_NUM_SUPPLIES] = {
+static const char *rt5682s_supply_names[RT5682S_NUM_SUPPLIES] = {
        "AVDD",
        "MICVDD",
 };
@@ -71,7 +71,7 @@ static void rt5682s_apply_patch_list(struct rt5682s_priv *rt5682s,
                dev_warn(dev, "Failed to apply regmap patch: %d\n", ret);
 }
 
-const struct reg_default rt5682s_reg[] = {
+static const struct reg_default rt5682s_reg[] = {
        {0x0002, 0x8080},
        {0x0003, 0x0001},
        {0x0005, 0x0000},
@@ -2838,7 +2838,7 @@ static int rt5682s_resume(struct snd_soc_component *component)
 #define rt5682s_resume NULL
 #endif
 
-const struct snd_soc_dai_ops rt5682s_aif1_dai_ops = {
+static const struct snd_soc_dai_ops rt5682s_aif1_dai_ops = {
        .hw_params = rt5682s_hw_params,
        .set_fmt = rt5682s_set_dai_fmt,
        .set_tdm_slot = rt5682s_set_tdm_slot,