Commit 9cc0590a authored by Jean Delvare's avatar Jean Delvare Committed by Mark Brown

regulator: mt6380: Fix unused array warning

With the following configuration options:
CONFIG_OF is not set
CONFIG_REGULATOR_MT6380=y
we get the following build warning:

  CC      drivers/regulator/mt6380-regulator.o
drivers/regulator/mt6380-regulator.c:322:34: warning: ‘mt6380_of_match’ defined but not used [-Wunused-const-variable=]

Fix this by annotating that array with __maybe_unused, as done in
various regulator drivers.
Signed-off-by: default avatarJean Delvare <jdelvare@suse.de>
Reported-by: default avatarkernel test robot <lkp@intel.com>
Link: https://lore.kernel.org/all/202207240252.ZY5hSCNB-lkp@intel.com/
Cc: Liam Girdwood <lgirdwood@gmail.com>
Cc: Mark Brown <broonie@kernel.org>
Cc: Matthias Brugger <matthias.bgg@gmail.com>
Cc: Chenglin Xu <chenglin.xu@mediatek.com>
Link: https://lore.kernel.org/r/20220727132637.76d6073f@endymion.delvareSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 4c7da374
......@@ -319,7 +319,7 @@ static const struct platform_device_id mt6380_platform_ids[] = {
};
MODULE_DEVICE_TABLE(platform, mt6380_platform_ids);
static const struct of_device_id mt6380_of_match[] = {
static const struct of_device_id __maybe_unused mt6380_of_match[] = {
{ .compatible = "mediatek,mt6380-regulator", },
{ /* sentinel */ },
};
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment