FAILED: patch "[PATCH] MIPS: IP22: Fix build error due to binutils 2.25 uselessnes." failed to apply to 4.10-stable tree
Subsystems (2)
[email protected]
maintainerThe patch below does not apply to the 4.10-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
Quoted 1 line
From
ae2f5e5ed04a17c1aa1f0a3714c725e12c21d2a9Mon Sep 17 00:00:00 2001
From: Ralf Baechle <[email protected]>
Date: Thu, 15 Dec 2016 12:39:22 +0100
Subject: [PATCH] MIPS: IP22: Fix build error due to binutils 2.25 uselessnes.
Fix the following build error with binutils 2.25.
CC arch/mips/mm/sc-ip22.o
{standard input}: Assembler messages:
{standard input}:132: Error: number (0x9000000080000000) larger than 32 bits {standard input}:159: Error: number (0x9000000080000000) larger than 32 bits {standard input}:200: Error: number (0x9000000080000000) larger than 32 bits scripts/Makefile.build:293: recipe for target 'arch/mips/mm/sc-ip22.o' failed make[1]: *** [arch/mips/mm/sc-ip22.o] Error 1
MIPS has used .set mips3 to temporarily switch the assembler to 64 bit mode in 64 bit kernels virtually forever. Binutils 2.25 broke this behavious partially by happily accepting 64 bit instructions in .set mips3 mode but puking on 64 bit constants when generating 32 bit ELF. Binutils 2.26 restored the old behaviour again.
Fix build with binutils 2.25 by open coding the offending
dli $1, 0x9000000080000000
as
li $1, 0x9000 dsll $1, $1, 48
which is ugly be the only thing that will build on all binutils vintages.
arch/mips/mm/sc-ip22.c +12 -1
@@ -39,7 +39,18 @@ static inline void indy_sc_wipe(unsigned long first, unsigned long last)" li $1, 0x80 # Go 64 bit \n" " mtc0 $1, $12 \n" " \n" -" dli $1, 0x9000000080000000 \n" +" # \n" +" # Open code a dli $1, 0x9000000080000000 \n" +" # \n" +" # Required because binutils 2.25 will happily accept \n" +" # 64 bit instructions in .set mips3 mode but puke on \n" +" # 64 bit constants when generating 32 bit ELF \n" +" # \n" +" lui $1,0x9000 \n" +" dsll $1,$1,0x10 \n" +" ori $1,$1,0x8000 \n" +" dsll $1,$1,0x10 \n" +" \n" " or %0, $1 # first line to flush \n" " or %1, $1 # last line to flush \n" " .set at \n"
Hi Gregh,
Quoted 7 lines · On Wed, Mar 08, 2017 at 07:54:36AM +0100, [email protected] wrote:
The patch below does not apply to the 4.10-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.thanks,
Quoted 8 lines
greg k-h
------------------ original commit in Linus's tree ------------------
Quoted 1 line
From
ae2f5e5ed04a17c1aa1f0a3714c725e12c21d2a9Mon Sep 17 00:00:00 2001From: Ralf Baechle <[email protected]>
Date: Thu, 15 Dec 2016 12:39:22 +0100
Subject: [PATCH] MIPS: IP22: Fix build error due to binutils 2.25 uselessnes.
The patch will apply fine to v4.10-stable but requires 55e4fac7c9ef ("MIPS: IP22: Reformat inline assembler code to modern standards.") to be applied first. This is the case for all three branches that you reported this issue with, v4.10-stable, v4.9-stable and v4.4-stable.
Ralf
Greg KH
maintainerQuoted 16 lines · Ralf Baechle
Hi Gregh,
Quoted 12 lines · On Wed, Mar 08, 2017 at 07:54:36AM +0100, [email protected] wrote:
The patch below does not apply to the 4.10-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
Quoted 1 line
From
ae2f5e5ed04a17c1aa1f0a3714c725e12c21d2a9Mon Sep 17 00:00:00 2001
Quoted 8 lines
Quoted 3 lines
From: Ralf Baechle <[email protected]>
Date: Thu, 15 Dec 2016 12:39:22 +0100
Subject: [PATCH] MIPS: IP22: Fix build error due to binutils 2.25 uselessnes.The patch will apply fine to v4.10-stable but requires
55e4fac7c9ef("MIPS: IP22: Reformat inline assembler code to modern standards.") to be applied first. This is the case for all three branches that you reported this issue with, v4.10-stable, v4.9-stable and v4.4-stable.
Do you mean f9f1c8db1c37253805eaa32265e1e1af3ae7d0a4? I don't see a 55e4fac7c9ef in Linus's tree.
thanks,
greg k-h
Quoted 21 lines · Greg KH
Quoted 20 lines · Ralf Baechle
Hi Gregh,
Quoted 15 lines · On Wed, Mar 08, 2017 at 07:54:36AM +0100, [email protected] wrote:
The patch below does not apply to the 4.10-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
Quoted 1 line
From
ae2f5e5ed04a17c1aa1f0a3714c725e12c21d2a9Mon Sep 17 00:00:00 2001From: Ralf Baechle <[email protected]>
Date: Thu, 15 Dec 2016 12:39:22 +0100
Subject: [PATCH] MIPS: IP22: Fix build error due to binutils 2.25 uselessnes.
Quoted 7 lines
Quoted 4 lines
The patch will apply fine to v4.10-stable but requires
55e4fac7c9ef("MIPS: IP22: Reformat inline assembler code to modern standards.") to be applied first. This is the case for all three branches that you reported this issue with, v4.10-stable, v4.9-stable and v4.4-stable.Do you mean
f9f1c8db1c37253805eaa32265e1e1af3ae7d0a4? I don't see a55e4fac7c9efin Linus's tree.
Yes. 55e4fac7c9ef was the commit id in the MIPS tree before it was pushed to Linus.
Thanks,
Ralf