Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 5 Jan 2026 09:51:08 +0100 (CET)
From:      Ronald Klop <ronald-lists@klop.ws>
To:        freebsd-arm@FreeBSD.org
Subject:   Re: [Bug 292195] arm64: panic on coredump with sve instructions
Message-ID:  <904455433.482.1767603068277@localhost>
In-Reply-To: <bug-292195-7@https.bugs.freebsd.org/bugzilla/>

index | next in thread | previous in thread | raw e-mail

[-- Attachment #1 --]
Sounds like an investigation candidate for why pkg builder ampere1 crashes now and than?

Ronald.
 
Van: bugzilla-noreply@freebsd.org
Datum: maandag, 5 januari 2026 09:39
Aan: freebsd-arm@FreeBSD.org
Onderwerp: [Bug 292195] arm64: panic on coredump with sve instructions
> 
> https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=292195
> 
>             Bug ID: 292195
>            Summary: arm64: panic on coredump with sve instructions
>            Product: Base System
>            Version: 16.0-CURRENT
>           Hardware: Any
>                 OS: Any
>             Status: New
>           Severity: Affects Some People
>           Priority: ---
>          Component: arm
>           Assignee: freebsd-arm@FreeBSD.org
>           Reporter: william.a@carrel.org
> 
> Created attachment 266838
>   --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=266838&action=edit
> vfp.c.patch
> 
> When trying to reproduce bug 292177 on 16-CURRENT I unexpectedly encountered a
> kernel panic. It looks like the panic was unique to coredumping in SVE code.
> 
> The coredump logic calls get_arm64_sve twice: once to get the note size, and
> once to get the data. The note size calculation depended on the volatile
> PCB_FP_SVEVALID flag. If this flag was cleared between the two calls (e.g., due
> to a context switch clearing the flag to comply with the ABI), the second call
> would expect a smaller buffer size than the first, triggering the KASSERT panic
> ("invalid size").
> 
> Fix this by:
> 1. Using pcb->pcb_svesaved != NULL (a stable indicator of SVE usage) to
> determine the note size.
> 2. Calling vfp_to_sve_sync() if SVE is not currently valid but SVE state is
> saved, ensuring the SVE buffer in the core dump contains the most up-to-date
> register values.
> 
> -- 
> You are receiving this mail because:
> You are the assignee for the bug.
> 
> 
> 

 
[-- Attachment #2 --]
<html><head></head><body>Sounds like an investigation candidate for why pkg builder ampere1 crashes now and than?<br>
<br>
Ronald.<br>
&nbsp;
<p><strong>Van:</strong> bugzilla-noreply@freebsd.org<br>
<strong>Datum:</strong> maandag, 5 januari 2026 09:39<br>
<strong>Aan:</strong> freebsd-arm@FreeBSD.org<br>
<strong>Onderwerp:</strong> [Bug 292195] arm64: panic on coredump with sve instructions</p>

<blockquote style="padding-right: 0px; padding-left: 5px; margin-left: 5px; border-left: #000000 2px solid; margin-right: 0px">
<div class="MessageRFC822Viewer" id="P">
<div class="TextPlainViewer" id="P.P"><a href="https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=292195">https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=292195</a><br>;
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Bug ID: 292195<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Summary: arm64: panic on coredump with sve instructions<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Product: Base System<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Version: 16.0-CURRENT<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hardware: Any<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;OS: Any<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Status: New<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Severity: Affects Some People<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Priority: ---<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Component: arm<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Assignee: freebsd-arm@FreeBSD.org<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reporter: william.a@carrel.org<br>
<br>
Created attachment 266838<br>
&nbsp;&nbsp;--&gt; <a href="https://bugs.freebsd.org/bugzilla/attachment.cgi?id=266838&amp;action=edit">https://bugs.freebsd.org/bugzilla/attachment.cgi?id=266838&amp;action=edit</a><br>;
vfp.c.patch<br>
<br>
When trying to reproduce bug 292177 on 16-CURRENT I unexpectedly encountered a<br>
kernel panic. It looks like the panic was unique to coredumping in SVE code.<br>
<br>
The coredump logic calls get_arm64_sve twice: once to get the note size, and<br>
once to get the data. The note size calculation depended on the volatile<br>
PCB_FP_SVEVALID flag. If this flag was cleared between the two calls (e.g., due<br>
to a context switch clearing the flag to comply with the ABI), the second call<br>
would expect a smaller buffer size than the first, triggering the KASSERT panic<br>
("invalid size").<br>
<br>
Fix this by:<br>
1. Using pcb-&gt;pcb_svesaved != NULL (a stable indicator of SVE usage) to<br>
determine the note size.<br>
2. Calling vfp_to_sve_sync() if SVE is not currently valid but SVE state is<br>
saved, ensuring the SVE buffer in the core dump contains the most up-to-date<br>
register values.<br>
<br>
--&nbsp;<br>
You are receiving this mail because:<br>
You are the assignee for the bug.</div>

<hr></div>
</blockquote>
<br>
&nbsp;</body></html>
home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?904455433.482.1767603068277>