linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Chen-Yu Tsai <wens@csie.org>
Cc: Quentin Schulz <quentin.schulz@free-electrons.com>,
	Lee Jones <lee.jones@linaro.org>,
	Hans de Goede <hdegoede@redhat.com>,
	"linux-input@vger.kernel.org" <linux-input@vger.kernel.org>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	Thomas Petazzoni <thomas.petazzoni@free-electrons.com>,
	Maxime Ripard <maxime.ripard@free-electrons.com>
Subject: Re: [PATCH v3 1/2] Input: axp20x-pek: use driver_data of platform_device_id instead of extended attributes
Date: Wed, 16 Aug 2017 17:46:02 -0700	[thread overview]
Message-ID: <20170817004602.GE25491@dtor-ws> (raw)
In-Reply-To: <CAGb2v65xoUZA+AGb+1LEba-ccmDdLo6YyAB1nqo2uKUN7x=2kA@mail.gmail.com>

On Mon, Aug 14, 2017 at 06:03:44PM +0800, Chen-Yu Tsai wrote:
> On Wed, Aug 9, 2017 at 5:45 PM, Quentin Schulz
> <quentin.schulz@free-electrons.com> wrote:
> > To prepare an upcoming patch adding support for another PMIC that has
> > different startup and shutdown time, use driver_data of
> > platform_device_id instead of a fixed extended device attribute.
> >
> > By doing so, we also remove a lot of nested structures that aren't
> > useful.
> >
> > With this patch, a new PMIC can be easily supported by just filling
> > correctly its ax20x_info structure and adding a platform_device_id.
> >
> > Moreover, since we get rid of extended attributes, rename
> > axp20x_store_ext_attr to axp20x_store_attr and axp20x_show_ext_attr to
> > axp20x_show_attr.
> >
> > Signed-off-by: Quentin Schulz <quentin.schulz@free-electrons.com>
> 
> Acked-by: Chen-Yu Tsai <wens@csie.org>

Applied, thank you.

> 
> [...]
> 
> > +
> > +DEVICE_ATTR(startup, 0644, axp20x_show_attr_startup, axp20x_store_attr_startup);
> > +DEVICE_ATTR(shutdown, 0644, axp20x_show_attr_shutdown,
> > +           axp20x_store_attr_shutdown);
> >
> 
> You could use DEVICE_ATTR_RW(...) if you renamed the function names to
> fit the macro if you wanted.

-- 
Dmitry

  reply	other threads:[~2017-08-17  0:46 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-09  9:45 [PATCH v3 0/2] add support for AXP22X/AXP288/AXP8XX PEK Quentin Schulz
2017-08-09  9:45 ` [PATCH v3 1/2] Input: axp20x-pek: use driver_data of platform_device_id instead of extended attributes Quentin Schulz
2017-08-14 10:03   ` Chen-Yu Tsai
2017-08-17  0:46     ` Dmitry Torokhov [this message]
2017-08-09  9:45 ` [PATCH v3 2/2] Input: axp20x-pek: add support for AXP221 PEK Quentin Schulz
2017-08-17  0:46   ` Dmitry Torokhov

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=20170817004602.GE25491@dtor-ws \
    --to=dmitry.torokhov@gmail.com \
    --cc=hdegoede@redhat.com \
    --cc=lee.jones@linaro.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maxime.ripard@free-electrons.com \
    --cc=quentin.schulz@free-electrons.com \
    --cc=thomas.petazzoni@free-electrons.com \
    --cc=wens@csie.org \
    /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).