interrupt1.S 254 B

1234567891011121314
  1. #include "common.h"
  2. BEGIN
  3. CLEAR
  4. /* Set address of the handler for interrupt 1. */
  5. movw $handler, 0x04
  6. /* Set code segment of the handler for interrupt 1. */
  7. mov %cs, 0x06
  8. int $1
  9. PUTC $'b
  10. hlt
  11. handler:
  12. PUTC $'a
  13. iret