diff options
author | afzal mohammed <afzal.mohd.ma@gmail.com> | 2020-03-12 07:42:55 +0100 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2020-03-25 02:07:57 +0100 |
commit | b4f00d5b2098320a0d4c4a6d31099bc0c9a85b02 (patch) | |
tree | 9bc3cf4525184149b10e2803d3a726a85e03ee7d /arch/powerpc/platforms/chrp | |
parent | powerpc/cell: Use fallthrough; (diff) | |
download | linux-b4f00d5b2098320a0d4c4a6d31099bc0c9a85b02.tar.xz linux-b4f00d5b2098320a0d4c4a6d31099bc0c9a85b02.zip |
powerpc: Replace setup_irq() by request_irq()
request_irq() is preferred over setup_irq(). Invocations of setup_irq()
occur after memory allocators are ready.
Per tglx[1], setup_irq() existed in olden days when allocators were not
ready by the time early interrupts were initialized.
Hence replace setup_irq() by request_irq().
[1] https://lkml.kernel.org/r/alpine.DEB.2.20.1710191609480.1971@nanos
Signed-off-by: afzal mohammed <afzal.mohd.ma@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20200312064256.18735-1-afzal.mohd.ma@gmail.com
Diffstat (limited to 'arch/powerpc/platforms/chrp')
-rw-r--r-- | arch/powerpc/platforms/chrp/setup.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/arch/powerpc/platforms/chrp/setup.c b/arch/powerpc/platforms/chrp/setup.c index fcf6f2342ef4..8328cd5817b0 100644 --- a/arch/powerpc/platforms/chrp/setup.c +++ b/arch/powerpc/platforms/chrp/setup.c @@ -451,13 +451,6 @@ static void __init chrp_find_openpic(void) of_node_put(np); } -#if defined(CONFIG_VT) && defined(CONFIG_INPUT_ADBHID) && defined(CONFIG_XMON) -static struct irqaction xmon_irqaction = { - .handler = xmon_irq, - .name = "XMON break", -}; -#endif - static void __init chrp_find_8259(void) { struct device_node *np, *pic = NULL; @@ -541,8 +534,11 @@ static void __init chrp_init_IRQ(void) if (of_node_is_type(kbd->parent, "adb")) break; of_node_put(kbd); - if (kbd) - setup_irq(HYDRA_INT_ADB_NMI, &xmon_irqaction); + if (kbd) { + if (request_irq(HYDRA_INT_ADB_NMI, xmon_irq, 0, "XMON break", + NULL)) + pr_err("Failed to register XMON break interrupt\n"); + } #endif } |