aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/parisc/gsc.h
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:20:36 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:20:36 -0400
commit1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 (patch)
tree0bba044c4ce775e45a88a51686b5d9f90697ea9d /drivers/parisc/gsc.h
Linux-2.6.12-rc2v2.6.12-rc2
Initial git repository build. I'm not bothering with the full history, even though we have it. We can create a separate "historical" git archive of that later if we want to, and in the meantime it's about 3.2GB when imported into git - space that would just make the early git days unnecessarily complicated, when we don't have a lot of good infrastructure for it. Let it rip!
Diffstat (limited to 'drivers/parisc/gsc.h')
-rw-r--r--drivers/parisc/gsc.h47
1 files changed, 47 insertions, 0 deletions
diff --git a/drivers/parisc/gsc.h b/drivers/parisc/gsc.h
new file mode 100644
index 000000000000..a3dc456709d7
--- /dev/null
+++ b/drivers/parisc/gsc.h
@@ -0,0 +1,47 @@
1/*
2 * drivers/parisc/gsc.h
3 * Declarations for functions in gsc.c
4 * Copyright (c) 2000-2002 Helge Deller, Matthew Wilcox
5 *
6 * Distributed under the terms of the GPL, version 2
7 */
8
9#include <linux/interrupt.h>
10#include <asm/hardware.h>
11#include <asm/parisc-device.h>
12
13#define OFFSET_IRR 0x0000 /* Interrupt request register */
14#define OFFSET_IMR 0x0004 /* Interrupt mask register */
15#define OFFSET_IPR 0x0008 /* Interrupt pending register */
16#define OFFSET_ICR 0x000C /* Interrupt control register */
17#define OFFSET_IAR 0x0010 /* Interrupt address register */
18
19/* PA I/O Architected devices support at least 5 bits in the EIM register. */
20#define GSC_EIM_WIDTH 5
21
22struct gsc_irq {
23 unsigned long txn_addr; /* IRQ "target" */
24 int txn_data; /* HW "IRQ" */
25 int irq; /* virtual IRQ */
26};
27
28struct gsc_asic {
29 struct parisc_device *gsc;
30 unsigned long hpa;
31 char *name;
32 int version;
33 int type;
34 int eim;
35 int global_irq[32];
36};
37
38int gsc_common_setup(struct parisc_device *parent, struct gsc_asic *gsc_asic);
39int gsc_alloc_irq(struct gsc_irq *dev); /* dev needs an irq */
40int gsc_claim_irq(struct gsc_irq *dev, int irq); /* dev needs this irq */
41int gsc_assign_irq(struct hw_interrupt_type *type, void *data);
42int gsc_find_local_irq(unsigned int irq, int *global_irq, int limit);
43void gsc_fixup_irqs(struct parisc_device *parent, void *ctrl,
44 void (*choose)(struct parisc_device *child, void *ctrl));
45void gsc_asic_assign_irq(struct gsc_asic *asic, int local_irq, int *irqp);
46
47irqreturn_t gsc_asic_intr(int irq, void *dev, struct pt_regs *regs);