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: <aQI4v1lVcagBWY3i@lizhi-Precision-Tower-5810>
Date: Wed, 29 Oct 2025 11:54:39 -0400
From: Frank Li <Frank.li@....com>
To: Andy Shevchenko <andriy.shevchenko@...el.com>
Cc: Alexandre Belloni <alexandre.belloni@...tlin.com>,
	Miquel Raynal <miquel.raynal@...tlin.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-i3c@...ts.infradead.org,
	linux-kernel@...r.kernel.org, imx@...ts.linux.dev,
	linux-iio@...r.kernel.org, joshua.yeong@...rfivetech.com,
	devicetree@...r.kernel.org, Carlos Song <carlos.song@....com>,
	Adrian Fluturel <fluturel.adrian@...il.com>
Subject: Re: [PATCH v7 5/5] iio: magnetometer: Add mmc5633 sensor

On Tue, Oct 28, 2025 at 12:50:55PM +0200, Andy Shevchenko wrote:
> On Mon, Oct 27, 2025 at 04:08:33PM -0400, Frank Li wrote:

After update patch, I met some problem, so reply at prevous your email.

> > +	struct device *dev;
> > +	struct i3c_device *i3cdev;
> > +	struct mutex mutex; /* protect to finish one whole measurement */
> > +	struct regmap *regmap;
>
> regmap has struct device, i3c_device presumable also, and here is struct
> device. Don't we have some overhead?

*dev already removed. i3cdev is kept as my reply at yesterday.

>
> > +static const struct {
> > +   int val;
> > +   int val2;
>
> No need. Just
>
> > +} mmc5633_samp_freq[] = {

There are some place will like

        if (mmc5633_samp_freq[i][0] == val &&
                mmc5633_samp_freq[i][1] == val2)

previous
        if (mmc5633_samp_freq[i].val == val &&
                mmc5633_samp_freq[i].val2 == val2)

Previous version seem have better readablity. But it is not big deal, if
you like, I change to [0][1].

>
> struct i3c_device doesn't have a name, does it?

It has name, but it is hexnumber (VID+PID), like 0-4a20000f000.
So use friend/readable name here.

Frank

>
> --
> With Best Regards,
> Andy Shevchenko
>
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ