Use the kernel's MAX_ERRNO in the syscall stubs.

Bug: http://code.google.com/p/android/issues/detail?id=53104
Change-Id: Iaabf7025b153e96dc5eca231a33a32d4cb7d8116
diff --git a/libc/arch-x86/syscalls/__brk.S b/libc/arch-x86/syscalls/__brk.S
index f7a81ff..88841df 100644
--- a/libc/arch-x86/syscalls/__brk.S
+++ b/libc/arch-x86/syscalls/__brk.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_brk, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__fcntl.S b/libc/arch-x86/syscalls/__fcntl.S
index 9f74d86..087097e 100644
--- a/libc/arch-x86/syscalls/__fcntl.S
+++ b/libc/arch-x86/syscalls/__fcntl.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_fcntl, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__fcntl64.S b/libc/arch-x86/syscalls/__fcntl64.S
index c59f490..5a67ee1 100644
--- a/libc/arch-x86/syscalls/__fcntl64.S
+++ b/libc/arch-x86/syscalls/__fcntl64.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_fcntl64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__fork.S b/libc/arch-x86/syscalls/__fork.S
index 557714d..7c3661d 100644
--- a/libc/arch-x86/syscalls/__fork.S
+++ b/libc/arch-x86/syscalls/__fork.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_fork, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__fstatfs64.S b/libc/arch-x86/syscalls/__fstatfs64.S
index 9943362..57eb2f6 100644
--- a/libc/arch-x86/syscalls/__fstatfs64.S
+++ b/libc/arch-x86/syscalls/__fstatfs64.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_fstatfs64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__getcpu.S b/libc/arch-x86/syscalls/__getcpu.S
index 152f5c8..448e012 100644
--- a/libc/arch-x86/syscalls/__getcpu.S
+++ b/libc/arch-x86/syscalls/__getcpu.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_getcpu, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__getcwd.S b/libc/arch-x86/syscalls/__getcwd.S
index 2e30d9b..29a73e3 100644
--- a/libc/arch-x86/syscalls/__getcwd.S
+++ b/libc/arch-x86/syscalls/__getcwd.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_getcwd, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__getpriority.S b/libc/arch-x86/syscalls/__getpriority.S
index a015127..c5f4751 100644
--- a/libc/arch-x86/syscalls/__getpriority.S
+++ b/libc/arch-x86/syscalls/__getpriority.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_getpriority, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__ioctl.S b/libc/arch-x86/syscalls/__ioctl.S
index db85a19..e64c3af 100644
--- a/libc/arch-x86/syscalls/__ioctl.S
+++ b/libc/arch-x86/syscalls/__ioctl.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_ioctl, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__llseek.S b/libc/arch-x86/syscalls/__llseek.S
index 7811f6b..9160ee7 100644
--- a/libc/arch-x86/syscalls/__llseek.S
+++ b/libc/arch-x86/syscalls/__llseek.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR__llseek, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__mmap2.S b/libc/arch-x86/syscalls/__mmap2.S
index 535a891..59c6d23 100644
--- a/libc/arch-x86/syscalls/__mmap2.S
+++ b/libc/arch-x86/syscalls/__mmap2.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -17,7 +18,7 @@
     mov     48(%esp), %ebp
     movl    $__NR_mmap2, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__open.S b/libc/arch-x86/syscalls/__open.S
index b878231..02b99b7 100644
--- a/libc/arch-x86/syscalls/__open.S
+++ b/libc/arch-x86/syscalls/__open.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_open, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__openat.S b/libc/arch-x86/syscalls/__openat.S
index faf8013..8a7dafe 100644
--- a/libc/arch-x86/syscalls/__openat.S
+++ b/libc/arch-x86/syscalls/__openat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_openat, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__ptrace.S b/libc/arch-x86/syscalls/__ptrace.S
index f574cf0..157bdd8 100644
--- a/libc/arch-x86/syscalls/__ptrace.S
+++ b/libc/arch-x86/syscalls/__ptrace.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_ptrace, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__reboot.S b/libc/arch-x86/syscalls/__reboot.S
index 626a955..6c6ecff 100644
--- a/libc/arch-x86/syscalls/__reboot.S
+++ b/libc/arch-x86/syscalls/__reboot.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_reboot, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__rt_sigaction.S b/libc/arch-x86/syscalls/__rt_sigaction.S
index ef9893b..b0ffaee 100644
--- a/libc/arch-x86/syscalls/__rt_sigaction.S
+++ b/libc/arch-x86/syscalls/__rt_sigaction.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_rt_sigaction, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__rt_sigprocmask.S b/libc/arch-x86/syscalls/__rt_sigprocmask.S
index 930c9b2..26b2fee 100644
--- a/libc/arch-x86/syscalls/__rt_sigprocmask.S
+++ b/libc/arch-x86/syscalls/__rt_sigprocmask.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_rt_sigprocmask, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__rt_sigtimedwait.S b/libc/arch-x86/syscalls/__rt_sigtimedwait.S
index ba867f5..af53f04 100644
--- a/libc/arch-x86/syscalls/__rt_sigtimedwait.S
+++ b/libc/arch-x86/syscalls/__rt_sigtimedwait.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_rt_sigtimedwait, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__sched_getaffinity.S b/libc/arch-x86/syscalls/__sched_getaffinity.S
index 2a40b65..21efaee 100644
--- a/libc/arch-x86/syscalls/__sched_getaffinity.S
+++ b/libc/arch-x86/syscalls/__sched_getaffinity.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_sched_getaffinity, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__set_thread_area.S b/libc/arch-x86/syscalls/__set_thread_area.S
index dc4a561..bcdbca3 100644
--- a/libc/arch-x86/syscalls/__set_thread_area.S
+++ b/libc/arch-x86/syscalls/__set_thread_area.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_set_thread_area, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__setresuid.S b/libc/arch-x86/syscalls/__setresuid.S
index c604984..d235042 100644
--- a/libc/arch-x86/syscalls/__setresuid.S
+++ b/libc/arch-x86/syscalls/__setresuid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_setresuid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__setreuid.S b/libc/arch-x86/syscalls/__setreuid.S
index 5818739..61eea65 100644
--- a/libc/arch-x86/syscalls/__setreuid.S
+++ b/libc/arch-x86/syscalls/__setreuid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_setreuid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__setuid.S b/libc/arch-x86/syscalls/__setuid.S
index df578b8..f5b5c72 100644
--- a/libc/arch-x86/syscalls/__setuid.S
+++ b/libc/arch-x86/syscalls/__setuid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_setuid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__sigsuspend.S b/libc/arch-x86/syscalls/__sigsuspend.S
index b09f872..52bb2d8 100644
--- a/libc/arch-x86/syscalls/__sigsuspend.S
+++ b/libc/arch-x86/syscalls/__sigsuspend.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_sigsuspend, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__statfs64.S b/libc/arch-x86/syscalls/__statfs64.S
index 4f46bd7..3716cec 100644
--- a/libc/arch-x86/syscalls/__statfs64.S
+++ b/libc/arch-x86/syscalls/__statfs64.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_statfs64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__sys_clone.S b/libc/arch-x86/syscalls/__sys_clone.S
index a5ce170..674797b 100644
--- a/libc/arch-x86/syscalls/__sys_clone.S
+++ b/libc/arch-x86/syscalls/__sys_clone.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_clone, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__syslog.S b/libc/arch-x86/syscalls/__syslog.S
index 9d36779..8db151a 100644
--- a/libc/arch-x86/syscalls/__syslog.S
+++ b/libc/arch-x86/syscalls/__syslog.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_syslog, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__timer_create.S b/libc/arch-x86/syscalls/__timer_create.S
index b319f1b..5b92706 100644
--- a/libc/arch-x86/syscalls/__timer_create.S
+++ b/libc/arch-x86/syscalls/__timer_create.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_timer_create, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__timer_delete.S b/libc/arch-x86/syscalls/__timer_delete.S
index 7fb5930..3ba48e4 100644
--- a/libc/arch-x86/syscalls/__timer_delete.S
+++ b/libc/arch-x86/syscalls/__timer_delete.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_timer_delete, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__timer_getoverrun.S b/libc/arch-x86/syscalls/__timer_getoverrun.S
index 477a3d8..f49e218 100644
--- a/libc/arch-x86/syscalls/__timer_getoverrun.S
+++ b/libc/arch-x86/syscalls/__timer_getoverrun.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_timer_getoverrun, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__timer_gettime.S b/libc/arch-x86/syscalls/__timer_gettime.S
index ee5604d..b1dd22c 100644
--- a/libc/arch-x86/syscalls/__timer_gettime.S
+++ b/libc/arch-x86/syscalls/__timer_gettime.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_timer_gettime, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__timer_settime.S b/libc/arch-x86/syscalls/__timer_settime.S
index 9758f61..9bda7f8 100644
--- a/libc/arch-x86/syscalls/__timer_settime.S
+++ b/libc/arch-x86/syscalls/__timer_settime.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_timer_settime, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__wait4.S b/libc/arch-x86/syscalls/__wait4.S
index 23165a3..57de4d9 100644
--- a/libc/arch-x86/syscalls/__wait4.S
+++ b/libc/arch-x86/syscalls/__wait4.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_wait4, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/__waitid.S b/libc/arch-x86/syscalls/__waitid.S
index 12f1ac8..9c2125a 100644
--- a/libc/arch-x86/syscalls/__waitid.S
+++ b/libc/arch-x86/syscalls/__waitid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_waitid, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/_exit.S b/libc/arch-x86/syscalls/_exit.S
index e17f925..0bfb2f9 100644
--- a/libc/arch-x86/syscalls/_exit.S
+++ b/libc/arch-x86/syscalls/_exit.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_exit_group, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/_exit_thread.S b/libc/arch-x86/syscalls/_exit_thread.S
index a371350..d20caea 100644
--- a/libc/arch-x86/syscalls/_exit_thread.S
+++ b/libc/arch-x86/syscalls/_exit_thread.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_exit, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/_waitpid.S b/libc/arch-x86/syscalls/_waitpid.S
index 59bf20e..74da41a 100644
--- a/libc/arch-x86/syscalls/_waitpid.S
+++ b/libc/arch-x86/syscalls/_waitpid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_waitpid, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/accept.S b/libc/arch-x86/syscalls/accept.S
index f5fcb5d..5c0df0d 100644
--- a/libc/arch-x86/syscalls/accept.S
+++ b/libc/arch-x86/syscalls/accept.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/access.S b/libc/arch-x86/syscalls/access.S
index 0f68574..cdf2a2a 100644
--- a/libc/arch-x86/syscalls/access.S
+++ b/libc/arch-x86/syscalls/access.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_access, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/acct.S b/libc/arch-x86/syscalls/acct.S
index bf991d6..0d224ee 100644
--- a/libc/arch-x86/syscalls/acct.S
+++ b/libc/arch-x86/syscalls/acct.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_acct, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/bind.S b/libc/arch-x86/syscalls/bind.S
index ff6ae9f..942aba5 100644
--- a/libc/arch-x86/syscalls/bind.S
+++ b/libc/arch-x86/syscalls/bind.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/capget.S b/libc/arch-x86/syscalls/capget.S
index 55960f1..55d230c 100644
--- a/libc/arch-x86/syscalls/capget.S
+++ b/libc/arch-x86/syscalls/capget.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_capget, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/capset.S b/libc/arch-x86/syscalls/capset.S
index c8703c7..5ce72e4 100644
--- a/libc/arch-x86/syscalls/capset.S
+++ b/libc/arch-x86/syscalls/capset.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_capset, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/chdir.S b/libc/arch-x86/syscalls/chdir.S
index d40d099..f453d94 100644
--- a/libc/arch-x86/syscalls/chdir.S
+++ b/libc/arch-x86/syscalls/chdir.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_chdir, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/chmod.S b/libc/arch-x86/syscalls/chmod.S
index 307e196..3202cbd 100644
--- a/libc/arch-x86/syscalls/chmod.S
+++ b/libc/arch-x86/syscalls/chmod.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_chmod, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/chown.S b/libc/arch-x86/syscalls/chown.S
index 800bf04..df3f259 100644
--- a/libc/arch-x86/syscalls/chown.S
+++ b/libc/arch-x86/syscalls/chown.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_chown32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/chroot.S b/libc/arch-x86/syscalls/chroot.S
index 24d2d10..35a37a9 100644
--- a/libc/arch-x86/syscalls/chroot.S
+++ b/libc/arch-x86/syscalls/chroot.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_chroot, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/clock_getres.S b/libc/arch-x86/syscalls/clock_getres.S
index da332aa..543887b 100644
--- a/libc/arch-x86/syscalls/clock_getres.S
+++ b/libc/arch-x86/syscalls/clock_getres.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_clock_getres, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/clock_gettime.S b/libc/arch-x86/syscalls/clock_gettime.S
index 41ac5e2..38a8ec9 100644
--- a/libc/arch-x86/syscalls/clock_gettime.S
+++ b/libc/arch-x86/syscalls/clock_gettime.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_clock_gettime, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/clock_nanosleep.S b/libc/arch-x86/syscalls/clock_nanosleep.S
index cd163df..94f7c39 100644
--- a/libc/arch-x86/syscalls/clock_nanosleep.S
+++ b/libc/arch-x86/syscalls/clock_nanosleep.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_clock_nanosleep, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/clock_settime.S b/libc/arch-x86/syscalls/clock_settime.S
index 18237c4..f82aa78 100644
--- a/libc/arch-x86/syscalls/clock_settime.S
+++ b/libc/arch-x86/syscalls/clock_settime.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_clock_settime, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/close.S b/libc/arch-x86/syscalls/close.S
index 76175c7..b9c7961 100644
--- a/libc/arch-x86/syscalls/close.S
+++ b/libc/arch-x86/syscalls/close.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_close, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/connect.S b/libc/arch-x86/syscalls/connect.S
index e87b123..3298e08 100644
--- a/libc/arch-x86/syscalls/connect.S
+++ b/libc/arch-x86/syscalls/connect.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/delete_module.S b/libc/arch-x86/syscalls/delete_module.S
index 10a06a3..92b6446 100644
--- a/libc/arch-x86/syscalls/delete_module.S
+++ b/libc/arch-x86/syscalls/delete_module.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_delete_module, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/dup.S b/libc/arch-x86/syscalls/dup.S
index 80259fe..b3de1fb 100644
--- a/libc/arch-x86/syscalls/dup.S
+++ b/libc/arch-x86/syscalls/dup.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_dup, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/dup2.S b/libc/arch-x86/syscalls/dup2.S
index 43def66..7558f56 100644
--- a/libc/arch-x86/syscalls/dup2.S
+++ b/libc/arch-x86/syscalls/dup2.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_dup2, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/epoll_create.S b/libc/arch-x86/syscalls/epoll_create.S
index 0bdc885..010473a 100644
--- a/libc/arch-x86/syscalls/epoll_create.S
+++ b/libc/arch-x86/syscalls/epoll_create.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_epoll_create, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/epoll_ctl.S b/libc/arch-x86/syscalls/epoll_ctl.S
index 43175d2..4a87900 100644
--- a/libc/arch-x86/syscalls/epoll_ctl.S
+++ b/libc/arch-x86/syscalls/epoll_ctl.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_epoll_ctl, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/epoll_wait.S b/libc/arch-x86/syscalls/epoll_wait.S
index e2d61c0..616f735 100644
--- a/libc/arch-x86/syscalls/epoll_wait.S
+++ b/libc/arch-x86/syscalls/epoll_wait.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_epoll_wait, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/eventfd.S b/libc/arch-x86/syscalls/eventfd.S
index 338696f..4ad4cea 100644
--- a/libc/arch-x86/syscalls/eventfd.S
+++ b/libc/arch-x86/syscalls/eventfd.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_eventfd2, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/execve.S b/libc/arch-x86/syscalls/execve.S
index c7e3ca5..82922a3 100644
--- a/libc/arch-x86/syscalls/execve.S
+++ b/libc/arch-x86/syscalls/execve.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_execve, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/faccessat.S b/libc/arch-x86/syscalls/faccessat.S
index 6733029..2756265 100644
--- a/libc/arch-x86/syscalls/faccessat.S
+++ b/libc/arch-x86/syscalls/faccessat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_faccessat, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fchdir.S b/libc/arch-x86/syscalls/fchdir.S
index 23aa6e2..9badf6f 100644
--- a/libc/arch-x86/syscalls/fchdir.S
+++ b/libc/arch-x86/syscalls/fchdir.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_fchdir, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fchmod.S b/libc/arch-x86/syscalls/fchmod.S
index 019eb07..4cf79cc 100644
--- a/libc/arch-x86/syscalls/fchmod.S
+++ b/libc/arch-x86/syscalls/fchmod.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_fchmod, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fchmodat.S b/libc/arch-x86/syscalls/fchmodat.S
index f7292f9..b91fdf7 100644
--- a/libc/arch-x86/syscalls/fchmodat.S
+++ b/libc/arch-x86/syscalls/fchmodat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_fchmodat, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fchown.S b/libc/arch-x86/syscalls/fchown.S
index f17c0d6..f5f6849 100644
--- a/libc/arch-x86/syscalls/fchown.S
+++ b/libc/arch-x86/syscalls/fchown.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_fchown32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fchownat.S b/libc/arch-x86/syscalls/fchownat.S
index 7648d79..183ae1d 100644
--- a/libc/arch-x86/syscalls/fchownat.S
+++ b/libc/arch-x86/syscalls/fchownat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_fchownat, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fdatasync.S b/libc/arch-x86/syscalls/fdatasync.S
index 2808e0f..73811a5 100644
--- a/libc/arch-x86/syscalls/fdatasync.S
+++ b/libc/arch-x86/syscalls/fdatasync.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_fdatasync, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fgetxattr.S b/libc/arch-x86/syscalls/fgetxattr.S
index beaab09..dc6c457 100644
--- a/libc/arch-x86/syscalls/fgetxattr.S
+++ b/libc/arch-x86/syscalls/fgetxattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_fgetxattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/flistxattr.S b/libc/arch-x86/syscalls/flistxattr.S
index 95935c0..bcef232 100644
--- a/libc/arch-x86/syscalls/flistxattr.S
+++ b/libc/arch-x86/syscalls/flistxattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_flistxattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/flock.S b/libc/arch-x86/syscalls/flock.S
index 156844c..e73f1b6 100644
--- a/libc/arch-x86/syscalls/flock.S
+++ b/libc/arch-x86/syscalls/flock.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_flock, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fremovexattr.S b/libc/arch-x86/syscalls/fremovexattr.S
index 32d0bdc..0535938 100644
--- a/libc/arch-x86/syscalls/fremovexattr.S
+++ b/libc/arch-x86/syscalls/fremovexattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_fremovexattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fsetxattr.S b/libc/arch-x86/syscalls/fsetxattr.S
index c3d588e..3a88be8 100644
--- a/libc/arch-x86/syscalls/fsetxattr.S
+++ b/libc/arch-x86/syscalls/fsetxattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_fsetxattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fstat.S b/libc/arch-x86/syscalls/fstat.S
index 95301d9..4969b00 100644
--- a/libc/arch-x86/syscalls/fstat.S
+++ b/libc/arch-x86/syscalls/fstat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_fstat64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fstatat.S b/libc/arch-x86/syscalls/fstatat.S
index 947f4da..0bae34f 100644
--- a/libc/arch-x86/syscalls/fstatat.S
+++ b/libc/arch-x86/syscalls/fstatat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_fstatat64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/fsync.S b/libc/arch-x86/syscalls/fsync.S
index 363b334..6cf6ee8 100644
--- a/libc/arch-x86/syscalls/fsync.S
+++ b/libc/arch-x86/syscalls/fsync.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_fsync, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/ftruncate.S b/libc/arch-x86/syscalls/ftruncate.S
index 1ed3f96..ff3e945 100644
--- a/libc/arch-x86/syscalls/ftruncate.S
+++ b/libc/arch-x86/syscalls/ftruncate.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_ftruncate, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/ftruncate64.S b/libc/arch-x86/syscalls/ftruncate64.S
index fa6dbef..fe23a41 100644
--- a/libc/arch-x86/syscalls/ftruncate64.S
+++ b/libc/arch-x86/syscalls/ftruncate64.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_ftruncate64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/futex.S b/libc/arch-x86/syscalls/futex.S
index f72be1b..b21da36 100644
--- a/libc/arch-x86/syscalls/futex.S
+++ b/libc/arch-x86/syscalls/futex.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -17,7 +18,7 @@
     mov     48(%esp), %ebp
     movl    $__NR_futex, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getdents.S b/libc/arch-x86/syscalls/getdents.S
index c5d2721..baef233 100644
--- a/libc/arch-x86/syscalls/getdents.S
+++ b/libc/arch-x86/syscalls/getdents.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_getdents64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getegid.S b/libc/arch-x86/syscalls/getegid.S
index c26ebc2..4dc0678 100644
--- a/libc/arch-x86/syscalls/getegid.S
+++ b/libc/arch-x86/syscalls/getegid.S
@@ -1,11 +1,12 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
 ENTRY(getegid)
     movl    $__NR_getegid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/geteuid.S b/libc/arch-x86/syscalls/geteuid.S
index a7761e8..a2c4029 100644
--- a/libc/arch-x86/syscalls/geteuid.S
+++ b/libc/arch-x86/syscalls/geteuid.S
@@ -1,11 +1,12 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
 ENTRY(geteuid)
     movl    $__NR_geteuid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getgid.S b/libc/arch-x86/syscalls/getgid.S
index 7a51200..8885cf9 100644
--- a/libc/arch-x86/syscalls/getgid.S
+++ b/libc/arch-x86/syscalls/getgid.S
@@ -1,11 +1,12 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
 ENTRY(getgid)
     movl    $__NR_getgid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getgroups.S b/libc/arch-x86/syscalls/getgroups.S
index 35bc3f5..3e580e3 100644
--- a/libc/arch-x86/syscalls/getgroups.S
+++ b/libc/arch-x86/syscalls/getgroups.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_getgroups32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getitimer.S b/libc/arch-x86/syscalls/getitimer.S
index 79957da..40e984b 100644
--- a/libc/arch-x86/syscalls/getitimer.S
+++ b/libc/arch-x86/syscalls/getitimer.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_getitimer, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getpeername.S b/libc/arch-x86/syscalls/getpeername.S
index 3831990..854cf9f 100644
--- a/libc/arch-x86/syscalls/getpeername.S
+++ b/libc/arch-x86/syscalls/getpeername.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getpgid.S b/libc/arch-x86/syscalls/getpgid.S
index f49abbf..990af58 100644
--- a/libc/arch-x86/syscalls/getpgid.S
+++ b/libc/arch-x86/syscalls/getpgid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_getpgid, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getpid.S b/libc/arch-x86/syscalls/getpid.S
index 29703e8..3f4406e 100644
--- a/libc/arch-x86/syscalls/getpid.S
+++ b/libc/arch-x86/syscalls/getpid.S
@@ -1,11 +1,12 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
 ENTRY(getpid)
     movl    $__NR_getpid, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getppid.S b/libc/arch-x86/syscalls/getppid.S
index dc89d6e..f1f3f6b 100644
--- a/libc/arch-x86/syscalls/getppid.S
+++ b/libc/arch-x86/syscalls/getppid.S
@@ -1,11 +1,12 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
 ENTRY(getppid)
     movl    $__NR_getppid, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getresgid.S b/libc/arch-x86/syscalls/getresgid.S
index 08a37e7..bac8f59 100644
--- a/libc/arch-x86/syscalls/getresgid.S
+++ b/libc/arch-x86/syscalls/getresgid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_getresgid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getresuid.S b/libc/arch-x86/syscalls/getresuid.S
index 435a901..e78c835 100644
--- a/libc/arch-x86/syscalls/getresuid.S
+++ b/libc/arch-x86/syscalls/getresuid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_getresuid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getrlimit.S b/libc/arch-x86/syscalls/getrlimit.S
index 8f6edd6..4c3e56e 100644
--- a/libc/arch-x86/syscalls/getrlimit.S
+++ b/libc/arch-x86/syscalls/getrlimit.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_ugetrlimit, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getrusage.S b/libc/arch-x86/syscalls/getrusage.S
index ee47f3d..90d58ba 100644
--- a/libc/arch-x86/syscalls/getrusage.S
+++ b/libc/arch-x86/syscalls/getrusage.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_getrusage, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getsid.S b/libc/arch-x86/syscalls/getsid.S
index 876bf6a..4cb8182 100644
--- a/libc/arch-x86/syscalls/getsid.S
+++ b/libc/arch-x86/syscalls/getsid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_getsid, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getsockname.S b/libc/arch-x86/syscalls/getsockname.S
index b28ecb8..931bf79 100644
--- a/libc/arch-x86/syscalls/getsockname.S
+++ b/libc/arch-x86/syscalls/getsockname.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getsockopt.S b/libc/arch-x86/syscalls/getsockopt.S
index 190b6f2..ffd4730 100644
--- a/libc/arch-x86/syscalls/getsockopt.S
+++ b/libc/arch-x86/syscalls/getsockopt.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/gettid.S b/libc/arch-x86/syscalls/gettid.S
index c1e6ba0..5e6d65e 100644
--- a/libc/arch-x86/syscalls/gettid.S
+++ b/libc/arch-x86/syscalls/gettid.S
@@ -1,11 +1,12 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
 ENTRY(gettid)
     movl    $__NR_gettid, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/gettimeofday.S b/libc/arch-x86/syscalls/gettimeofday.S
index 34b9982..142faa3 100644
--- a/libc/arch-x86/syscalls/gettimeofday.S
+++ b/libc/arch-x86/syscalls/gettimeofday.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_gettimeofday, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getuid.S b/libc/arch-x86/syscalls/getuid.S
index e82b8b0..9aa8bc6 100644
--- a/libc/arch-x86/syscalls/getuid.S
+++ b/libc/arch-x86/syscalls/getuid.S
@@ -1,11 +1,12 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
 ENTRY(getuid)
     movl    $__NR_getuid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/getxattr.S b/libc/arch-x86/syscalls/getxattr.S
index 92f7c30..e3d9edc 100644
--- a/libc/arch-x86/syscalls/getxattr.S
+++ b/libc/arch-x86/syscalls/getxattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_getxattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/init_module.S b/libc/arch-x86/syscalls/init_module.S
index 3ef9b36..74ebfe8 100644
--- a/libc/arch-x86/syscalls/init_module.S
+++ b/libc/arch-x86/syscalls/init_module.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_init_module, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/inotify_add_watch.S b/libc/arch-x86/syscalls/inotify_add_watch.S
index 7b57f3c..58a6fd4 100644
--- a/libc/arch-x86/syscalls/inotify_add_watch.S
+++ b/libc/arch-x86/syscalls/inotify_add_watch.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_inotify_add_watch, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/inotify_init.S b/libc/arch-x86/syscalls/inotify_init.S
index c19174b..66b3a65 100644
--- a/libc/arch-x86/syscalls/inotify_init.S
+++ b/libc/arch-x86/syscalls/inotify_init.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_inotify_init, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/inotify_rm_watch.S b/libc/arch-x86/syscalls/inotify_rm_watch.S
index 351bdc2..4db5799 100644
--- a/libc/arch-x86/syscalls/inotify_rm_watch.S
+++ b/libc/arch-x86/syscalls/inotify_rm_watch.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_inotify_rm_watch, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/ioprio_get.S b/libc/arch-x86/syscalls/ioprio_get.S
index b64662f..7c6daa3 100644
--- a/libc/arch-x86/syscalls/ioprio_get.S
+++ b/libc/arch-x86/syscalls/ioprio_get.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_ioprio_get, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/ioprio_set.S b/libc/arch-x86/syscalls/ioprio_set.S
index 6f2a4f3..4be460e 100644
--- a/libc/arch-x86/syscalls/ioprio_set.S
+++ b/libc/arch-x86/syscalls/ioprio_set.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_ioprio_set, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/kill.S b/libc/arch-x86/syscalls/kill.S
index 99fe9a9..7c7dcb9 100644
--- a/libc/arch-x86/syscalls/kill.S
+++ b/libc/arch-x86/syscalls/kill.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_kill, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/klogctl.S b/libc/arch-x86/syscalls/klogctl.S
index e9f8b79..e6cac00 100644
--- a/libc/arch-x86/syscalls/klogctl.S
+++ b/libc/arch-x86/syscalls/klogctl.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_syslog, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/lchown.S b/libc/arch-x86/syscalls/lchown.S
index 779f703..471c51f 100644
--- a/libc/arch-x86/syscalls/lchown.S
+++ b/libc/arch-x86/syscalls/lchown.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_lchown32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/lgetxattr.S b/libc/arch-x86/syscalls/lgetxattr.S
index 3781bff..0997262 100644
--- a/libc/arch-x86/syscalls/lgetxattr.S
+++ b/libc/arch-x86/syscalls/lgetxattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_lgetxattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/link.S b/libc/arch-x86/syscalls/link.S
index dac7d0e..96b8edc 100644
--- a/libc/arch-x86/syscalls/link.S
+++ b/libc/arch-x86/syscalls/link.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_link, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/listen.S b/libc/arch-x86/syscalls/listen.S
index 8f63945..bf1aa77 100644
--- a/libc/arch-x86/syscalls/listen.S
+++ b/libc/arch-x86/syscalls/listen.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/listxattr.S b/libc/arch-x86/syscalls/listxattr.S
index 853c47b..ae8d351 100644
--- a/libc/arch-x86/syscalls/listxattr.S
+++ b/libc/arch-x86/syscalls/listxattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_listxattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/llistxattr.S b/libc/arch-x86/syscalls/llistxattr.S
index cd7038b..22fb6a9 100644
--- a/libc/arch-x86/syscalls/llistxattr.S
+++ b/libc/arch-x86/syscalls/llistxattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_llistxattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/lremovexattr.S b/libc/arch-x86/syscalls/lremovexattr.S
index 93973d6..3deae95 100644
--- a/libc/arch-x86/syscalls/lremovexattr.S
+++ b/libc/arch-x86/syscalls/lremovexattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_lremovexattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/lseek.S b/libc/arch-x86/syscalls/lseek.S
index f6250e6..d62983f 100644
--- a/libc/arch-x86/syscalls/lseek.S
+++ b/libc/arch-x86/syscalls/lseek.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_lseek, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/lsetxattr.S b/libc/arch-x86/syscalls/lsetxattr.S
index c5dbc30..f8f50aa 100644
--- a/libc/arch-x86/syscalls/lsetxattr.S
+++ b/libc/arch-x86/syscalls/lsetxattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_lsetxattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/lstat.S b/libc/arch-x86/syscalls/lstat.S
index 4e25fae..dc2a36c 100644
--- a/libc/arch-x86/syscalls/lstat.S
+++ b/libc/arch-x86/syscalls/lstat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_lstat64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/madvise.S b/libc/arch-x86/syscalls/madvise.S
index bf3e5dc..a2827eb 100644
--- a/libc/arch-x86/syscalls/madvise.S
+++ b/libc/arch-x86/syscalls/madvise.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_madvise, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/mincore.S b/libc/arch-x86/syscalls/mincore.S
index 37df639..0b6e129 100644
--- a/libc/arch-x86/syscalls/mincore.S
+++ b/libc/arch-x86/syscalls/mincore.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_mincore, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/mkdir.S b/libc/arch-x86/syscalls/mkdir.S
index 16a5c03..3256aff 100644
--- a/libc/arch-x86/syscalls/mkdir.S
+++ b/libc/arch-x86/syscalls/mkdir.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_mkdir, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/mkdirat.S b/libc/arch-x86/syscalls/mkdirat.S
index ece2c27..9d872b1 100644
--- a/libc/arch-x86/syscalls/mkdirat.S
+++ b/libc/arch-x86/syscalls/mkdirat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_mkdirat, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/mknod.S b/libc/arch-x86/syscalls/mknod.S
index 22fc390..ad06357 100644
--- a/libc/arch-x86/syscalls/mknod.S
+++ b/libc/arch-x86/syscalls/mknod.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_mknod, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/mlock.S b/libc/arch-x86/syscalls/mlock.S
index 5010e00..c078138 100644
--- a/libc/arch-x86/syscalls/mlock.S
+++ b/libc/arch-x86/syscalls/mlock.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_mlock, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/mlockall.S b/libc/arch-x86/syscalls/mlockall.S
index 849b44f..8251117 100644
--- a/libc/arch-x86/syscalls/mlockall.S
+++ b/libc/arch-x86/syscalls/mlockall.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_mlockall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/mount.S b/libc/arch-x86/syscalls/mount.S
index 9ceeab9..e57c54d 100644
--- a/libc/arch-x86/syscalls/mount.S
+++ b/libc/arch-x86/syscalls/mount.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_mount, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/mprotect.S b/libc/arch-x86/syscalls/mprotect.S
index 4438bfe..c5b414a 100644
--- a/libc/arch-x86/syscalls/mprotect.S
+++ b/libc/arch-x86/syscalls/mprotect.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_mprotect, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/mremap.S b/libc/arch-x86/syscalls/mremap.S
index d33a8dc..ca40fd3 100644
--- a/libc/arch-x86/syscalls/mremap.S
+++ b/libc/arch-x86/syscalls/mremap.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_mremap, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/msync.S b/libc/arch-x86/syscalls/msync.S
index 2da5bc7..3eb8014 100644
--- a/libc/arch-x86/syscalls/msync.S
+++ b/libc/arch-x86/syscalls/msync.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_msync, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/munlock.S b/libc/arch-x86/syscalls/munlock.S
index 574d17b..20249f9 100644
--- a/libc/arch-x86/syscalls/munlock.S
+++ b/libc/arch-x86/syscalls/munlock.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_munlock, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/munlockall.S b/libc/arch-x86/syscalls/munlockall.S
index f69316a..18275ca 100644
--- a/libc/arch-x86/syscalls/munlockall.S
+++ b/libc/arch-x86/syscalls/munlockall.S
@@ -1,11 +1,12 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
 ENTRY(munlockall)
     movl    $__NR_munlockall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/munmap.S b/libc/arch-x86/syscalls/munmap.S
index 91c73c1..22f3549 100644
--- a/libc/arch-x86/syscalls/munmap.S
+++ b/libc/arch-x86/syscalls/munmap.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_munmap, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/nanosleep.S b/libc/arch-x86/syscalls/nanosleep.S
index 6d2df08..dc14121 100644
--- a/libc/arch-x86/syscalls/nanosleep.S
+++ b/libc/arch-x86/syscalls/nanosleep.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_nanosleep, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/pause.S b/libc/arch-x86/syscalls/pause.S
index 70be691..8bc21d1 100644
--- a/libc/arch-x86/syscalls/pause.S
+++ b/libc/arch-x86/syscalls/pause.S
@@ -1,11 +1,12 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
 ENTRY(pause)
     movl    $__NR_pause, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/perf_event_open.S b/libc/arch-x86/syscalls/perf_event_open.S
index 6466b45..e1ec6d8 100644
--- a/libc/arch-x86/syscalls/perf_event_open.S
+++ b/libc/arch-x86/syscalls/perf_event_open.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_perf_event_open, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/personality.S b/libc/arch-x86/syscalls/personality.S
index b23b592..7ae3dfb 100644
--- a/libc/arch-x86/syscalls/personality.S
+++ b/libc/arch-x86/syscalls/personality.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_personality, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/pipe.S b/libc/arch-x86/syscalls/pipe.S
index 1560bad..583e868 100644
--- a/libc/arch-x86/syscalls/pipe.S
+++ b/libc/arch-x86/syscalls/pipe.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_pipe, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/pipe2.S b/libc/arch-x86/syscalls/pipe2.S
index 55fe08f..12a8033 100644
--- a/libc/arch-x86/syscalls/pipe2.S
+++ b/libc/arch-x86/syscalls/pipe2.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_pipe2, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/poll.S b/libc/arch-x86/syscalls/poll.S
index 541d657..7d7608a 100644
--- a/libc/arch-x86/syscalls/poll.S
+++ b/libc/arch-x86/syscalls/poll.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_poll, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/prctl.S b/libc/arch-x86/syscalls/prctl.S
index 56720fe..f8dcc28 100644
--- a/libc/arch-x86/syscalls/prctl.S
+++ b/libc/arch-x86/syscalls/prctl.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_prctl, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/pread64.S b/libc/arch-x86/syscalls/pread64.S
index 987e9b8..ff12f55 100644
--- a/libc/arch-x86/syscalls/pread64.S
+++ b/libc/arch-x86/syscalls/pread64.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_pread64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/pwrite64.S b/libc/arch-x86/syscalls/pwrite64.S
index 8773a20..6c00508 100644
--- a/libc/arch-x86/syscalls/pwrite64.S
+++ b/libc/arch-x86/syscalls/pwrite64.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_pwrite64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/read.S b/libc/arch-x86/syscalls/read.S
index 98b7c12..be63487 100644
--- a/libc/arch-x86/syscalls/read.S
+++ b/libc/arch-x86/syscalls/read.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_read, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/readahead.S b/libc/arch-x86/syscalls/readahead.S
index b0c0018..78584cc 100644
--- a/libc/arch-x86/syscalls/readahead.S
+++ b/libc/arch-x86/syscalls/readahead.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_readahead, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/readlink.S b/libc/arch-x86/syscalls/readlink.S
index 393b5d4..e75a2c0 100644
--- a/libc/arch-x86/syscalls/readlink.S
+++ b/libc/arch-x86/syscalls/readlink.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_readlink, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/readv.S b/libc/arch-x86/syscalls/readv.S
index d626068..699295d 100644
--- a/libc/arch-x86/syscalls/readv.S
+++ b/libc/arch-x86/syscalls/readv.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_readv, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/recvfrom.S b/libc/arch-x86/syscalls/recvfrom.S
index 98558e1..acbc166 100644
--- a/libc/arch-x86/syscalls/recvfrom.S
+++ b/libc/arch-x86/syscalls/recvfrom.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/recvmsg.S b/libc/arch-x86/syscalls/recvmsg.S
index 8b3c7bd..b85abb5 100644
--- a/libc/arch-x86/syscalls/recvmsg.S
+++ b/libc/arch-x86/syscalls/recvmsg.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/removexattr.S b/libc/arch-x86/syscalls/removexattr.S
index e2211e8..c0af7e7 100644
--- a/libc/arch-x86/syscalls/removexattr.S
+++ b/libc/arch-x86/syscalls/removexattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_removexattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/rename.S b/libc/arch-x86/syscalls/rename.S
index 43be210..955bb74 100644
--- a/libc/arch-x86/syscalls/rename.S
+++ b/libc/arch-x86/syscalls/rename.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_rename, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/renameat.S b/libc/arch-x86/syscalls/renameat.S
index 8084045..d4b9f24 100644
--- a/libc/arch-x86/syscalls/renameat.S
+++ b/libc/arch-x86/syscalls/renameat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_renameat, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/rmdir.S b/libc/arch-x86/syscalls/rmdir.S
index b16375c..a9025b0 100644
--- a/libc/arch-x86/syscalls/rmdir.S
+++ b/libc/arch-x86/syscalls/rmdir.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_rmdir, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sched_get_priority_max.S b/libc/arch-x86/syscalls/sched_get_priority_max.S
index 713b02d..281f4d7 100644
--- a/libc/arch-x86/syscalls/sched_get_priority_max.S
+++ b/libc/arch-x86/syscalls/sched_get_priority_max.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_sched_get_priority_max, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sched_get_priority_min.S b/libc/arch-x86/syscalls/sched_get_priority_min.S
index de6768f..41b2e65 100644
--- a/libc/arch-x86/syscalls/sched_get_priority_min.S
+++ b/libc/arch-x86/syscalls/sched_get_priority_min.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_sched_get_priority_min, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sched_getparam.S b/libc/arch-x86/syscalls/sched_getparam.S
index eabc562..131d919 100644
--- a/libc/arch-x86/syscalls/sched_getparam.S
+++ b/libc/arch-x86/syscalls/sched_getparam.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_sched_getparam, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sched_getscheduler.S b/libc/arch-x86/syscalls/sched_getscheduler.S
index 2a6c8f7..da8578b 100644
--- a/libc/arch-x86/syscalls/sched_getscheduler.S
+++ b/libc/arch-x86/syscalls/sched_getscheduler.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_sched_getscheduler, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sched_rr_get_interval.S b/libc/arch-x86/syscalls/sched_rr_get_interval.S
index 3f032d5..3ce976a 100644
--- a/libc/arch-x86/syscalls/sched_rr_get_interval.S
+++ b/libc/arch-x86/syscalls/sched_rr_get_interval.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_sched_rr_get_interval, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sched_setaffinity.S b/libc/arch-x86/syscalls/sched_setaffinity.S
index 988f6b4..89b42eb 100644
--- a/libc/arch-x86/syscalls/sched_setaffinity.S
+++ b/libc/arch-x86/syscalls/sched_setaffinity.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_sched_setaffinity, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sched_setparam.S b/libc/arch-x86/syscalls/sched_setparam.S
index a250783..4327d04 100644
--- a/libc/arch-x86/syscalls/sched_setparam.S
+++ b/libc/arch-x86/syscalls/sched_setparam.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_sched_setparam, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sched_setscheduler.S b/libc/arch-x86/syscalls/sched_setscheduler.S
index c6851ba..9fdb5e6 100644
--- a/libc/arch-x86/syscalls/sched_setscheduler.S
+++ b/libc/arch-x86/syscalls/sched_setscheduler.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_sched_setscheduler, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sched_yield.S b/libc/arch-x86/syscalls/sched_yield.S
index 3dcc7fc..774aca4 100644
--- a/libc/arch-x86/syscalls/sched_yield.S
+++ b/libc/arch-x86/syscalls/sched_yield.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_sched_yield, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/select.S b/libc/arch-x86/syscalls/select.S
index b665281..9943618 100644
--- a/libc/arch-x86/syscalls/select.S
+++ b/libc/arch-x86/syscalls/select.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR__newselect, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sendfile.S b/libc/arch-x86/syscalls/sendfile.S
index b36fa1f..b2dd94b 100644
--- a/libc/arch-x86/syscalls/sendfile.S
+++ b/libc/arch-x86/syscalls/sendfile.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_sendfile, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sendmsg.S b/libc/arch-x86/syscalls/sendmsg.S
index 119d632..93b5047 100644
--- a/libc/arch-x86/syscalls/sendmsg.S
+++ b/libc/arch-x86/syscalls/sendmsg.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sendto.S b/libc/arch-x86/syscalls/sendto.S
index 82208fe..b0ecd86 100644
--- a/libc/arch-x86/syscalls/sendto.S
+++ b/libc/arch-x86/syscalls/sendto.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setgid.S b/libc/arch-x86/syscalls/setgid.S
index 37f5ffe..853fea3 100644
--- a/libc/arch-x86/syscalls/setgid.S
+++ b/libc/arch-x86/syscalls/setgid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_setgid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setgroups.S b/libc/arch-x86/syscalls/setgroups.S
index 20266e0..e68a971 100644
--- a/libc/arch-x86/syscalls/setgroups.S
+++ b/libc/arch-x86/syscalls/setgroups.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_setgroups32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setitimer.S b/libc/arch-x86/syscalls/setitimer.S
index 97ee7c6..246e8da 100644
--- a/libc/arch-x86/syscalls/setitimer.S
+++ b/libc/arch-x86/syscalls/setitimer.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_setitimer, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setpgid.S b/libc/arch-x86/syscalls/setpgid.S
index 8ff9273..878662b 100644
--- a/libc/arch-x86/syscalls/setpgid.S
+++ b/libc/arch-x86/syscalls/setpgid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_setpgid, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setpriority.S b/libc/arch-x86/syscalls/setpriority.S
index 7358a89..65ba7d5 100644
--- a/libc/arch-x86/syscalls/setpriority.S
+++ b/libc/arch-x86/syscalls/setpriority.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_setpriority, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setregid.S b/libc/arch-x86/syscalls/setregid.S
index bbe092f..58a5afd 100644
--- a/libc/arch-x86/syscalls/setregid.S
+++ b/libc/arch-x86/syscalls/setregid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_setregid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setresgid.S b/libc/arch-x86/syscalls/setresgid.S
index c235837..efda6e6 100644
--- a/libc/arch-x86/syscalls/setresgid.S
+++ b/libc/arch-x86/syscalls/setresgid.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_setresgid32, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setrlimit.S b/libc/arch-x86/syscalls/setrlimit.S
index d7f5072..b73faaf 100644
--- a/libc/arch-x86/syscalls/setrlimit.S
+++ b/libc/arch-x86/syscalls/setrlimit.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_setrlimit, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setsid.S b/libc/arch-x86/syscalls/setsid.S
index 684b304..59b3bbb 100644
--- a/libc/arch-x86/syscalls/setsid.S
+++ b/libc/arch-x86/syscalls/setsid.S
@@ -1,11 +1,12 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
 ENTRY(setsid)
     movl    $__NR_setsid, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setsockopt.S b/libc/arch-x86/syscalls/setsockopt.S
index 9c70116..486e9eb 100644
--- a/libc/arch-x86/syscalls/setsockopt.S
+++ b/libc/arch-x86/syscalls/setsockopt.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/settimeofday.S b/libc/arch-x86/syscalls/settimeofday.S
index bc95fec..616b551 100644
--- a/libc/arch-x86/syscalls/settimeofday.S
+++ b/libc/arch-x86/syscalls/settimeofday.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_settimeofday, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/setxattr.S b/libc/arch-x86/syscalls/setxattr.S
index 9dc87e3..30752f8 100644
--- a/libc/arch-x86/syscalls/setxattr.S
+++ b/libc/arch-x86/syscalls/setxattr.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -15,7 +16,7 @@
     mov     40(%esp), %edi
     movl    $__NR_setxattr, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/shutdown.S b/libc/arch-x86/syscalls/shutdown.S
index 7fa36a1..697107c 100644
--- a/libc/arch-x86/syscalls/shutdown.S
+++ b/libc/arch-x86/syscalls/shutdown.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sigaction.S b/libc/arch-x86/syscalls/sigaction.S
index 4fd5993..7f2cfd1 100644
--- a/libc/arch-x86/syscalls/sigaction.S
+++ b/libc/arch-x86/syscalls/sigaction.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_sigaction, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sigaltstack.S b/libc/arch-x86/syscalls/sigaltstack.S
index 830c99f..6adf9a7 100644
--- a/libc/arch-x86/syscalls/sigaltstack.S
+++ b/libc/arch-x86/syscalls/sigaltstack.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_sigaltstack, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/signalfd4.S b/libc/arch-x86/syscalls/signalfd4.S
index 57e0233..a2c7527 100644
--- a/libc/arch-x86/syscalls/signalfd4.S
+++ b/libc/arch-x86/syscalls/signalfd4.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_signalfd4, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sigpending.S b/libc/arch-x86/syscalls/sigpending.S
index 2f009b2..34af79d 100644
--- a/libc/arch-x86/syscalls/sigpending.S
+++ b/libc/arch-x86/syscalls/sigpending.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_sigpending, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sigprocmask.S b/libc/arch-x86/syscalls/sigprocmask.S
index 81cdfa2..12390a5 100644
--- a/libc/arch-x86/syscalls/sigprocmask.S
+++ b/libc/arch-x86/syscalls/sigprocmask.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_sigprocmask, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/socket.S b/libc/arch-x86/syscalls/socket.S
index 8cc93bd..c9f63b0 100644
--- a/libc/arch-x86/syscalls/socket.S
+++ b/libc/arch-x86/syscalls/socket.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/socketpair.S b/libc/arch-x86/syscalls/socketpair.S
index ccfc847..6ea3edc 100644
--- a/libc/arch-x86/syscalls/socketpair.S
+++ b/libc/arch-x86/syscalls/socketpair.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -10,7 +11,7 @@
     addl    $12, %ecx
     movl    $__NR_socketcall, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/stat.S b/libc/arch-x86/syscalls/stat.S
index 83d1af8..cd2d291 100644
--- a/libc/arch-x86/syscalls/stat.S
+++ b/libc/arch-x86/syscalls/stat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_stat64, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/symlink.S b/libc/arch-x86/syscalls/symlink.S
index dbc5490..86415f1 100644
--- a/libc/arch-x86/syscalls/symlink.S
+++ b/libc/arch-x86/syscalls/symlink.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_symlink, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sync.S b/libc/arch-x86/syscalls/sync.S
index f337c2c..2126a6a 100644
--- a/libc/arch-x86/syscalls/sync.S
+++ b/libc/arch-x86/syscalls/sync.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_sync, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/sysinfo.S b/libc/arch-x86/syscalls/sysinfo.S
index ef9fcb0..42dcea3 100644
--- a/libc/arch-x86/syscalls/sysinfo.S
+++ b/libc/arch-x86/syscalls/sysinfo.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_sysinfo, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/tgkill.S b/libc/arch-x86/syscalls/tgkill.S
index 6d5dc88..ad7a94a 100644
--- a/libc/arch-x86/syscalls/tgkill.S
+++ b/libc/arch-x86/syscalls/tgkill.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_tgkill, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/times.S b/libc/arch-x86/syscalls/times.S
index 04991a8..b4dec25 100644
--- a/libc/arch-x86/syscalls/times.S
+++ b/libc/arch-x86/syscalls/times.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_times, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/tkill.S b/libc/arch-x86/syscalls/tkill.S
index 51eb1c8..89ece49 100644
--- a/libc/arch-x86/syscalls/tkill.S
+++ b/libc/arch-x86/syscalls/tkill.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_tkill, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/truncate.S b/libc/arch-x86/syscalls/truncate.S
index 9e9b08d..60f30eb 100644
--- a/libc/arch-x86/syscalls/truncate.S
+++ b/libc/arch-x86/syscalls/truncate.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_truncate, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/umask.S b/libc/arch-x86/syscalls/umask.S
index f2bf7b0..4942c43 100644
--- a/libc/arch-x86/syscalls/umask.S
+++ b/libc/arch-x86/syscalls/umask.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_umask, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/umount2.S b/libc/arch-x86/syscalls/umount2.S
index 1949489..3c54150 100644
--- a/libc/arch-x86/syscalls/umount2.S
+++ b/libc/arch-x86/syscalls/umount2.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_umount2, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/uname.S b/libc/arch-x86/syscalls/uname.S
index 9b2c746..310ac7f 100644
--- a/libc/arch-x86/syscalls/uname.S
+++ b/libc/arch-x86/syscalls/uname.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_uname, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/unlink.S b/libc/arch-x86/syscalls/unlink.S
index 0d9ce84..d58bfb8 100644
--- a/libc/arch-x86/syscalls/unlink.S
+++ b/libc/arch-x86/syscalls/unlink.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_unlink, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/unlinkat.S b/libc/arch-x86/syscalls/unlinkat.S
index d05b488..85499c2 100644
--- a/libc/arch-x86/syscalls/unlinkat.S
+++ b/libc/arch-x86/syscalls/unlinkat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_unlinkat, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/unshare.S b/libc/arch-x86/syscalls/unshare.S
index da0f563..883ad40 100644
--- a/libc/arch-x86/syscalls/unshare.S
+++ b/libc/arch-x86/syscalls/unshare.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -7,7 +8,7 @@
     mov     8(%esp), %ebx
     movl    $__NR_unshare, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/utimensat.S b/libc/arch-x86/syscalls/utimensat.S
index fb1d630..739d486 100644
--- a/libc/arch-x86/syscalls/utimensat.S
+++ b/libc/arch-x86/syscalls/utimensat.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -13,7 +14,7 @@
     mov     32(%esp), %esi
     movl    $__NR_utimensat, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/utimes.S b/libc/arch-x86/syscalls/utimes.S
index 189f6b9..b6c6036 100644
--- a/libc/arch-x86/syscalls/utimes.S
+++ b/libc/arch-x86/syscalls/utimes.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -9,7 +10,7 @@
     mov     16(%esp), %ecx
     movl    $__NR_utimes, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/write.S b/libc/arch-x86/syscalls/write.S
index 7f0b030..8dd79a2 100644
--- a/libc/arch-x86/syscalls/write.S
+++ b/libc/arch-x86/syscalls/write.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_write, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax
diff --git a/libc/arch-x86/syscalls/writev.S b/libc/arch-x86/syscalls/writev.S
index 0757a44..c442a19 100644
--- a/libc/arch-x86/syscalls/writev.S
+++ b/libc/arch-x86/syscalls/writev.S
@@ -1,4 +1,5 @@
 /* autogenerated by gensyscalls.py */
+#include <linux/err.h>
 #include <machine/asm.h>
 #include <sys/linux-syscalls.h>
 
@@ -11,7 +12,7 @@
     mov     24(%esp), %edx
     movl    $__NR_writev, %eax
     int     $0x80
-    cmpl    $-129, %eax
+    cmpl    $-MAX_ERRNO, %eax
     jb      1f
     negl    %eax
     pushl   %eax