Re: [PATCH v2] iio: pressure: dlhl60d: Initialize empty DLH bytes

2024-02-25 Thread Jonathan Cameron
On Fri, 23 Feb 2024 09:50:10 -0800 Kees Cook wrote: > On Fri, Feb 23, 2024 at 07:47:36PM +0200, Andy Shevchenko wrote: > > On Fri, Feb 23, 2024 at 09:29:39AM -0800, Kees Cook wrote: > > > 3 bytes were being read but 4 were being written. Explicitly initialize > > > the unused bytes to 0 and ref

Re: [PATCH v2] iio: pressure: dlhl60d: Initialize empty DLH bytes

2024-02-23 Thread Kees Cook
On Fri, Feb 23, 2024 at 07:47:36PM +0200, Andy Shevchenko wrote: > On Fri, Feb 23, 2024 at 09:29:39AM -0800, Kees Cook wrote: > > 3 bytes were being read but 4 were being written. Explicitly initialize > > the unused bytes to 0 and refactor the loop to use direct array > > indexing, which appears t

Re: [PATCH v2] iio: pressure: dlhl60d: Initialize empty DLH bytes

2024-02-23 Thread Andy Shevchenko
On Fri, Feb 23, 2024 at 07:47:36PM +0200, Andy Shevchenko wrote: > On Fri, Feb 23, 2024 at 09:29:39AM -0800, Kees Cook wrote: > > 3 bytes were being read but 4 were being written. Explicitly initialize > > the unused bytes to 0 and refactor the loop to use direct array > > indexing, which appears t

Re: [PATCH v2] iio: pressure: dlhl60d: Initialize empty DLH bytes

2024-02-23 Thread Andy Shevchenko
On Fri, Feb 23, 2024 at 09:29:39AM -0800, Kees Cook wrote: > 3 bytes were being read but 4 were being written. Explicitly initialize > the unused bytes to 0 and refactor the loop to use direct array > indexing, which appears to silence a Clang false positive warning[1]. ... > for_each_set_b