mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-28 23:23:55 +08:00
powerpc fixes for 4.9 #7
Four fixes, the first for code we merged this cycle and three that are also going to stable: - On 64-bit Book3E we were not placing the .text section where we said we would in the asm. - We broke building the boot wrapper on some 32-bit toolchains. - Lazy icache flushing was broken on pre-POWER5 machines. - One of the error paths in our EEH code would lead to a deadlock. Thanks to: Andrew Donnellan, Ben Hutchings, Benjamin Herrenschmidt, Nicholas Piggin. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAABAgAGBQJYRMkzAAoJEFHr6jzI4aWAoKsP/jUhpuGLkLM04isnRyjerYUL TZLp3NyplLSII8mwj+mCglVet4R79fctsvrl8uUXcMuTSfD6F1e9W7Oz9gxmBahT owZw5xmXFNLeCq1/w0N3KajYNvCTISEBuIgb/JVHntTu9nQ2gMwJ78DxpnBlTL93 mAWA/2Sl1ybcEJJDKK6M/Lz3TyicRGBKDfo6tHdtgH44Sv1q2NufbA+UCzpZXywO HIPbirgy22vs6pA+OAe+5UmiHCgkFXNgZbrnIr0bz/6w8xaQmKJF1uUxt6Qj03Gn l+y45C1lgGiQzCNl5S+VkO0yopFS9L3/VNA0xHHUpi7/3Sz229ASHpCJjNrT3qsd NUjKMLucAgM+86R4gOhAKk1xjKKjp9LnTdAVs1t9w4nMud6pKd3+2/I7kEk8GQvh fTf3P2Bw6Gtm8b2Pd5WswcDYXpZGgfbPSltgAXtnyKuswtNtUfhhmVkNaJRZSCLP ZdgcwT1zmBISz3b5n1dtngRwSO4BP/+2HTCpLFF77ZT6PEAhRKbCOy1Qlb0+C2RW nZG6oXkNHjvF4W6teYRAmyqklj4ndUcUKsS9koFO/6GOiaDUMiCHnMNa+tByk1nl ufAKLAQ5IlvhEZ6kE11QDkcACy76obNDnKu24+kGwyJD9R2CK0HIMykogJYasN68 Hjo03XsSaWv2umwq7ZwI =6IL4 -----END PGP SIGNATURE----- Merge tag 'powerpc-4.9-7' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux Pull powerpc fixes from Michael Ellerman: "Four fixes, the first for code we merged this cycle and three that are also going to stable: - On 64-bit Book3E we were not placing the .text section where we said we would in the asm. - We broke building the boot wrapper on some 32-bit toolchains. - Lazy icache flushing was broken on pre-POWER5 machines. - One of the error paths in our EEH code would lead to a deadlock. Thanks to: Andrew Donnellan, Ben Hutchings, Benjamin Herrenschmidt, Nicholas Piggin" * tag 'powerpc-4.9-7' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: powerpc/64: Fix placement of .text to be immediately following .head.text powerpc/eeh: Fix deadlock when PE frozen state can't be cleared powerpc/mm: Fix lazy icache flush on pre-POWER5 powerpc/boot: Fix build failure in 32-bit boot wrapper
This commit is contained in:
commit
d9d04527c7
@ -100,7 +100,8 @@ src-wlib-y := string.S crt0.S crtsavres.S stdio.c decompress.c main.c \
|
||||
ns16550.c serial.c simple_alloc.c div64.S util.S \
|
||||
elf_util.c $(zlib-y) devtree.c stdlib.c \
|
||||
oflib.c ofconsole.c cuboot.c mpsc.c cpm-serial.c \
|
||||
uartlite.c mpc52xx-psc.c opal.c opal-calls.S
|
||||
uartlite.c mpc52xx-psc.c opal.c
|
||||
src-wlib-$(CONFIG_PPC64_BOOT_WRAPPER) += opal-calls.S
|
||||
src-wlib-$(CONFIG_40x) += 4xx.c planetcore.c
|
||||
src-wlib-$(CONFIG_44x) += 4xx.c ebony.c bamboo.c
|
||||
src-wlib-$(CONFIG_8xx) += mpc8xx.c planetcore.c fsl-soc.c
|
||||
|
@ -13,7 +13,7 @@
|
||||
#include <libfdt.h>
|
||||
#include "../include/asm/opal-api.h"
|
||||
|
||||
#ifdef __powerpc64__
|
||||
#ifdef CONFIG_PPC64_BOOT_WRAPPER
|
||||
|
||||
/* Global OPAL struct used by opal-call.S */
|
||||
struct opal {
|
||||
|
@ -671,8 +671,10 @@ static int eeh_reset_device(struct eeh_pe *pe, struct pci_bus *bus,
|
||||
|
||||
/* Clear frozen state */
|
||||
rc = eeh_clear_pe_frozen_state(pe, false);
|
||||
if (rc)
|
||||
if (rc) {
|
||||
pci_unlock_rescan_remove();
|
||||
return rc;
|
||||
}
|
||||
|
||||
/* Give the system 5 seconds to finish running the user-space
|
||||
* hotplug shutdown scripts, e.g. ifdown for ethernet. Yes,
|
||||
|
@ -94,8 +94,17 @@ SECTIONS
|
||||
* detected, and will result in a crash at boot due to offsets being
|
||||
* wrong.
|
||||
*/
|
||||
#ifdef CONFIG_PPC64
|
||||
/*
|
||||
* BLOCK(0) overrides the default output section alignment because
|
||||
* this needs to start right after .head.text in order for fixed
|
||||
* section placement to work.
|
||||
*/
|
||||
.text BLOCK(0) : AT(ADDR(.text) - LOAD_OFFSET) {
|
||||
#else
|
||||
.text : AT(ADDR(.text) - LOAD_OFFSET) {
|
||||
ALIGN_FUNCTION();
|
||||
#endif
|
||||
/* careful! __ftr_alt_* sections need to be close to .text */
|
||||
*(.text .fixup __ftr_alt_* .ref.text)
|
||||
SCHED_TEXT
|
||||
|
@ -55,7 +55,7 @@ int __hash_page_4K(unsigned long ea, unsigned long access, unsigned long vsid,
|
||||
*/
|
||||
rflags = htab_convert_pte_flags(new_pte);
|
||||
|
||||
if (!cpu_has_feature(CPU_FTR_NOEXECUTE) &&
|
||||
if (cpu_has_feature(CPU_FTR_NOEXECUTE) &&
|
||||
!cpu_has_feature(CPU_FTR_COHERENT_ICACHE))
|
||||
rflags = hash_page_do_lazy_icache(rflags, __pte(old_pte), trap);
|
||||
|
||||
|
@ -87,7 +87,7 @@ int __hash_page_4K(unsigned long ea, unsigned long access, unsigned long vsid,
|
||||
subpg_pte = new_pte & ~subpg_prot;
|
||||
rflags = htab_convert_pte_flags(subpg_pte);
|
||||
|
||||
if (!cpu_has_feature(CPU_FTR_NOEXECUTE) &&
|
||||
if (cpu_has_feature(CPU_FTR_NOEXECUTE) &&
|
||||
!cpu_has_feature(CPU_FTR_COHERENT_ICACHE)) {
|
||||
|
||||
/*
|
||||
@ -258,7 +258,7 @@ int __hash_page_64K(unsigned long ea, unsigned long access,
|
||||
|
||||
rflags = htab_convert_pte_flags(new_pte);
|
||||
|
||||
if (!cpu_has_feature(CPU_FTR_NOEXECUTE) &&
|
||||
if (cpu_has_feature(CPU_FTR_NOEXECUTE) &&
|
||||
!cpu_has_feature(CPU_FTR_COHERENT_ICACHE))
|
||||
rflags = hash_page_do_lazy_icache(rflags, __pte(old_pte), trap);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user