lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 9 Nov 2023 11:31:16 +0000
From:   Mark Brown <broonie@...nel.org>
To:     Naresh Solanki <naresh.solanki@...ements.com>
Cc:     zev@...ilderbeest.net, Liam Girdwood <lgirdwood@...il.com>,
        Patrick Rudolph <patrick.rudolph@...ements.com>,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] drivers/regulator: Notify sysfs about status changes

On Thu, Nov 09, 2023 at 04:08:06PM +0530, Naresh Solanki wrote:
> On Thu, 2 Nov 2023 at 22:20, Mark Brown <broonie@...nel.org> wrote:

> > Ah, right.  Everything except for the enable and disable there looks
> > like it should be OK since they should normally just not happen but the
> > enables and disables might get a bit frequent with runtime PM - not
> > *super* frequent like voltage scaling but enough that people could have
> > an issue with it.

> I aim for a straightforward implementation.
> Using attributes such as status or state seems ideal for receiving
> notifications.
> In my case, the application focuses on status changes—whether it's on, off,
> or encountering an error.
> These changes are driven by events originating from the regulator.
> So below change is what I see fit well.
> 
>         status_events = REGULATOR_EVENT_DISABLE;
>         status_events |= REGULATOR_EVENT_ENABLE;
>         status_events |= REGULATOR_EVENT_FAIL;
>         status_events |= REGULATOR_EVENT_FORCE_DISABLE;
>         status_events |= REGULATOR_EVENT_ABORT_DISABLE;

In terms of the implementation for delivering uevents this looks fine,
my concern here is that for some systems the enable and disable events
might happen more often than is really a good fir for delivering via
uevents, if a device like say a SD card is getting powered up and down
via runtime PM that might happen relatively often and then the system
would get a lot of uevents which it would most likely end up ignoring.
That could have a noticable impact on power or performance.

Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ