Re: [PATCH v3 2/7] regulator: Handle system-critical under-voltage events

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Oct 25, 2023 at 10:46:09AM +0200, Oleksij Rempel wrote:

> +	if (rdev->constraints->system_critical &&
> +	    event == REGULATOR_EVENT_UNDER_VOLTAGE)
> +		hw_protection_shutdown("System critical voltage drop detected",
> +				       REGULATOR_DEF_EMERG_SHUTDWN_TMO);
> +

This should probably be a switch statement for the event and also handle
REGULATOR_EVENT_FAIL, possibly other errors this would also be
appropriate handling but it's less immediately obvious and we can
always extend later.

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux