Add .data, .text to output.
authorBen Pfaff <blp@cs.stanford.edu>
Sun, 29 Aug 2004 07:02:56 +0000 (07:02 +0000)
committerBen Pfaff <blp@cs.stanford.edu>
Sun, 29 Aug 2004 07:02:56 +0000 (07:02 +0000)
Pop intr_handler arg inside intr_entry, not intr_exit.

src/threads/intr-stubs.pl

index ea20e9668ede5de1669138957c5e205079c6e3f4..9725860b24b297b70175cbaac1618a200f153e0b 100755 (executable)
@@ -3,6 +3,7 @@
 print <<'EOF';
 #include "mmu.h"
 
+       .data
        .globl intr_stubs
 intr_stubs:
 EOF
@@ -11,7 +12,11 @@ for $i (0...255) {
     $x = sprintf ("%02x", $i);
     print "\t.long intr${x}_stub\n";
 }
-print "\n";
+
+print <<'EOF';
+
+       .text
+EOF
 
 for $i (0...255) {
     $x = sprintf ("%02x", $i);
@@ -42,10 +47,10 @@ intr_entry:
        pushl %esp
        .globl intr_handler
        call intr_handler
+       addl $4, %esp
 
        .globl intr_exit
 intr_exit:
-       addl $4, %esp
 
        # Restore caller's registers.
        popal