clk: gate: add clk_always_on for debug
use: bootargs = "earlycon=uart8250,mmio32,0xfe660000 console=ttyFIQ0 clk_gate.always_on=y"; Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com> Change-Id: Iff38f71b31bf1de4b5e18bdaefd695d60cd2e124
This commit is contained in:
parent
cddd9bf436
commit
9fd1dbb405
|
|
@ -13,6 +13,10 @@
|
|||
#include <linux/err.h>
|
||||
#include <linux/string.h>
|
||||
|
||||
static bool clk_always_on;
|
||||
module_param_named(always_on, clk_always_on, bool, 0644);
|
||||
MODULE_PARM_DESC(always_on, "Always keep clks on except for system suspend.");
|
||||
|
||||
/**
|
||||
* DOC: basic gatable clock which can gate and ungate it's ouput
|
||||
*
|
||||
|
|
@ -59,6 +63,9 @@ static void clk_gate_endisable(struct clk_hw *hw, int enable)
|
|||
unsigned long flags;
|
||||
u32 reg;
|
||||
|
||||
if (clk_always_on && !enable)
|
||||
return;
|
||||
|
||||
set ^= enable;
|
||||
|
||||
if (gate->lock)
|
||||
|
|
|
|||
Loading…
Reference in New Issue