aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/arch/ia64/hp/sim/simserial.c
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2012-03-08 21:01:18 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-03-08 12:26:30 -0800
commit6efb6b77ff6fd512e9ef45b29f1940cb924cd7a6 (patch)
treeaf1c250060eac5eed26608e8709ae7e4d3c4b287 /arch/ia64/hp/sim/simserial.c
parentsimserial, include some headers (diff)
downloadwireguard-linux-6efb6b77ff6fd512e9ef45b29f1940cb924cd7a6.tar.xz
wireguard-linux-6efb6b77ff6fd512e9ef45b29f1940cb924cd7a6.zip
hpsim, initialize chip for assigned irqs
Currently, when assign_irq_vector is called and the irq connected in the simulator, the irq is not ready. request_irq will return ENOSYS immediately. It is because the irq chip is unset. Hence set the chip properly to irq_type_hp_sim. And make sure this is done from both users of simulated interrupts. Also we have to set handler here, otherwise we end up in handle_bad_int resulting in spam in logs and no irqs handled. We use handle_simple_irq as these are SW interrupts that need no ACK or anything. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Tony Luck <tony.luck@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch/ia64/hp/sim/simserial.c')
-rw-r--r--arch/ia64/hp/sim/simserial.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/ia64/hp/sim/simserial.c b/arch/ia64/hp/sim/simserial.c
index 35ae642b2a1a..3a079decde51 100644
--- a/arch/ia64/hp/sim/simserial.c
+++ b/arch/ia64/hp/sim/simserial.c
@@ -933,11 +933,10 @@ simrs_init (void)
if (state->type == PORT_UNKNOWN) continue;
if (!state->irq) {
- if ((rc = assign_irq_vector(AUTO_ASSIGN)) < 0)
+ if ((rc = hpsim_get_irq(KEYBOARD_INTR)) < 0)
panic("%s: out of interrupt vectors!\n",
__func__);
state->irq = rc;
- ia64_ssc_connect_irq(KEYBOARD_INTR, state->irq);
}
printk(KERN_INFO "ttyS%d at 0x%04lx (irq = %d) is a %s\n",