From: Timur Tabi <ttabi@nvidia.com>
To: "airlied@redhat.com" <airlied@redhat.com>,
"nouveau@lists.freedesktop.org" <nouveau@lists.freedesktop.org>,
"dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>, "me@dakr.org" <me@dakr.org>
Subject: Re: [Nouveau] [PATCH] nouveau/gsp: fix UBSAN array bounds warning in PACKED_REGISTRY_TABLE
Date: Wed, 8 Nov 2023 00:00:15 +0000 [thread overview]
Message-ID: <5905396653318954faeddcd8356f25644cccbb55.camel@nvidia.com> (raw)
In-Reply-To: <04fd39a8-174d-44e7-a910-5e808d8563b5@dakr.org>
On Wed, 2023-11-08 at 00:52 +0100, Danilo Krummrich wrote:
> On 11/8/23 00:47, Timur Tabi wrote:
> > Change PACKED_REGISTRY_TABLE so that its last member is a variable-
> > length
> > array instead of a zero-length array. UBSAN treats zero-length arrays
> > literally and warns if they are dereferenced. Changing the "[0]" to
> > "[]"
> > tells the compiler that the array is variable-length.
>
> Do you also intend to fix this upstream? (And with upstream I mean the
> open-gpu-kernel-modules in this case.)
Hmmm, I hadn't thought about that. I would need to repro (or see a repro)
with OpenRM to justify changing it. OpenRM doesn't build the registry the
way Nouveau does.
prev parent reply other threads:[~2023-11-08 0:00 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-07 23:47 [PATCH] nouveau/gsp: fix UBSAN array bounds warning in PACKED_REGISTRY_TABLE Timur Tabi
2023-11-07 23:52 ` [Nouveau] " Danilo Krummrich
2023-11-08 0:00 ` Timur Tabi [this message]
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=5905396653318954faeddcd8356f25644cccbb55.camel@nvidia.com \
--to=ttabi@nvidia.com \
--cc=airlied@redhat.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=me@dakr.org \
--cc=nouveau@lists.freedesktop.org \
/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