mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
nvmem: sunxi_sid: return -ENOMEM if kzalloc() fails
The driver currently returns -EINVAL if kzalloc() fails in probe(). Change it to -ENOMEM as it should be. Signed-off-by: Bartosz Golaszewski <[email protected]> Signed-off-by: Srinivas Kandagatla <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
parent
c1de7f43bd
commit
424d7033ad
1 changed files with 1 additions and 1 deletions
|
|
@ -187,7 +187,7 @@ static int sunxi_sid_probe(struct platform_device *pdev)
|
|||
|
||||
randomness = kzalloc(size, GFP_KERNEL);
|
||||
if (!randomness) {
|
||||
ret = -EINVAL;
|
||||
ret = -ENOMEM;
|
||||
goto err_unreg_nvmem;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue