Re: [PATCH v2 0/2] nvmem: fix a const-unsoundness in reg_write

Andy Shevchenko <[email protected]>
Newsgroups org.kernel.vger.rust-for-linux,dev.linux.lists.asahi,dev.linux.lists.imx,org.infradead.lists.linux-amlogic,org.infradead.lists.linux-arm-kernel,org.kernel.vger.linux-arm-msm,org.kernel.vger.linux-kernel
Organization Intel Finland Oy - BIC 0357606-4 - c/o Alberga Business Park, 6 krs, Bertel Jungin Aukio 5, 02600 Espoo
Message-ID <[email protected]>
On Thu, Jul 16, 2026 at 01:29:44PM +0200, Link Mauve wrote:
> On Thu, Jul 16, 2026 at 12:03:17PM +0300, Andy Shevchenko wrote:

[…]

> > TL;DR: you should fix the Apple driver (and might more if any of them
> > use that dirty trick).
> 
> It was the only one of the drivers/nvmem/ to do that.  Three other
> drivers use a pattern where they merge read and write operations into a
> single access function with a type=read/write parameter, so const safety
> can’t work there and I’ll continue casting from const void * to void *
> in the write function to keep that pattern working.

I meant all the driver in the kernel that are going to be affected by this
change.

-- 
With Best Regards,
Andy Shevchenko
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.