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: <MN2PR03MB51681CCFD911F63CE32E914AE7949@MN2PR03MB5168.namprd03.prod.outlook.com>
Date:   Sun, 9 Apr 2023 16:48:35 +0000
From:   "Sahin, Okan" <Okan.Sahin@...log.com>
To:     Lee Jones <lee@...nel.org>,
        Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
CC:     Rob Herring <robh+dt@...nel.org>,
        Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
        Liam Girdwood <lgirdwood@...il.com>,
        Mark Brown <broonie@...nel.org>,
        Jonathan Cameron <jic23@...nel.org>,
        Lars-Peter Clausen <lars@...afoo.de>,
        Cosmin Tanislav <demonsingur@...il.com>,
        Stephen Boyd <sboyd@...nel.org>,
        Caleb Connolly <caleb.connolly@...aro.org>,
        Lad Prabhakar <prabhakar.mahadev-lad.rj@...renesas.com>,
        "Bolboaca, Ramona" <Ramona.Bolboaca@...log.com>,
        ChiYuan Huang <cy_huang@...htek.com>,
        "Tilki, Ibrahim" <Ibrahim.Tilki@...log.com>,
        William Breathitt Gray <william.gray@...aro.org>,
        Arnd Bergmann <arnd@...db.de>,
        ChiaEn Wu <chiaen_wu@...htek.com>,
        Haibo Chen <haibo.chen@....com>,
        "devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "linux-iio@...r.kernel.org" <linux-iio@...r.kernel.org>
Subject: RE: [PATCH v6 5/5]  mfd: max77541: Add ADI MAX77541/MAX77540 PMIC
 Support

>On Wed, 05 Apr 2023, Andy Shevchenko wrote:
>
>> On Mon, Apr 03, 2023 at 03:09:50PM +0100, Lee Jones wrote:
>> > On Mon, 03 Apr 2023, Sahin, Okan wrote:
>>
>> ...
>>
>>
>> > > In fact, one of the maintainers suggested assigning chip_info to data
>> > > instead of enumeration. Then I added chip_info and put devices into
>> > > sub-structure above. I will replace chip_info with id structure in max77541
>> > > device structure, right? I will use enumeration for data as I will assign
>> > > it to id, and distinguish different devices.
>> >
>> > Yes, that's correct.  Please remove chip_info altogether.
>>
>> Then it will provoke casting in the OF ID table which I believe is not what
>> we want. I would agree on your first suggestion to have a plain number in I²C
>> ID table, but I'm against it in OF and/or ACPI ID table.
>
>And I'm against passing MFD information through the OF/ACPI APIs.
>
>You can put through raw platform data or a device descriptor.
>
>Ref: git grep -A5 "struct of_device_id.*{" -- drivers/mfd
>
>--
>Lee Jones [李琼斯]

Hi Lee,

Right now, as you suggested I rewrote code like below
For of_device_id,
	. data = (void *)MAX77540,
	.data = (void *)MAX77541,
For i2c_device_id,
	.data  = MAX77540,
	.data = MAX77541
I also rewrote other part as chip_info is excluded. I want to be sure before
sending new patch.

Does it seem correct?

Regards,
Okan Sahin

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ