Update.
authorUlrich Drepper <drepper@redhat.com>
Thu, 19 Apr 2001 21:24:46 +0000 (21:24 +0000)
committerUlrich Drepper <drepper@redhat.com>
Thu, 19 Apr 2001 21:24:46 +0000 (21:24 +0000)
2001-04-19  Matthew Wilcox  <willy@ldl.fc.hp.com>

* sysdeps/unix/sysv/linux/hppa/sysdep.h (INLINE_SYSCALL):
Change to return a signed result for compatibility with other
architectures, and correctness.

ChangeLog
sysdeps/unix/sysv/linux/hppa/sysdep.h

index b18db0a..ed54ff9 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2001-04-19  Matthew Wilcox  <willy@ldl.fc.hp.com>
+
+       * sysdeps/unix/sysv/linux/hppa/sysdep.h (INLINE_SYSCALL):
+       Change to return a signed result for compatibility with other
+       architectures, and correctness.
+
 2001-04-19  Ulrich Drepper  <drepper@redhat.com>
 
        * sysdeps/unix/sysv/linux/kernel-features.h (__ASSUME_32BITUIDS):
index 10e360d..1430642 100644 (file)
 
 #undef INLINE_SYSCALL
 #define INLINE_SYSCALL(name, nr, args...)      ({              \
-       unsigned long __sys_res;                                \
+       long __sys_res;                                         \
        {                                                       \
                register unsigned long __res asm("r28");        \
                LOAD_ARGS_##nr(args)                            \
                asm volatile(                                   \
-                       "ble  0x100(%%sr2, %%r0)\n\t"   \
+                       "ble  0x100(%%sr2, %%r0)\n\t"           \
                        " ldi %1, %%r20"                        \
                        : "=r" (__res)                          \
                        : "i" (SYS_ify(name)) ASM_ARGS_##nr     \
                         );                                     \
                __sys_res = __res;                              \
        }                                                       \
-       if (__sys_res >= (unsigned long)-4095) {                \
+       if ((unsigned long)__sys_res >= (unsigned long)-4095) { \
                __set_errno(-__sys_res);                        \
-               __sys_res = (unsigned long)-1;                  \
+               __sys_res = -1;                                 \
        }                                                       \
        __sys_res;                                              \
 })