2023-11-24 17:37:25

by Johannes Berg

[permalink] [raw]
Subject: Re: [PATCH] uapi: propagate __struct_group() attributes to the container union

On Mon, 2023-11-20 at 14:05 +0300, Dmitry Antipov wrote:
> Recently the kernel test robot has reported an ARM-specific BUILD_BUG_ON()
> in an old and unmaintained wil6210 wireless driver.
>

Heh. I guess it wasn't unmaintained enough for someone to touch it and
add struct_group() to it...

> include/uapi/linux/stddef.h | 2 +-
>

No idea what tree this should go through, but I guess wireless isn't
appropriate.

johannes


2023-11-28 00:22:19

by Kees Cook

[permalink] [raw]
Subject: Re: [PATCH] uapi: propagate __struct_group() attributes to the container union

On Fri, Nov 24, 2023 at 06:37:14PM +0100, Johannes Berg wrote:
> On Mon, 2023-11-20 at 14:05 +0300, Dmitry Antipov wrote:
> > Recently the kernel test robot has reported an ARM-specific BUILD_BUG_ON()
> > in an old and unmaintained wil6210 wireless driver.
> >
>
> Heh. I guess it wasn't unmaintained enough for someone to touch it and
> add struct_group() to it...

It needed it since it was using memcpy across fields. But it's been a
while since that change happened, so finding this bug now is pretty
impressive. :)

>
> > include/uapi/linux/stddef.h | 2 +-
> >
>
> No idea what tree this should go through, but I guess wireless isn't
> appropriate.

I'll take it; thanks for the find Dmitry!

--
Kees Cook