All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] visws: export some functions from i8259.c (2/13)
@ 2003-02-14 12:57 Andrey Panin
  0 siblings, 0 replies; only message in thread
From: Andrey Panin @ 2003-02-14 12:57 UTC (permalink / raw)
  To: linux-kernel; +Cc: Linus Torvalds

[-- Attachment #1: Type: text/plain, Size: 351 bytes --]

Hi.

This trivial patch exports some functions from 8259.c file.
Visws subarch needs them to handle interrupts from legacy devices 
connected to PIIX4 i8259s, which are in turn connected to SGI 
Cobalt APIC.

Please consider applying.

Best regards.

-- 
Andrey Panin		| Embedded systems software developer
pazke@orbita1.ru	| PGP key: wwwkeys.pgp.net

[-- Attachment #2: patch-i8259 --]
[-- Type: text/plain, Size: 1829 bytes --]

diff -urN -X /usr/share/dontdiff linux-2.5.60.vanilla/include/asm-i386/i8259.h linux-2.5.60/include/asm-i386/i8259.h
--- linux-2.5.60.vanilla/include/asm-i386/i8259.h	Thu Jan  1 03:00:00 1970
+++ linux-2.5.60/include/asm-i386/i8259.h	Thu Feb 13 20:42:02 2003
@@ -0,0 +1,17 @@
+#ifndef __ASM_I8259_H__
+#define __ASM_I8259_H__
+
+extern unsigned int cached_irq_mask;
+
+#define __byte(x,y) 	(((unsigned char *) &(y))[x])
+#define cached_21	(__byte(0, cached_irq_mask))
+#define cached_A1	(__byte(1, cached_irq_mask))
+
+extern spinlock_t i8259A_lock;
+
+extern void init_8259A(int auto_eoi);
+extern void enable_8259A_irq(unsigned int irq);
+extern void disable_8259A_irq(unsigned int irq);
+extern unsigned int startup_8259A_irq(unsigned int irq);
+
+#endif	/* __ASM_I8259_H__ */
diff -urN -X /usr/share/dontdiff linux-2.5.60.vanilla/arch/i386/kernel/i8259.c linux-2.5.60/arch/i386/kernel/i8259.c
--- linux-2.5.60.vanilla/arch/i386/kernel/i8259.c	Thu Feb 13 20:29:07 2003
+++ linux-2.5.60/arch/i386/kernel/i8259.c	Thu Feb 13 20:42:02 2003
@@ -22,6 +22,7 @@
 #include <asm/desc.h>
 #include <asm/apic.h>
 #include <asm/arch_hooks.h>
+#include <asm/i8259.h>
 
 #include <linux/irq.h>
 
@@ -47,7 +48,7 @@
 
 void mask_and_ack_8259A(unsigned int);
 
-static unsigned int startup_8259A_irq(unsigned int irq)
+unsigned int startup_8259A_irq(unsigned int irq)
 { 
 	enable_8259A_irq(irq);
 	return 0; /* never anything pending */
@@ -71,11 +72,7 @@
 /*
  * This contains the irq mask for both 8259A irq controllers,
  */
-static unsigned int cached_irq_mask = 0xffff;
-
-#define __byte(x,y) 	(((unsigned char *)&(y))[x])
-#define cached_21	(__byte(0,cached_irq_mask))
-#define cached_A1	(__byte(1,cached_irq_mask))
+unsigned int cached_irq_mask = 0xffff;
 
 /*
  * Not all IRQs can be routed through the IO-APIC, eg. on certain (older)

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-02-14 13:02 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-02-14 12:57 [PATCH] visws: export some functions from i8259.c (2/13) Andrey Panin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.