diff options
author | Michael Walle <[email protected]> | 2023-01-27 10:40:13 +0000 |
---|---|---|
committer | Greg Kroah-Hartman <[email protected]> | 2023-01-28 14:38:49 +0100 |
commit | db3546d58b5a0fa581d9c9f2bdc2856fa6c5e43e (patch) | |
tree | d964f41332bd51e7f207dafef479b2a79f500684 /tools/testing/selftests/bpf/progs/test_autoload.c | |
parent | edcf2fb660526b5ed29f93bd17328a2b4835c8b2 (diff) |
nvmem: core: fix cell removal on error
nvmem_add_cells() could return an error after some cells are already
added to the provider. In this case, the added cells are not removed.
Remove any registered cells if nvmem_add_cells() fails.
Fixes: fa72d847d68d7 ("nvmem: check the return value of nvmem_add_cells()")
Cc: [email protected]
Signed-off-by: Michael Walle <[email protected]>
Signed-off-by: Srinivas Kandagatla <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'tools/testing/selftests/bpf/progs/test_autoload.c')
0 files changed, 0 insertions, 0 deletions