lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aJnkYn4nN5K6AO2q@smile.fi.intel.com>
Date: Mon, 11 Aug 2025 15:38:58 +0300
From: Andy Shevchenko <andriy.shevchenko@...el.com>
To: Dixit Parmar <dixitparmar19@...il.com>
Cc: Andy Shevchenko <andy.shevchenko@...il.com>,
	Jonathan Cameron <jic23@...nel.org>,
	David Lechner <dlechner@...libre.com>,
	Nuno Sá <nuno.sa@...log.com>,
	Andy Shevchenko <andy@...nel.org>, Rob Herring <robh@...nel.org>,
	Krzysztof Kozlowski <krzk+dt@...nel.org>,
	Conor Dooley <conor+dt@...nel.org>, linux-kernel@...r.kernel.org,
	linux-iio@...r.kernel.org, devicetree@...r.kernel.org
Subject: Re: [PATCH v3 1/2] iio: magnetometer: add support for Infineon
 TLV493D 3D Magentic sensor

On Sat, Aug 09, 2025 at 08:03:54PM +0530, Dixit Parmar wrote:
> On Sat, Aug 09, 2025 at 02:44:00PM +0200, Andy Shevchenko wrote:

...

> > > > > +       data->wr_regs[TLV493D_WR_REG_MODE1] |= mode1_cfg;
> > > > > +       data->wr_regs[TLV493D_WR_REG_MODE2] |= mode2_cfg;
> > > >
> > > > No mask for the existing values in the respective wr_regs? Wouldn't
> > > > you need to use FIELD_MODIFY() instead?
> > > >
> > > I believe, we are doing OR op with the value created using FIELD_PREP,
> > > so it should not interefere with the existing non-masked values.
> > 
> > I am talking about existing values in the array.
> >
> Right. So in that I think it will make more sense to directly use
> FIELD_MODIFY instead of using FIELD_PREP first and then doing this OR
> op. Right?

Just double check carefully, but sounds about right.

> > > However, as FIELD_MODIFY is there, I should utilize it.

-- 
With Best Regards,
Andy Shevchenko



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ