public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrey Panin <pazke@orbita1.ru>
To: linux-kernel@vger.kernel.org
Subject: [PATCH] create header file for i386/kernel/i8259.c
Date: Fri, 31 Jan 2003 11:05:43 +0300	[thread overview]
Message-ID: <20030131080543.GC8183@pazke> (raw)

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

Hi all,

this trivial patch against 2.5.59 creates header file asm-i386/i8259.h
and exports some prototypes and macros related to i8259 handling into it.

This allows subarches (such as visws) to use some parts of i8259.c for
handling their nonstandard hardware.

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.59.vanilla/arch/i386/kernel/i8259.c linux-2.5.59/arch/i386/kernel/i8259.c
--- linux-2.5.59.vanilla/arch/i386/kernel/i8259.c	Wed Jan 15 20:37:20 2003
+++ linux-2.5.59/arch/i386/kernel/i8259.c	Sun Jan 19 18:43:10 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)
diff -urN -X /usr/share/dontdiff linux-2.5.59.vanilla/include/asm-i386/i8259.h linux-2.5.59/include/asm-i386/i8259.h
--- linux-2.5.59.vanilla/include/asm-i386/i8259.h	Thu Jan  1 03:00:00 1970
+++ linux-2.5.59/include/asm-i386/i8259.h	Sun Jan 19 18:43:10 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__ */

                 reply	other threads:[~2003-01-31  8:01 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030131080543.GC8183@pazke \
    --to=pazke@orbita1.ru \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox