From: Thomas Hellstrom <thellstrom@vmware.com>
To: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: linux-input@vger.kernel.org,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Input: serio - fix sysfs layout
Date: Sat, 07 Dec 2013 21:51:56 +0100 [thread overview]
Message-ID: <52A38A6C.6040005@vmware.com> (raw)
In-Reply-To: <20131207154116.GA9902@core.coreip.homeip.net>
On 12/07/2013 04:41 PM, Dmitry Torokhov wrote:
> Restore previous layout of sysfs attributes that was broken by commit
> 3778a2129bcce84f684cc0017ed20d2524afd289 (input: serio: remove bus usage of
> dev_attrs) which moved all serio device attributes into 'id' group, when
> only 'type', 'proto', 'id', and 'extra' should be in 'id' group and the
> rest of attributes should be attached directly to the device.
Thanks for doing this. Makes vmmouse work again.
>
> Reported-by: Thomas Hellstrom <thellstrom@vmware.com>
> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Tested-by: Thomas Hellstrom <thellstrom@vmware.com>
> ---
> drivers/input/serio/serio.c | 24 +++++++++++++++++-------
> 1 file changed, 17 insertions(+), 7 deletions(-)
>
> diff --git a/drivers/input/serio/serio.c b/drivers/input/serio/serio.c
> index 98707fb..8f4c4ab 100644
> --- a/drivers/input/serio/serio.c
> +++ b/drivers/input/serio/serio.c
> @@ -455,16 +455,26 @@ static DEVICE_ATTR_RO(type);
> static DEVICE_ATTR_RO(proto);
> static DEVICE_ATTR_RO(id);
> static DEVICE_ATTR_RO(extra);
> -static DEVICE_ATTR_RO(modalias);
> -static DEVICE_ATTR_WO(drvctl);
> -static DEVICE_ATTR(description, S_IRUGO, serio_show_description, NULL);
> -static DEVICE_ATTR(bind_mode, S_IWUSR | S_IRUGO, serio_show_bind_mode, serio_set_bind_mode);
>
> static struct attribute *serio_device_id_attrs[] = {
> &dev_attr_type.attr,
> &dev_attr_proto.attr,
> &dev_attr_id.attr,
> &dev_attr_extra.attr,
> + NULL
> +};
> +
> +static struct attribute_group serio_id_attr_group = {
> + .name = "id",
> + .attrs = serio_device_id_attrs,
> +};
> +
> +static DEVICE_ATTR_RO(modalias);
> +static DEVICE_ATTR_WO(drvctl);
> +static DEVICE_ATTR(description, S_IRUGO, serio_show_description, NULL);
> +static DEVICE_ATTR(bind_mode, S_IWUSR | S_IRUGO, serio_show_bind_mode, serio_set_bind_mode);
> +
> +static struct attribute *serio_device_attrs[] = {
> &dev_attr_modalias.attr,
> &dev_attr_description.attr,
> &dev_attr_drvctl.attr,
> @@ -472,13 +482,13 @@ static struct attribute *serio_device_id_attrs[] = {
> NULL
> };
>
> -static struct attribute_group serio_id_attr_group = {
> - .name = "id",
> - .attrs = serio_device_id_attrs,
> +static struct attribute_group serio_device_attr_group = {
> + .attrs = serio_device_attrs,
> };
>
> static const struct attribute_group *serio_device_attr_groups[] = {
> &serio_id_attr_group,
> + &serio_device_attr_group,
> NULL
> };
>
prev parent reply other threads:[~2013-12-07 20:51 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-07 15:41 [PATCH] Input: serio - fix sysfs layout Dmitry Torokhov
2013-12-07 17:12 ` Greg Kroah-Hartman
2013-12-07 20:51 ` Thomas Hellstrom [this message]
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=52A38A6C.6040005@vmware.com \
--to=thellstrom@vmware.com \
--cc=dmitry.torokhov@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.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).