|
|
1.1 root 1: /*
1.1.1.2 root 2: * linux/kernel/asm.s
3: *
4: * (C) 1991 Linus Torvalds
5: */
6:
7: /*
1.1.1.6 ! root 8: * asm.s contains the low-level code for interrupts that cannot
! 9: * result in an task-switch. These are things like the hd- and
! 10: * floppy-interrupt etc. With these interrupts, we don't have to
! 11: * care about the stack layout etc.
1.1 root 12: */
13:
1.1.1.6 ! root 14: .globl _floppy_interrupt,_parallel_interrupt
1.1 root 15:
1.1.1.6 ! root 16: _floppy_interrupt:
! 17: cld
1.1.1.5 root 18: pushl %eax
19: pushl %ecx
1.1 root 20: pushl %edx
1.1.1.6 ! root 21: push %ds
! 22: push %es
! 23: push %fs
! 24: movl $0x10,%eax
! 25: mov %ax,%ds
! 26: mov %ax,%es
! 27: movl $0x17,%eax
! 28: mov %ax,%fs
! 29: movb $0x20,%al
! 30: outb %al,$0x20 # EOI to interrupt controller #1
! 31: xorl %eax,%eax
! 32: xchgl _do_floppy,%eax
! 33: testl %eax,%eax
! 34: jne 1f
! 35: movl $_unexpected_floppy_interrupt,%eax
! 36: 1: call *%eax # "interesting" way of handling intr.
! 37: pop %fs
! 38: pop %es
! 39: pop %ds
1.1.1.5 root 40: popl %edx
1.1.1.6 ! root 41: popl %ecx
1.1 root 42: popl %eax
43: iret
44:
1.1.1.6 ! root 45: _parallel_interrupt:
! 46: cld
1.1.1.2 root 47: pushl %eax
48: movb $0x20,%al
49: outb %al,$0x20
50: popl %eax
1.1.1.6 ! root 51: iret
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.