1
0
Fork 0
alistair23-linux/kernel/power
zhangyi (F) 3df6f61fff PM / sleep: wakeup: Fix build error caused by missing SRCU support
Commit ea0212f40c (power: auto select CONFIG_SRCU) made the code in
drivers/base/power/wakeup.c use SRCU instead of RCU, but it forgot to
select CONFIG_SRCU in Kconfig, which leads to the following build
error if CONFIG_SRCU is not selected somewhere else:

drivers/built-in.o: In function `wakeup_source_remove':
(.text+0x3c6fc): undefined reference to `synchronize_srcu'
drivers/built-in.o: In function `pm_print_active_wakeup_sources':
(.text+0x3c7a8): undefined reference to `__srcu_read_lock'
drivers/built-in.o: In function `pm_print_active_wakeup_sources':
(.text+0x3c84c): undefined reference to `__srcu_read_unlock'
drivers/built-in.o: In function `device_wakeup_arm_wake_irqs':
(.text+0x3d1d8): undefined reference to `__srcu_read_lock'
drivers/built-in.o: In function `device_wakeup_arm_wake_irqs':
(.text+0x3d228): undefined reference to `__srcu_read_unlock'
drivers/built-in.o: In function `device_wakeup_disarm_wake_irqs':
(.text+0x3d24c): undefined reference to `__srcu_read_lock'
drivers/built-in.o: In function `device_wakeup_disarm_wake_irqs':
(.text+0x3d29c): undefined reference to `__srcu_read_unlock'
drivers/built-in.o:(.data+0x4158): undefined reference to `process_srcu'

Fix this error by selecting CONFIG_SRCU when PM_SLEEP is enabled.

Fixes: ea0212f40c (power: auto select CONFIG_SRCU)
Cc: 4.2+ <stable@vger.kernel.org> # 4.2+
Signed-off-by: zhangyi (F) <yi.zhang@huawei.com>
[ rjw: Minor subject/changelog fixups ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2018-08-15 00:07:08 +02:00
..
Kconfig PM / sleep: wakeup: Fix build error caused by missing SRCU support 2018-08-15 00:07:08 +02:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
autosleep.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
console.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
hibernate.c PM / reboot: Eliminate race between reboot and suspend 2018-08-06 12:35:20 +02:00
main.c PM / reboot: Eliminate race between reboot and suspend 2018-08-06 12:35:20 +02:00
power.h x86/power: Fix swsusp_arch_resume prototype 2018-02-02 23:33:50 +01:00
poweroff.c power/sysrq: fix inconstistent help message of sysrq key 2013-04-30 17:04:10 -07:00
process.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
qos.c PM / QoS: Drop redundant declaration of pm_qos_get_value() 2018-05-28 23:21:41 +02:00
snapshot.c PM: hibernate: Do not subtract NR_FILE_MAPPED in minimum_image_size() 2018-01-05 14:46:25 +01:00
suspend.c Power management updates for 4.19-rc1 2018-08-14 13:12:24 -07:00
suspend_test.c PM / s2idle: Rename PM_SUSPEND_FREEZE to PM_SUSPEND_TO_IDLE 2017-08-11 01:29:55 +02:00
swap.c PM / hibernate: cast PAGE_SIZE to int when comparing with error code 2018-07-02 11:48:30 +02:00
user.c PM / reboot: Eliminate race between reboot and suspend 2018-08-06 12:35:20 +02:00
wakelock.c PM / wakeup: Only update last time for active wakeup sources 2018-05-10 11:39:19 +02:00