22 lines
726 B
C
22 lines
726 B
C
|
/*
|
||
|
* Copyright (c) 2020 Nuvoton Technology Corporation.
|
||
|
*
|
||
|
* SPDX-License-Identifier: Apache-2.0
|
||
|
*/
|
||
|
|
||
|
#ifndef _NUVOTON_NPCX_SOC_DT_H_
|
||
|
#define _NUVOTON_NPCX_SOC_DT_H_
|
||
|
|
||
|
/*
|
||
|
* Construct a npcx_clk_cfg item from clocks prop which type is 'phandle-array'
|
||
|
* to handle "clock-cells" in current driver device
|
||
|
*/
|
||
|
#define DT_NPCX_CLK_CFG_ITEM(inst) \
|
||
|
{ \
|
||
|
.bus = DT_PHA(DT_DRV_INST(inst), clocks, bus), \
|
||
|
.ctrl = DT_PHA(DT_DRV_INST(inst), clocks, ctl), \
|
||
|
.bit = DT_PHA(DT_DRV_INST(inst), clocks, bit), \
|
||
|
}
|
||
|
|
||
|
#endif /* _NUVOTON_NPCX_SOC_DT_H_ */
|