X-Git-Url: https://git.enpas.org/?a=blobdiff_plain;f=target%2Flinux%2Focteon%2Fpatches%2F001-handle_removal_h_constraint.patch;h=ea19508ce7194a93dd1b826e8d8cf83c334650bd;hb=09c18c40fa96f8ae744c05b70de84245c4383439;hp=48c41d74d5288a6a3086ecfd46706cfc611fde97;hpb=7d01bddd188fbc4bed66f137c1a1ddda572f234d;p=openwrt.git diff --git a/target/linux/octeon/patches/001-handle_removal_h_constraint.patch b/target/linux/octeon/patches/001-handle_removal_h_constraint.patch index 48c41d74d5..ea19508ce7 100644 --- a/target/linux/octeon/patches/001-handle_removal_h_constraint.patch +++ b/target/linux/octeon/patches/001-handle_removal_h_constraint.patch @@ -7,13 +7,12 @@ Comments welcome. Signed-off-by: David Daney --- arch/mips/include/asm/compiler.h | 7 +++++++ - arch/mips/include/asm/delay.h | 4 ++++ 2 files changed, 11 insertions(+), 0 deletions(-) --- a/arch/mips/include/asm/compiler.h +++ b/arch/mips/include/asm/compiler.h -@@ -26,4 +26,11 @@ typedef u64 uintx_t; - #endif +@@ -16,4 +16,11 @@ + #define GCC_REG_ACCUM "accum" #endif +#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4) @@ -24,20 +23,3 @@ Signed-off-by: David Daney +#endif + #endif /* _ASM_COMPILER_H */ ---- a/arch/mips/include/asm/delay.h -+++ b/arch/mips/include/asm/delay.h -@@ -67,10 +67,14 @@ static inline unsigned long __usecs_to_l - : "r" (usecs), "r" (lpj) - : GCC_REG_ACCUM); - else if (sizeof(long) == 8 && !R4000_WAR) -+#ifdef GCC_NO_H_CONSTRAINT -+ usecs = ((uint128_t)usecs * lpj) >> 64; -+#else - __asm__("dmultu\t%2, %3" - : "=h" (usecs), "=l" (lo) - : "r" (usecs), "r" (lpj) - : GCC_REG_ACCUM); -+#endif - else if (sizeof(long) == 8 && R4000_WAR) - __asm__("dmultu\t%3, %4\n\tmfhi\t%0" - : "=r" (usecs), "=h" (hi), "=l" (lo)