0002-m4-stack-direction-RISC-V-stack-grows-downward.patch 1.1 KB

1234567891011121314151617181920212223242526272829303132333435
  1. From 9dd1989f5ae6cd3f2051732318e26bf742a4c89b Mon Sep 17 00:00:00 2001
  2. From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
  3. Date: Tue, 13 Nov 2018 22:24:03 +0100
  4. Subject: [PATCH] m4/stack-direction: RISC-V stack grows downward
  5. While commit 671b2528b55c57eda1a8fe5872ff1ef61014235f ("Improve
  6. support for Linux/RISC-V") adds some support for the RISC-V
  7. architecture, it doesn't update m4/stack-direction.m4 to properly
  8. support cross-compiling libsigsegv for a RISC-V architecture.
  9. According to
  10. https://riscv.org/wp-content/uploads/2015/01/riscv-calling.pdf: "In
  11. the standard RISC-V calling convention, the stack grows downward", so
  12. let's update m4/stack-direction.m4 accordingly.
  13. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
  14. ---
  15. m4/stack-direction.m4 | 1 +
  16. 1 file changed, 1 insertion(+)
  17. diff --git a/m4/stack-direction.m4 b/m4/stack-direction.m4
  18. index c373f1c..9504f88 100644
  19. --- a/m4/stack-direction.m4
  20. +++ b/m4/stack-direction.m4
  21. @@ -43,6 +43,7 @@ AC_DEFUN([SV_STACK_DIRECTION],
  22. pdp11 | \
  23. pj* | \
  24. powerpc* | rs6000 | \
  25. + riscv* | \
  26. romp | \
  27. s390* | \
  28. sh* | \
  29. --
  30. 2.19.1