From: Stian Halseth <stian@itx.no>
To: Tony Rodriguez <unixpro1970@gmail.com>,
andreas@gaisler.com, davem@davemloft.net,
sparclinux@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, david.laight.linux@gmail.com,
glaubitz@physik.fu-berlin.de, thuth@redhat.com,
regressions@lists.linux.dev, nroach44@nroach44.id.au
Subject: Re: [PATCH v2] sparc64: increase kernel thread stack size to 32K
Date: Mon, 31 Aug 2026 23:05:33 +0200 [thread overview]
Message-ID: <18d7ea80efbb5dd3d81acbae926da4e027ebfed9.camel@itx.no> (raw)
In-Reply-To: <b46209d5-e518-4289-9b3a-5854a2512278@gmail.com>
Hi Tony,
On Mon, 2026-08-31 at 13:18 -0700, Tony Rodriguez wrote:
> Hi Stian,
>
> Just please continue to give me a
> mention in any patches related to this work, since I spent a
> considerable amount of time debugging, researching, and validating
> the fixes.
Sure. For now, no real changes have been made to your patches, so as
far as I'm concerned, this is entirely your work.
Will try help with the last mile, alongside some other patches I've
submitted.
And yes, the debugging, researching and validation is the hard part.
Writing a fix is often _relatively_ easy, when you have all the facts.
>
> When I last tested on 7.0 and 7.1, both of my patches worked:
>
> A) sparc64: increase kernel thread stack size to 32K
>
> B) sparc64: Fix comparator problem with timer interrupts
>
> I was able to debug and validate these issues on S7‑2 and T7‑1
> hardware.
Yes, and that's a very important data point. My analyzis is based on
the change itself, _and_ your validation/testing.
> I’m not sure if others have reported similar problems on T4 or T5
> systems.
Not that I'm aware of, and I haven't seen it on my T4-1.
>
> If you have a quicker or better methodology for reviewing stack
> usage—or
> any general suggestions—I’m definitely open to seeing them, along
> with
> your config and exact procedure. And if you need help validating
> against
> S7‑2 and T7‑1 hardware, I can try to allocate some time to assist.
I think that would be very helpful. Let's try to settle the 32K-vs-64K
question with more data.
The kernel has stack measurement built in.
The in-kernel method:
CONFIG_STACK_TRACER=y
CONFIG_DEBUG_STACK_USAGE=y
CONFIG_SCHED_STACK_END_CHECK=y
Boot with "stacktrace" on the kernel command line (arms the tracer
before built-in drivers probe). Then:
cat /sys/kernel/tracing/stack_max_size # worst case seen, bytes
cat /sys/kernel/tracing/stack_trace # that path, frame by frame
Reset with "echo 0 > stack_max_size" before a workload to isolate it.
For the 32K-vs-64K question, the most valuable data you could gather
is a stack_trace snapshot on the S7-2/T7-1 under your real workload
with mlx5 active, on a 32K kernel.
On our T4-1 the worst case is 12616 bytes, but doesn't have mlx5. If
your machines stay well under 32K, we have comfortable margin. But if
something approaches the limit, the trace will name the exact frames,
and we can judge whether the right answer is 64K or a targeted fix in
that driver.
>
Thanks!
--
Best regards
Stian Halseth
next prev parent reply other threads:[~2026-08-31 21:05 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-19 7:57 [PATCH 0/1] sparc64: unify thread stack sizing and add explicit 32KB stack Tony Rodriguez
2026-05-19 7:57 ` [PATCH 1/1] " Tony Rodriguez
2026-05-19 8:56 ` Nathaniel Roach
2026-06-16 14:18 ` Andreas Larsson
2026-06-16 19:58 ` David Laight
2026-06-18 5:53 ` Andreas Larsson
2026-06-18 7:29 ` Tony Rodriguez
2026-06-18 8:57 ` David Laight
2026-06-18 10:32 ` David Laight
2026-05-19 10:02 ` [PATCH 0/1] " David Laight
2026-05-19 23:57 ` Tony Rodriguez
2026-05-20 13:41 ` David Laight
2026-08-31 17:27 ` Stian Halseth
2026-08-31 17:29 ` [PATCH v2] sparc64: increase kernel thread stack size to 32K Stian Halseth
2026-08-31 18:25 ` Tony Rodriguez
2026-08-31 18:54 ` Stian Halseth
2026-08-31 20:18 ` Tony Rodriguez
2026-08-31 21:05 ` Stian Halseth [this message]
2026-09-02 3:30 ` Tony Rodriguez
[not found] <f3719bb0-e892-49cc-af82-79e2569a8a90@gmail.com>
2026-08-31 19:04 ` Tony Rodriguez
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=18d7ea80efbb5dd3d81acbae926da4e027ebfed9.camel@itx.no \
--to=stian@itx.no \
--cc=andreas@gaisler.com \
--cc=davem@davemloft.net \
--cc=david.laight.linux@gmail.com \
--cc=glaubitz@physik.fu-berlin.de \
--cc=linux-kernel@vger.kernel.org \
--cc=nroach44@nroach44.id.au \
--cc=regressions@lists.linux.dev \
--cc=sparclinux@vger.kernel.org \
--cc=thuth@redhat.com \
--cc=unixpro1970@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox