lkml.org 
[lkml]   [2023]   [Nov]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] regulator: core: Add option to prevent disabling unused regulators
Date
Mark Brown <broonie@kernel.org> writes:

> On Wed, Nov 01, 2023 at 10:26:52AM +0530, Manivannan Sadhasivam wrote:
>
>> On the other note, I'm wondering if we could use sync_state() for handling the
>> regulator_init_complete() work. This would ensure that the regulators are only
>> disabled when all the consumers are probed.
>
> That assumes that everything defined in the DT both has a driver and has
> the driver available for the currently running kernel neither of which
> is a good assumption.

Agreed. I believe the current logic of disabling all regulators using a
workqueue is the correct thing to do.

The only better option I think is to make user-space notify the kernel
that it won't load kernel modules anymore. But the delayed work would
sill be needed, since the kernel can't make an assumption on whether
user-space will notify of this or not.

--
Best regards,

Javier Martinez Canillas
Core Platforms
Red Hat

\
 
 \ /
  Last update: 2023-11-02 10:36    [W:0.271 / U:0.000 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site