Re: [Nouveau] [PATCH] nouveau/gsp: fix UBSAN array bounds warning in PACKED_REGISTRY_TABLE

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

 



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.






[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux