Commit 5cd221e8 authored by Joerg Roedel's avatar Joerg Roedel Committed by Linus Torvalds

alpha: Fix build around srm_sysrq_reboot_op

The patch introducing the struct was probably never compile tested,
because it sets a handler with a wrong function signature. Wrap the
handler into a functions with the correct signature to fix the build.

Fixes: 0f1c9688 ("tty/sysrq: alpha: export and use __sysrq_get_key_op()")
Cc: Emil Velikov <emil.l.velikov@gmail.com>
Signed-off-by: default avatarJoerg Roedel <jroedel@suse.de>
Reviewed-by: default avatarGuenter Roeck <linux@roeck-us.net>
Tested-by: default avatarGuenter Roeck <linux@roeck-us.net>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent cd16ed33
...@@ -430,8 +430,13 @@ register_cpus(void) ...@@ -430,8 +430,13 @@ register_cpus(void)
arch_initcall(register_cpus); arch_initcall(register_cpus);
#ifdef CONFIG_MAGIC_SYSRQ #ifdef CONFIG_MAGIC_SYSRQ
static void sysrq_reboot_handler(int unused)
{
machine_halt();
}
static const struct sysrq_key_op srm_sysrq_reboot_op = { static const struct sysrq_key_op srm_sysrq_reboot_op = {
.handler = machine_halt, .handler = sysrq_reboot_handler,
.help_msg = "reboot(b)", .help_msg = "reboot(b)",
.action_msg = "Resetting", .action_msg = "Resetting",
.enable_mask = SYSRQ_ENABLE_BOOT, .enable_mask = SYSRQ_ENABLE_BOOT,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment