Patch "powerpc/64s: Increase default stack size to 32KB" has been added to the 6.1-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    powerpc/64s: Increase default stack size to 32KB

to the 6.1-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-64s-increase-default-stack-size-to-32kb.patch
and it can be found in the queue-6.1 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.


>From 18f14afe281648e31ed35c9ad2fcb724c4838ad9 Mon Sep 17 00:00:00 2001
From: Michael Ellerman <mpe@xxxxxxxxxxxxxx>
Date: Fri, 15 Dec 2023 23:44:49 +1100
Subject: powerpc/64s: Increase default stack size to 32KB

From: Michael Ellerman <mpe@xxxxxxxxxxxxxx>

commit 18f14afe281648e31ed35c9ad2fcb724c4838ad9 upstream.

There are reports of kernels crashing due to stack overflow while
running OpenShift (Kubernetes). The primary contributor to the stack
usage seems to be openvswitch, which is used by OVN-Kubernetes (based on
OVN (Open Virtual Network)), but NFS also contributes in some stack
traces.

There may be some opportunities to reduce stack usage in the openvswitch
code, but doing so potentially require tradeoffs vs performance, and
also requires testing across architectures.

Looking at stack usage across the kernel (using -fstack-usage), shows
that ppc64le stack frames are on average 50-100% larger than the
equivalent function built for x86-64. Which is not surprising given the
minimum stack frame size is 32 bytes on ppc64le vs 16 bytes on x86-64.

So increase the default stack size to 32KB for the modern 64-bit Book3S
platforms, ie. pseries (virtualised) and powernv (bare metal). That
leaves the older systems like G5s, and the AmigaOne (pasemi) with a 16KB
stack which should be sufficient on those machines.

Signed-off-by: Michael Ellerman <mpe@xxxxxxxxxxxxxx>
Signed-off-by: Aneesh Kumar K.V (IBM) <aneesh.kumar@xxxxxxxxxx>
Link: https://msgid.link/20231215124449.317597-1-mpe@xxxxxxxxxxxxxx
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
---
 arch/powerpc/Kconfig |    1 +
 1 file changed, 1 insertion(+)

--- a/arch/powerpc/Kconfig
+++ b/arch/powerpc/Kconfig
@@ -806,6 +806,7 @@ config THREAD_SHIFT
 	int "Thread shift" if EXPERT
 	range 13 15
 	default "15" if PPC_256K_PAGES
+	default "15" if PPC_PSERIES || PPC_POWERNV
 	default "14" if PPC64
 	default "13"
 	help


Patches currently in stable-queue which might be from mpe@xxxxxxxxxxxxxx are

queue-6.1/powerpc-powernv-add-a-null-pointer-check-in-opal_eve.patch
queue-6.1/powerpc-powernv-add-a-null-pointer-check-to-scom_deb.patch
queue-6.1/powerpc-remove-checks-for-binutils-older-than-2.25.patch
queue-6.1/powerpc-64s-increase-default-stack-size-to-32kb.patch
queue-6.1/powerpc-add-crtsavres.o-to-always-y-instead-of-extra.patch
queue-6.1/selftests-powerpc-fix-error-handling-in-fpu-vmx-pree.patch
queue-6.1/powerpc-imc-pmu-add-a-null-pointer-check-in-update_e.patch
queue-6.1/powerpc-44x-select-i2c-for-currituck.patch
queue-6.1/powerpc-powernv-add-a-null-pointer-check-in-opal_pow.patch
queue-6.1/powerpc-pseries-memhp-fix-access-beyond-end-of-drmem.patch




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux