Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 313736
b: refs/heads/master
c: 3b1267b
h: refs/heads/master
v: v3
  • Loading branch information
Paul Mundt committed May 18, 2012
1 parent b0d2c0a commit 803d22c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 22 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 051f923d922d105f4d32e64cba1ed6f5a749d530
refs/heads/master: 3b1267b90f6b7c080024101696c0454f455761f4
32 changes: 11 additions & 21 deletions trunk/arch/sh/boards/mach-dreamcast/irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@
* This file is part of the LinuxDC project (www.linuxdc.org)
* Released under the terms of the GNU GPL v2.0
*/

#include <linux/irq.h>
#include <linux/io.h>
#include <asm/irq.h>
#include <linux/irq.h>
#include <linux/export.h>
#include <linux/err.h>
#include <mach/sysasic.h>

/*
Expand Down Expand Up @@ -141,26 +142,15 @@ int systemasic_irq_demux(int irq)

void systemasic_irq_init(void)
{
int i, nid = cpu_to_node(boot_cpu_data);

/* Assign all virtual IRQs to the System ASIC int. handler */
for (i = HW_EVENT_IRQ_BASE; i < HW_EVENT_IRQ_MAX; i++) {
unsigned int irq;

irq = create_irq_nr(i, nid);
if (unlikely(irq == 0)) {
pr_err("%s: failed hooking irq %d for systemasic\n",
__func__, i);
return;
}
int irq_base, i;

if (unlikely(irq != i)) {
pr_err("%s: got irq %d but wanted %d, bailing.\n",
__func__, irq, i);
destroy_irq(irq);
return;
}
irq_base = irq_alloc_descs(HW_EVENT_IRQ_BASE, HW_EVENT_IRQ_BASE,
HW_EVENT_IRQ_MAX - HW_EVENT_IRQ_BASE, -1);
if (IS_ERR_VALUE(irq_base)) {
pr_err("%s: failed hooking irqs\n", __func__);
return;
}

for (i = HW_EVENT_IRQ_BASE; i < HW_EVENT_IRQ_MAX; i++)
irq_set_chip_and_handler(i, &systemasic_int, handle_level_irq);
}
}

0 comments on commit 803d22c

Please sign in to comment.