[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.44L0.1101191704080.3655-100000@iolanthe.rowland.org>
Date: Wed, 19 Jan 2011 17:05:16 -0500 (EST)
From: Alan Stern <stern@...land.harvard.edu>
To: "Rafael J. Wysocki" <rjw@...k.pl>
cc: Linux-pm mailing list <linux-pm@...ts.linux-foundation.org>,
Len Brown <lenb@...nel.org>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [RFC][PATCH] PM: Do not create wakeup sysfs files for devices
that cannot wakeup
On Sat, 15 Jan 2011, Rafael J. Wysocki wrote:
> OK, I think that problem is not present any more in the new version of the
> patch, which is appended.
>
> > Apart from that, it all seems reasonable. But you should change the
> > description of the wakeup attribute in Documentation/power/devices.txt;
> > it says that the attribute file is present but empty if the device is
> > not wakeup-capable.
>
> Right and not only that. The descriptions in ABI/sysfs-device-power have to be
> updated too.
>
> Thanks,
> Rafael
>
> ---
> From: Rafael J. Wysocki <rjw@...k.pl>
> Subject: PM: Do not create wakeup sysfs files for devices that cannot wake up
>
> Currently, wakeup sysfs attributes are created for all devices,
> regardless of whether or not they are wakeup-capable. This is
> excessive and complicates wakeup device identification from user
> space (i.e. to identify wakeup-capable devices user space has to read
> /sys/devices/.../power/wakeup for all devices and see if they are not
> empty).
>
> Fix this issue by avoiding to create wakeup sysfs files for devices
> that cannot wake up the system from sleep states (i.e. whose
> power.can_wakeup flags are unset during registration) and modify
> device_set_wakeup_capable() so that it adds (or removes) the relevant
> sysfs attributes if a device's wakeup capability status is changed.
Yes, this all looks okay to me.
Alan Stern
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists