Patch "powerpc/hotplug-mem: Fix missing endian conversion of aa_index" has been added to the 4.4-stable tree
Subsystems (2)
This is a note to let you know that I've just added the patch titled
powerpc/hotplug-mem: Fix missing endian conversion of aa_index
to the 4.4-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
powerpc-hotplug-mem-fix-missing-endian-conversion-of-aa_index.patch
and it can be found in the queue-4.4 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From
dc421b200f91930c9c6a9586810ff8c232cf10fcMon Sep 17 00:00:00 2001
From: Michael Bringmann <[email protected]>
Date: Mon, 22 May 2017 15:44:37 -0500
Subject: powerpc/hotplug-mem: Fix missing endian conversion of aa_index
From: Michael Bringmann <[email protected]>
commit dc421b200f91930c9c6a9586810ff8c232cf10fc upstream.
When adding or removing memory, the aa_index (affinity value) for the memblock must also be converted to match the endianness of the rest of the 'ibm,dynamic-memory' property. Otherwise, subsequent retrieval of the attribute will likely lead to non-existent nodes, followed by using the default node in the code inappropriately.
--- arch/powerpc/platforms/pseries/hotplug-memory.c | 2 ++ 1 file changed, 2 insertions(+)
arch/powerpc/platforms/pseries/hotplug-memory.c +2 -0
@@ -110,6 +110,7 @@ static struct property *dlpar_clone_drcofor (i =0 ; i < num_lmbs; i++) { lmbs[i].base_addr =be64_to_cpu (lmbs[i].base_addr); lmbs[i].drc_index =be32_to_cpu (lmbs[i].drc_index); + lmbs[i].aa_index =be32_to_cpu (lmbs[i].aa_index); lmbs[i].flags =be32_to_cpu (lmbs[i].flags); }
@@ -553,6 +554,7 @@ static void dlpar_update_drconf_propertyfor (i =0 ; i < num_lmbs; i++) { lmbs[i].base_addr =cpu_to_be64 (lmbs[i].base_addr); lmbs[i].drc_index =cpu_to_be32 (lmbs[i].drc_index); + lmbs[i].aa_index =cpu_to_be32 (lmbs[i].aa_index); lmbs[i].flags =cpu_to_be32 (lmbs[i].flags); }
Patches currently in stable-queue which might be from [email protected] are
queue-4.4/powerpc-hotplug-mem-fix-missing-endian-conversion-of-aa_index.patch