mirror of
https://github.com/torvalds/linux.git
synced 2026-05-30 01:53:29 +02:00
clk: thead: th1520-ap: Add macro to define multiplexers with flags
The new macro, TH_CCU_MUX_FLAGS, extends TH_CCU_MUX macro by adding two parameters to specify clock flags and multiplexer flags. Reviewed-by: Drew Fustini <fustini@kernel.org> Signed-off-by: Yao Zi <ziyao@disroot.org> Signed-off-by: Drew Fustini <fustini@kernel.org>
This commit is contained in:
parent
238cc6316a
commit
5dbee35037
|
|
@ -101,17 +101,22 @@ struct ccu_pll {
|
|||
.flags = _flags, \
|
||||
}
|
||||
|
||||
#define TH_CCU_MUX(_name, _parents, _shift, _width) \
|
||||
#define TH_CCU_MUX_FLAGS(_name, _parents, _shift, _width, _flags, \
|
||||
_mux_flags) \
|
||||
{ \
|
||||
.mask = GENMASK(_width - 1, 0), \
|
||||
.shift = _shift, \
|
||||
.flags = _mux_flags, \
|
||||
.hw.init = CLK_HW_INIT_PARENTS_DATA( \
|
||||
_name, \
|
||||
_parents, \
|
||||
&clk_mux_ops, \
|
||||
0), \
|
||||
_flags), \
|
||||
}
|
||||
|
||||
#define TH_CCU_MUX(_name, _parents, _shift, _width) \
|
||||
TH_CCU_MUX_FLAGS(_name, _parents, _shift, _width, 0, 0)
|
||||
|
||||
#define CCU_GATE(_clkid, _struct, _name, _parent, _reg, _bit, _flags) \
|
||||
struct ccu_gate _struct = { \
|
||||
.clkid = _clkid, \
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user