Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

spi/pxa2xx: fix compilation warning when !CONFIG_PM_SLEEP

CONFIG_PM will be set if either or both CONFIG_PM_SLEEP and
CONFIG_PM_RUNTIME is set. Compiling the driver with !CONFIG_PM_SLEEP causes
following compilation warning:

drivers/spi/spi-pxa2xx.c:1270:12: warning: ‘pxa2xx_spi_suspend’ defined but not used [-Wunused-function]

Fix this by using CONFIG_PM_SLEEP instead.

Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: Mark Brown <broonie@linaro.org>

authored by

Mika Westerberg and committed by
Mark Brown
382cebb0 6ce4eac1

+1 -1
+1 -1
drivers/spi/spi-pxa2xx.c
··· 1264 1264 dev_err(&pdev->dev, "shutdown failed with %d\n", status); 1265 1265 } 1266 1266 1267 - #ifdef CONFIG_PM 1267 + #ifdef CONFIG_PM_SLEEP 1268 1268 static int pxa2xx_spi_suspend(struct device *dev) 1269 1269 { 1270 1270 struct driver_data *drv_data = dev_get_drvdata(dev);