Skip to contentSkip to conversation

spi: tegra20: fix build with CONFIG_PM_SLEEP=n

PATCH In review Arnd Bergmann 4 participants 5 messages Oct 13, 2021 – Oct 18, 2021

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 spi: tegra20: fix build with CONFIG_PM_SLEEP=n

From: Arnd Bergmann <[email protected]>

There is another one of these warnings:

drivers/spi/spi-tegra20-slink.c:1197:12: error: 'tegra_slink_runtime_resume' defined but not used [-Werror=unused-function]
1197 | static int tegra_slink_runtime_resume(struct device *dev)

      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~

Give it the same treatment as the other functions in this file.

Fixes efafec27c565 ("spi: Fix tegra20 build with CONFIG_PM=n")
Fixes 2bab94090b01 ("spi: tegra20-slink: Declare runtime suspend and resume functions conditionally")
---
 drivers/spi/spi-tegra20-slink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/spi/spi-tegra20-slink.c +1 -1
index 713292b0c71e..33302f6b42d7 100644
@@ -1194,7 +1194,7 @@ static int __maybe_unused tegra_slink_runtime_suspend(struct device *dev)
 	return 0;
 }
 
-static int tegra_slink_runtime_resume(struct device *dev)
+static __maybe_unused int tegra_slink_runtime_resume(struct device *dev)
 {
 	struct spi_master *master = dev_get_drvdata(dev);
 	struct tegra_slink_data *tspi = spi_master_get_devdata(master);
Signature · 1 line
2.29.2
Reviewed-by on v1 1/1
#1 lore raw
Quoted 22 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

There is another one of these warnings:

drivers/spi/spi-tegra20-slink.c:1197:12: error: 'tegra_slink_runtime_resume' defined but not used [-Werror=unused-function]
1197 | static int tegra_slink_runtime_resume(struct device *dev)

      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~

Give it the same treatment as the other functions in this file.

Fixes efafec27c565 ("spi: Fix tegra20 build with CONFIG_PM=n")
Fixes 2bab94090b01 ("spi: tegra20-slink: Declare runtime suspend and resume functions conditionally")
---
 drivers/spi/spi-tegra20-slink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/spi/spi-tegra20-slink.c +0 -0
index 713292b0c71e..33302f6b42d7 100644

drivers/spi/spi-tegra20-slink.c static int __maybe_unused tegra_slink_runtime_suspend(struct device *dev) · line 1197

Quoted 5 lines
drivers/spi/spi-tegra20-slink.c +1 -1
@@ -1194,7 +1194,7 @@ static int __maybe_unused tegra_slink_runtime_suspend(struct device *dev)
 	return 0;
 }
 
-static int tegra_slink_runtime_resume(struct device *dev)
+static __maybe_unused int tegra_slink_runtime_resume(struct device *dev)

That was actually done in efafec27c565. The error is the result of a bad conflict resolution against 2bab94090b01, not a result of any of the two patches listed in the Fixes: tags. So, yes, either this patch needs to be applied in -next or the conflict resolution needs to be fixed.

Guenter

Quoted 6 lines
drivers/spi/spi-tegra20-slink.c +0 -0
 {
 	struct spi_master *master = dev_get_drvdata(dev);
 	struct tegra_slink_data *tspi = spi_master_get_devdata(master);
Signature · 1 line
2.29.2
maintainer
#2 lore raw
In reply to Arnd Bergmann
Quoted 9 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

There is another one of these warnings:

drivers/spi/spi-tegra20-slink.c:1197:12: error: 'tegra_slink_runtime_resume' defined but not used [-Werror=unused-function]
1197 | static int tegra_slink_runtime_resume(struct device *dev)

      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~

[...]

Applied to

https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-next

Thanks!

[1/1] spi: tegra20: fix build with CONFIG_PM_SLEEP=n

      commit: 7dc9b9562740d858332894447c9779b146559239

All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying to this mail.

Thanks,
Mark

Acked-by on v1 1/1
#3 lore raw
In reply to Arnd Bergmann
Quoted 8 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

There is another one of these warnings:

drivers/spi/spi-tegra20-slink.c:1197:12: error: 'tegra_slink_runtime_resume' defined but not used [-Werror=unused-function]
1197 | static int tegra_slink_runtime_resume(struct device *dev)

      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~
Quoted 8 lines

Give it the same treatment as the other functions in this file.

Fixes efafec27c565 ("spi: Fix tegra20 build with CONFIG_PM=n")
Fixes 2bab94090b01 ("spi: tegra20-slink: Declare runtime suspend and resume functions conditionally")
---
 drivers/spi/spi-tegra20-slink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
#4 lore raw
Quoted 11 lines · Thierry Reding
Quoted 10 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

There is another one of these warnings:

drivers/spi/spi-tegra20-slink.c:1197:12: error: 'tegra_slink_runtime_resume' defined but not used [-Werror=unused-function]
1197 | static int tegra_slink_runtime_resume(struct device *dev)

       |            ^~~~~~~~~~~~~~~~~~~~~~~~~~

Give it the same treatment as the other functions in this file.

Quoted 9 lines
Quoted 6 lines
Fixes efafec27c565 ("spi: Fix tegra20 build with CONFIG_PM=n")
Fixes 2bab94090b01 ("spi: tegra20-slink: Declare runtime suspend and resume functions conditionally")
---
  drivers/spi/spi-tegra20-slink.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

The problem has now been (re-)introduced into the mainline kernel and causes various test build failures there.

Guenter