]> git.baikalelectronics.ru Git - kernel.git/commit
ata: brcm: mark PM functions as __maybe_unused
authorArnd Bergmann <arnd@arndb.de>
Tue, 7 Jan 2020 22:14:59 +0000 (23:14 +0100)
committerJens Axboe <axboe@kernel.dk>
Fri, 17 Jan 2020 04:49:07 +0000 (21:49 -0700)
commitc97342f41e65d8cfc37101b85b09b8e22322a3f8
tree54cb87b771cde9eb397bdc56e304a6e2c9e52ec7
parentf8b6461b375600fe3477b06c5d93ecd3c4f46939
ata: brcm: mark PM functions as __maybe_unused

The new shutdown callback causes a link failure:

drivers/ata/ahci_brcm.c: In function 'brcm_ahci_shutdown':
drivers/ata/ahci_brcm.c:552:8: error: implicit declaration of function 'brcm_ahci_suspend'; did you mean 'brcm_ahci_shutdown'? [-Werror=implicit-function-declaration]
  ret = brcm_ahci_suspend(&pdev->dev);
        ^~~~~~~~~~~~~~~~~

Remove the incorrect #ifdef and use __maybe_unused annotations
instead to make this more robust.

Fixes: 713f62ec4cd2 ("ata: ahci_brcm: Add a shutdown callback")
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/ata/ahci_brcm.c