mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-05 21:44:23 -04:00
ASoC: tegra: mark runtime-pm functions as __maybe_unused
A reorganization of the driver source led to two of them causing
a compile time warning in some configurations:
tegra/tegra20_spdif.c:36:12: error: 'tegra20_spdif_runtime_resume' defined but not used [-Werror=unused-function]
36 | static int tegra20_spdif_runtime_resume(struct device *dev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
tegra/tegra20_spdif.c:27:12: error: 'tegra20_spdif_runtime_suspend' defined but not used [-Werror=unused-function]
27 | static int tegra20_spdif_runtime_suspend(struct device *dev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
tegra/tegra30_ahub.c:64:12: error: 'tegra30_ahub_runtime_resume' defined but not used [-Werror=unused-function]
64 | static int tegra30_ahub_runtime_resume(struct device *dev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
tegra/tegra30_ahub.c:43:12: error: 'tegra30_ahub_runtime_suspend' defined but not used [-Werror=unused-function]
43 | static int tegra30_ahub_runtime_suspend(struct device *dev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
Mark these functions as __maybe_unused to avoid this kind of warning.
Fixes: b5571449e6 ("ASoC: tegra30: ahub: Remove handing of disabled runtime PM")
Fixes: c53b396f0d ("ASoC: tegra20: spdif: Remove handing of disabled runtime PM")
Fixes: 80ec4a4cb3 ("ASoC: tegra20: i2s: Remove handing of disabled runtime PM")
Fixes: b5f6f781fc ("ASoC: tegra30: i2s: Remove handing of disabled runtime PM")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Link: https://lore.kernel.org/r/20210422133418.1757893-1-arnd@kernel.org
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
committed by
Mark Brown
parent
73371bacf0
commit
ccd4cc3ed0
@@ -34,7 +34,7 @@
|
||||
|
||||
#define DRV_NAME "tegra20-i2s"
|
||||
|
||||
static int tegra20_i2s_runtime_suspend(struct device *dev)
|
||||
static __maybe_unused int tegra20_i2s_runtime_suspend(struct device *dev)
|
||||
{
|
||||
struct tegra20_i2s *i2s = dev_get_drvdata(dev);
|
||||
|
||||
@@ -45,7 +45,7 @@ static int tegra20_i2s_runtime_suspend(struct device *dev)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int tegra20_i2s_runtime_resume(struct device *dev)
|
||||
static __maybe_unused int tegra20_i2s_runtime_resume(struct device *dev)
|
||||
{
|
||||
struct tegra20_i2s *i2s = dev_get_drvdata(dev);
|
||||
int ret;
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
#define DRV_NAME "tegra20-spdif"
|
||||
|
||||
static int tegra20_spdif_runtime_suspend(struct device *dev)
|
||||
static __maybe_unused int tegra20_spdif_runtime_suspend(struct device *dev)
|
||||
{
|
||||
struct tegra20_spdif *spdif = dev_get_drvdata(dev);
|
||||
|
||||
@@ -33,7 +33,7 @@ static int tegra20_spdif_runtime_suspend(struct device *dev)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int tegra20_spdif_runtime_resume(struct device *dev)
|
||||
static __maybe_unused int tegra20_spdif_runtime_resume(struct device *dev)
|
||||
{
|
||||
struct tegra20_spdif *spdif = dev_get_drvdata(dev);
|
||||
int ret;
|
||||
|
||||
@@ -40,7 +40,7 @@ static inline void tegra30_audio_write(u32 reg, u32 val)
|
||||
regmap_write(ahub->regmap_ahub, reg, val);
|
||||
}
|
||||
|
||||
static int tegra30_ahub_runtime_suspend(struct device *dev)
|
||||
static __maybe_unused int tegra30_ahub_runtime_suspend(struct device *dev)
|
||||
{
|
||||
regcache_cache_only(ahub->regmap_apbif, true);
|
||||
regcache_cache_only(ahub->regmap_ahub, true);
|
||||
@@ -61,7 +61,7 @@ static int tegra30_ahub_runtime_suspend(struct device *dev)
|
||||
* stopping streams should dynamically adjust the clock as required. However,
|
||||
* this is not yet implemented.
|
||||
*/
|
||||
static int tegra30_ahub_runtime_resume(struct device *dev)
|
||||
static __maybe_unused int tegra30_ahub_runtime_resume(struct device *dev)
|
||||
{
|
||||
int ret;
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
|
||||
#define DRV_NAME "tegra30-i2s"
|
||||
|
||||
static int tegra30_i2s_runtime_suspend(struct device *dev)
|
||||
static __maybe_unused int tegra30_i2s_runtime_suspend(struct device *dev)
|
||||
{
|
||||
struct tegra30_i2s *i2s = dev_get_drvdata(dev);
|
||||
|
||||
@@ -47,7 +47,7 @@ static int tegra30_i2s_runtime_suspend(struct device *dev)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int tegra30_i2s_runtime_resume(struct device *dev)
|
||||
static __maybe_unused int tegra30_i2s_runtime_resume(struct device *dev)
|
||||
{
|
||||
struct tegra30_i2s *i2s = dev_get_drvdata(dev);
|
||||
int ret;
|
||||
|
||||
Reference in New Issue
Block a user