mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
bus: ti-sysc: Fix optional clocks array access
We should be checking ddata->clocks[i] instead of clock_names[i]
for the optional clocks. Currently this just happens to work for
the typical case of one fck and one optional clock.
Fixes: 09dfe58107 ("bus: ti-sysc: Add handling for clkctrl opt clocks")
Cc: Dan Carpenter <[email protected]>
Reported-by: Dan Carpenter <[email protected]>
Signed-off-by: Tony Lindgren <[email protected]>
This commit is contained in:
parent
dc4c85eac6
commit
c97c862083
1 changed files with 1 additions and 1 deletions
|
|
@ -128,7 +128,7 @@ static int sysc_get_one_clock(struct sysc *ddata, const char *name)
|
|||
|
||||
if (index < 0) {
|
||||
for (i = SYSC_OPTFCK0; i < SYSC_MAX_CLOCKS; i++) {
|
||||
if (!clock_names[i]) {
|
||||
if (!ddata->clocks[i]) {
|
||||
index = i;
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue