0001-Revert-riscv-Use-latest-system-call-ABI.patch 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. From 15f62343916fcb3cae82e618da28eaa82bc8c007 Mon Sep 17 00:00:00 2001
  2. From: Alistair Francis <alistair.francis@wdc.com>
  3. Date: Tue, 16 Apr 2019 09:03:41 -0700
  4. Subject: [PATCH] Revert "riscv: Use latest system call ABI"
  5. This reverts commit d4c08b9776b392e20efc6198ebe1bc8ec1911d9b.
  6. The latest RISC-V 32bit glibc submission doesn't work with this patch,
  7. so let's revert it. This revert can be reverted when the glibc
  8. submission is updated to work on the 5.1 kernel.
  9. Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
  10. ---
  11. arch/riscv/Kconfig | 1 +
  12. arch/riscv/include/uapi/asm/unistd.h | 5 ++++-
  13. arch/riscv/kernel/vdso/Makefile | 2 --
  14. 3 files changed, 5 insertions(+), 3 deletions(-)
  15. diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig
  16. index eb56c82d8aa1..43dd2680c696 100644
  17. --- a/arch/riscv/Kconfig
  18. +++ b/arch/riscv/Kconfig
  19. @@ -11,6 +11,7 @@ config 32BIT
  20. config RISCV
  21. def_bool y
  22. + select ARCH_32BIT_OFF_T if !64BIT
  23. # even on 32-bit, physical (and DMA) addresses are > 32-bits
  24. select PHYS_ADDR_T_64BIT
  25. select OF
  26. diff --git a/arch/riscv/include/uapi/asm/unistd.h b/arch/riscv/include/uapi/asm/unistd.h
  27. index 0e2eeeb1fd27..486a288b454c 100644
  28. --- a/arch/riscv/include/uapi/asm/unistd.h
  29. +++ b/arch/riscv/include/uapi/asm/unistd.h
  30. @@ -17,8 +17,11 @@
  31. #ifdef __LP64__
  32. #define __ARCH_WANT_NEW_STAT
  33. -#define __ARCH_WANT_SET_GET_RLIMIT
  34. #endif /* __LP64__ */
  35. +#define __ARCH_WANT_SET_GET_RLIMIT
  36. +#ifndef __LP64__
  37. +#define __ARCH_WANT_TIME32_SYSCALLS
  38. +#endif
  39. #include <asm-generic/unistd.h>
  40. diff --git a/arch/riscv/kernel/vdso/Makefile b/arch/riscv/kernel/vdso/Makefile
  41. index fec62b24df89..eed1c137f618 100644
  42. --- a/arch/riscv/kernel/vdso/Makefile
  43. +++ b/arch/riscv/kernel/vdso/Makefile
  44. @@ -2,11 +2,9 @@
  45. # Symbols present in the vdso
  46. vdso-syms = rt_sigreturn
  47. -ifdef CONFIG_64BIT
  48. vdso-syms += gettimeofday
  49. vdso-syms += clock_gettime
  50. vdso-syms += clock_getres
  51. -endif
  52. vdso-syms += getcpu
  53. vdso-syms += flush_icache
  54. --
  55. 2.21.0