mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
[media] of: reserved_mem: restore old behavior when no region is defined
Change return value back to -ENODEV when no region is defined for given
device. This restores old behavior of this function, as some drivers rely
on such error code.
Fixes: 59ce403972 ("of: reserved_mem: add support for using more than
one region for given device")
Reported-by: Liviu Dudau <[email protected]>
Signed-off-by: Marek Szyprowski <[email protected]>
Reviewed-by: Sylwester Nawrocki <[email protected]>
Reviewed-by: Liviu Dudau <[email protected]>
Acked-by: Rob Herring <[email protected]>
Reviewed-by: Sumit Semwal <[email protected]>
This commit is contained in:
parent
bd3df3c53e
commit
9f5a802b1d
1 changed files with 1 additions and 1 deletions
|
|
@ -327,7 +327,7 @@ int of_reserved_mem_device_init_by_idx(struct device *dev,
|
|||
|
||||
target = of_parse_phandle(np, "memory-region", idx);
|
||||
if (!target)
|
||||
return -EINVAL;
|
||||
return -ENODEV;
|
||||
|
||||
rmem = __find_rmem(target);
|
||||
of_node_put(target);
|
||||
|
|
|
|||
Loading…
Reference in a new issue