]> git.baikalelectronics.ru Git - kernel.git/commit
rtc: sh: mark PM functions as unused
authorArnd Bergmann <arnd@arndb.de>
Wed, 19 Apr 2017 17:52:43 +0000 (19:52 +0200)
committerAlexandre Belloni <alexandre.belloni@free-electrons.com>
Sat, 22 Apr 2017 16:01:15 +0000 (18:01 +0200)
commitbd0249ee3c8bc621389fc6dce523e38fa2d29759
treec371ff6cfe873e431cbe6b3499e06ed902ca7223
parent852aeb92c6396305ab462aed33da2ff554baaa07
rtc: sh: mark PM functions as unused

The sh_rtc_set_irq_wake() function is only called from the suspend/resume handlers
that may be hidden, causing a harmless warning:

drivers/rtc/rtc-sh.c:724:13: error: 'sh_rtc_set_irq_wake' defined but not used [-Werror=unused-function]
 static void sh_rtc_set_irq_wake(struct device *dev, int enabled)

The most reliable way to avoid the warning is to remove the existing #ifdef
and mark the two functions as __maybe_unused so the compiler can silently
drop all three when there is no reference.

Fixes: 87ed1f2b89ec ("rtc: sh: add support for rza series")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
drivers/rtc/rtc-sh.c