[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <12aedee1-9f13-266c-c398-2ec3d31212d1@huawei.com>
Date: Thu, 1 Sep 2022 11:52:23 +0100
From: John Garry <john.garry@...wei.com>
To: "Rafael J. Wysocki" <rafael@...nel.org>
CC: Andy Shevchenko <andy.shevchenko@...il.com>,
Len Brown <lenb@...nel.org>,
ACPI Devel Maling List <linux-acpi@...r.kernel.org>,
"Linux Kernel Mailing List" <linux-kernel@...r.kernel.org>,
Linuxarm <linuxarm@...wei.com>
Subject: Re: [PATCH PoC 2/3] ACPI: platform: Refactor
acpi_create_platform_device()
On 23/08/2022 17:42, Rafael J. Wysocki wrote:
>>>
>>>> +struct platform_device *acpi_create_platform_device_ops(
>>>> + struct acpi_device *adev,
>>>> + const char *name,
>>>> + const struct property_entry *properties,
>>>> + void *data, size_t size_data,
>>>> + int (*xlat)(struct acpi_device *adev,
>>>> + struct resource *res,
>>>> + void *data, size_t size_data),
>>>> + int id);
>>> ...because this looks a bit too much from the amount of parameters
>>> point of view.
>>>
>> ok, agreed.
Hi Rafael,
>>
>> But even if we improve this code, the hisi_lpc changes are quite large
>> and unwieldly.
> Well, they allow you to drop quite a few LOC ...
Sure, but the ACPI platform device code here is growing by about the
same amount :) However maybe we can reduce that with Andy's idea to
create a struct of function args. But first I will go with using
platform_device_register_full() in hisi_lpc.
And you please also check the PNP patch? I am not so keen on pushing for
that.
thanks,
John
Powered by blists - more mailing lists