[Linux-kernel-mentees] [PATCH] acpi: Use DEVICE_ATTR_<RW|RO|WO> macros
dwaipayanray1 at gmail.com
Thu Dec 17 12:43:22 UTC 2020
On Thu, Dec 17, 2020 at 6:08 PM Lukas Bulwahn <lukas.bulwahn at gmail.com> wrote:
> On Thu, Dec 17, 2020 at 1:06 PM Dwaipayan Ray <dwaipayanray1 at gmail.com> wrote:
>> Instead of open coding DEVICE_ATTR(), use the
>> DEVICE_ATTR_RW(), DEVICE_ATTR_RO() and DEVICE_ATTR_WO()
>> macros wherever possible.
>> This required a few functions to be renamed but the
>> functionality itself is unchanged.
>> Signed-off-by: Dwaipayan Ray <dwaipayanray1 at gmail.com>
> Basically looks good. Send it out to the maintainers and await the feedback.
> It could be that this does not meet the naming conventions the maintainers have, but you will see.
> It is certainly worth a try and some discussion.
Sure I will do.
The problem is that the show and store functions must be in the form <name>_show
and <name>_store, otherwise they won't link. There are already existing uses
of DEVICE_ATTR_RW type macros, so hoping they would consider this.
More information about the Linux-kernel-mentees