From: Dwaipayan Ray <dwaipayanray1@gmail.com>
To: Lukas Bulwahn <lukas.bulwahn@gmail.com>
Cc: linux-leds@vger.kernel.org,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Dan Murphy <dmurphy@ti.com>, Pavel Machek <pavel@ucw.cz>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
linux-kernel-mentees@lists.linuxfoundation.org
Subject: Re: [PATCH] leds: Use DEVICE_ATTR_{RW, RO, WO} macros
Date: Sun, 13 Dec 2020 13:48:58 +0530 [thread overview]
Message-ID: <CABJPP5BeB-aXDDk-8vy-8dOaNaM5jitx6QWKtV7Y3zXM5DgvUA@mail.gmail.com> (raw)
In-Reply-To: <CAKXUXMx9EnhWhGAJf4ousAgkxDUrN=g2zGaPEk6ijJYse7VJaQ@mail.gmail.com>
On Sun, Dec 13, 2020 at 1:31 PM Lukas Bulwahn <lukas.bulwahn@gmail.com> wrote:
>
> On Sat, Dec 12, 2020 at 8:56 PM Dwaipayan Ray <dwaipayanray1@gmail.com> wrote:
> >
> > Instead of open coding DEVICE_ATTR() defines, use the
> > DEVICE_ATTR_RW(), DEVICE_ATTR_WO(), and DEVICE_ATTR_RO()
> > macros intead.
>
> typo: s/intead/instead/
>
> No need to use the word "instead" twice in one sentence, though, we got it :)
>
> >
> > This required a few functions to be renamed, but the functionality
> > itself is unchanged.
> >
> > Note that this is compile tested only.
> >
>
> This note does not go in the commit message. In the future, this will
> be simply not true anymore, but this below the "---" (see HERE! as
> marker).
>
> For testing, you can generate the objdump of the binary before and
> after and compare if that is as expected.
>
> Other than that, the change itself looks good to me, so:
>
> Reviewed-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
>
> Thanks, Dwaipayan, for fixing this up.
>
> Will you also add a checkpatch rule to identify other DEVICE_ATTR(...)
> that can be adjusted to the refined macros, so that checkpatch informs
> other submitters as well?
>
I think a checkpatch rule for this already exists. But it cannot automatically
rename the function names. That might be the only drawback we got.
Probably clang-format could fix these automatically.
> > Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> > Cc: Dan Murphy <dmurphy@ti.com>
> > Cc: Pavel Machek <pavel@ucw.cz>
> > Cc: Lukas Bulwahn <lukas.bulwahn@gmail.com>
> > Cc: linux-leds@vger.kernel.org
> > Cc: linux-kernel@vger.kernel.org
> > Cc: linux-kernel-mentees@lists.linuxfoundation.org
>
> As far as I know, the maintainers will add the Cc lines---if they like
> those---with script support.
>
I thought I might ease the work of maintainers to add those lines :(
But nevertheless I will remove them.
> > Signed-off-by: Dwaipayan Ray <dwaipayanray1@gmail.com>
> > ---
>
> HERE!
>
Thanks Lukas.
I will be sending in a v2 if the led maintainers have no problem with
this patch.
Thank you,
Dwaipayan.
next prev parent reply other threads:[~2020-12-13 8:20 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-12 19:55 [PATCH] leds: Use DEVICE_ATTR_{RW, RO, WO} macros Dwaipayan Ray
2020-12-13 8:00 ` Lukas Bulwahn
2020-12-13 8:18 ` Dwaipayan Ray [this message]
2020-12-13 8:40 ` Joe Perches
2020-12-13 19:46 ` Miguel Ojeda
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CABJPP5BeB-aXDDk-8vy-8dOaNaM5jitx6QWKtV7Y3zXM5DgvUA@mail.gmail.com \
--to=dwaipayanray1@gmail.com \
--cc=dmurphy@ti.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel-mentees@lists.linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-leds@vger.kernel.org \
--cc=lukas.bulwahn@gmail.com \
--cc=pavel@ucw.cz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).