aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2011-06-30 09:43:14 -0400
committerRalf Baechle <ralf@linux-mips.org>2011-10-20 10:00:19 -0400
commitb77bb37a2ad7689d9ef8048df9cc30ee770f5a94 (patch)
tree6e23e1fab17a1f2c46592514e9adc171cfe958c8 /arch/mips
parentdd5d1380f1379882e4adad65a85271da4662d20d (diff)
Revert "MIPS: LD/SD o32 macro GAS fix update"
This reverts commit 97475f8b42e83be2966aa2d70ab9c98477701c53 (lmo) / 82b89152f00f7ad17844d5614d5011e8d7944ac9 (kernel.org) [MIPS: LD/SD o32 macro GAS fix update]. Turns out this patch is producing many build errors with gcc 4.2. Based on further testing with a test case extracted from the build errors found further build errors and suboptimal generation even in violation of the "R" constraint. To make matters worse, the binutils changes also don't work quite as intended so revert this patch for now.
Diffstat (limited to 'arch/mips')
-rw-r--r--arch/mips/include/asm/io.h12
-rw-r--r--arch/mips/pmc-sierra/yosemite/py-console.c12
2 files changed, 4 insertions, 20 deletions
diff --git a/arch/mips/include/asm/io.h b/arch/mips/include/asm/io.h
index b04e4de5dd2e..a58f22998a86 100644
--- a/arch/mips/include/asm/io.h
+++ b/arch/mips/include/asm/io.h
@@ -329,14 +329,10 @@ static inline void pfx##write##bwlq(type val, \
329 "dsrl32 %L0, %L0, 0" "\n\t" \ 329 "dsrl32 %L0, %L0, 0" "\n\t" \
330 "dsll32 %M0, %M0, 0" "\n\t" \ 330 "dsll32 %M0, %M0, 0" "\n\t" \
331 "or %L0, %L0, %M0" "\n\t" \ 331 "or %L0, %L0, %M0" "\n\t" \
332 ".set push" "\n\t" \
333 ".set noreorder" "\n\t" \
334 ".set nomacro" "\n\t" \
335 "sd %L0, %2" "\n\t" \ 332 "sd %L0, %2" "\n\t" \
336 ".set pop" "\n\t" \
337 ".set mips0" "\n" \ 333 ".set mips0" "\n" \
338 : "=r" (__tmp) \ 334 : "=r" (__tmp) \
339 : "0" (__val), "R" (*__mem)); \ 335 : "0" (__val), "m" (*__mem)); \
340 if (irq) \ 336 if (irq) \
341 local_irq_restore(__flags); \ 337 local_irq_restore(__flags); \
342 } else \ 338 } else \
@@ -359,16 +355,12 @@ static inline type pfx##read##bwlq(const volatile void __iomem *mem) \
359 local_irq_save(__flags); \ 355 local_irq_save(__flags); \
360 __asm__ __volatile__( \ 356 __asm__ __volatile__( \
361 ".set mips3" "\t\t# __readq" "\n\t" \ 357 ".set mips3" "\t\t# __readq" "\n\t" \
362 ".set push" "\n\t" \
363 ".set noreorder" "\n\t" \
364 ".set nomacro" "\n\t" \
365 "ld %L0, %1" "\n\t" \ 358 "ld %L0, %1" "\n\t" \
366 ".set pop" "\n\t" \
367 "dsra32 %M0, %L0, 0" "\n\t" \ 359 "dsra32 %M0, %L0, 0" "\n\t" \
368 "sll %L0, %L0, 0" "\n\t" \ 360 "sll %L0, %L0, 0" "\n\t" \
369 ".set mips0" "\n" \ 361 ".set mips0" "\n" \
370 : "=r" (__val) \ 362 : "=r" (__val) \
371 : "R" (*__mem)); \ 363 : "m" (*__mem)); \
372 if (irq) \ 364 if (irq) \
373 local_irq_restore(__flags); \ 365 local_irq_restore(__flags); \
374 } else { \ 366 } else { \
diff --git a/arch/mips/pmc-sierra/yosemite/py-console.c b/arch/mips/pmc-sierra/yosemite/py-console.c
index 434d7b1a8c6a..b7f1d9c4a8a3 100644
--- a/arch/mips/pmc-sierra/yosemite/py-console.c
+++ b/arch/mips/pmc-sierra/yosemite/py-console.c
@@ -65,15 +65,11 @@ static unsigned char readb_outer_space(unsigned long long phys)
65 65
66 __asm__ __volatile__ ( 66 __asm__ __volatile__ (
67 " .set mips3 \n" 67 " .set mips3 \n"
68 " .set push \n"
69 " .set noreorder \n"
70 " .set nomacro \n"
71 " ld %0, %1 \n" 68 " ld %0, %1 \n"
72 " .set pop \n"
73 " lbu %0, (%0) \n" 69 " lbu %0, (%0) \n"
74 " .set mips0 \n" 70 " .set mips0 \n"
75 : "=r" (res) 71 : "=r" (res)
76 : "R" (vaddr)); 72 : "m" (vaddr));
77 73
78 write_c0_status(sr); 74 write_c0_status(sr);
79 ssnop_4(); 75 ssnop_4();
@@ -93,15 +89,11 @@ static void writeb_outer_space(unsigned long long phys, unsigned char c)
93 89
94 __asm__ __volatile__ ( 90 __asm__ __volatile__ (
95 " .set mips3 \n" 91 " .set mips3 \n"
96 " .set push \n"
97 " .set noreorder \n"
98 " .set nomacro \n"
99 " ld %0, %1 \n" 92 " ld %0, %1 \n"
100 " .set pop \n"
101 " sb %2, (%0) \n" 93 " sb %2, (%0) \n"
102 " .set mips0 \n" 94 " .set mips0 \n"
103 : "=&r" (tmp) 95 : "=&r" (tmp)
104 : "R" (vaddr), "r" (c)); 96 : "m" (vaddr), "r" (c));
105 97
106 write_c0_status(sr); 98 write_c0_status(sr);
107 ssnop_4(); 99 ssnop_4();