mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-11 21:38:32 +08:00
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 <loic.poulain@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
5c244fa2c9
commit
fa5c107cc8
@ -54,7 +54,7 @@ static int rfkill_gpio_set_power(void *data, bool blocked)
|
||||
if (blocked && !IS_ERR(rfkill->clk) && rfkill->clk_enabled)
|
||||
clk_disable(rfkill->clk);
|
||||
|
||||
rfkill->clk_enabled = blocked;
|
||||
rfkill->clk_enabled = !blocked;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user