drivers: sai: Use 0x0 as clock id if none is provided
We use the name cell at a given index to retrieve a clock's id. But not all clocks provide a name cell, so use 0x0 as clock-id for these situations. Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
This commit is contained in:
parent
0687522cd4
commit
4f88301bc9
|
@ -38,7 +38,7 @@ LOG_MODULE_REGISTER(nxp_dai_sai);
|
|||
|
||||
/* used to retrieve a clock's ID using its index generated via _SAI_CLOCK_INDEX_ARRAY */
|
||||
#define _SAI_GET_CLOCK_ID(clock_idx, inst)\
|
||||
DT_INST_CLOCKS_CELL_BY_IDX(inst, clock_idx, name)
|
||||
DT_INST_PHA_BY_IDX_OR(inst, clocks, clock_idx, name, 0x0)
|
||||
|
||||
/* used to retrieve a clock's name using its index generated via _SAI_CLOCK_INDEX_ARRAY */
|
||||
#define _SAI_GET_CLOCK_NAME(clock_idx, inst)\
|
||||
|
|
Loading…
Reference in New Issue