Page MenuHomeFreeBSD

D17978.id50371.diff
No OneTemporary

D17978.id50371.diff

Index: sys/dev/extres/regulator/regulator_fixed.c
===================================================================
--- sys/dev/extres/regulator/regulator_fixed.c
+++ sys/dev/extres/regulator/regulator_fixed.c
@@ -161,10 +161,13 @@
enable = sc->param->boot_on || sc->param->always_on;
if (!sc->param->enable_active_high)
enable = !enable;
- rv = GPIO_PIN_SET(pin->dev, pin->pin, enable);
- if (rv != 0) {
- device_printf(dev, "Cannot set GPIO pin: %d\n", pin->pin);
- return (rv);
+ if (enable) {
+ rv = GPIO_PIN_SET(pin->dev, pin->pin, enable);
+ if (rv != 0) {
+ device_printf(dev, "Cannot set GPIO pin: %d\n",
+ pin->pin);
+ return (rv);
+ }
}
rv = GPIO_PIN_SETFLAGS(pin->dev, pin->pin, flags);
if (rv != 0) {

File Metadata

Mime Type
text/plain
Expires
Sun, Oct 18, 6:34 PM (3 h, 58 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
41007836
Default Alt Text
D17978.id50371.diff (743 B)

Event Timeline