Skip to content

Commit fa5c107

Browse files
Loic Poulainlinvjw
authored andcommitted
net: rfkill: gpio: Fix clock status
Clock is disabled when the device is blocked. So, clock_enabled is the logical negation of "blocked". Signed-off-by: Loic Poulain <[email protected]> Signed-off-by: John W. Linville <[email protected]>
1 parent 5c244fa commit fa5c107

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/rfkill/rfkill-gpio.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ static int rfkill_gpio_set_power(void *data, bool blocked)
5454
if (blocked && !IS_ERR(rfkill->clk) && rfkill->clk_enabled)
5555
clk_disable(rfkill->clk);
5656

57-
rfkill->clk_enabled = blocked;
57+
rfkill->clk_enabled = !blocked;
5858

5959
return 0;
6060
}

0 commit comments

Comments
 (0)