Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 112645
b: refs/heads/master
c: d94d93c
h: refs/heads/master
i:
  112643: 6dd1378
v: v3
  • Loading branch information
Suresh Siddha authored and Ingo Molnar committed Jul 12, 2008
1 parent f1009be commit 9a520fd
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 72b1e22dfcad1daca6906148fd956ffe404bb0bc
refs/heads/master: d94d93ca5cc36cd78c532def62772c98fe8ba5d7
24 changes: 24 additions & 0 deletions trunk/arch/x86/kernel/i8259.c
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,30 @@ static int __init i8259A_init_sysfs(void)

device_initcall(i8259A_init_sysfs);

void mask_8259A(void)
{
unsigned long flags;

spin_lock_irqsave(&i8259A_lock, flags);

outb(0xff, PIC_MASTER_IMR); /* mask all of 8259A-1 */
outb(0xff, PIC_SLAVE_IMR); /* mask all of 8259A-2 */

spin_unlock_irqrestore(&i8259A_lock, flags);
}

void unmask_8259A(void)
{
unsigned long flags;

spin_lock_irqsave(&i8259A_lock, flags);

outb(cached_master_mask, PIC_MASTER_IMR); /* restore master IRQ mask */
outb(cached_slave_mask, PIC_SLAVE_IMR); /* restore slave IRQ mask */

spin_unlock_irqrestore(&i8259A_lock, flags);
}

void init_8259A(int auto_eoi)
{
unsigned long flags;
Expand Down
3 changes: 3 additions & 0 deletions trunk/include/asm-x86/i8259.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,7 @@ static inline void outb_pic(unsigned char value, unsigned int port)

extern struct irq_chip i8259A_chip;

extern void mask_8259A(void);
extern void unmask_8259A(void);

#endif /* __ASM_I8259_H__ */

0 comments on commit 9a520fd

Please sign in to comment.