regmap: kunit: Use a KUnit action to call regmap_exit()
authorRichard Fitzgerald <rf@opensource.cirrus.com>
Mon, 8 Apr 2024 14:45:57 +0000 (15:45 +0100)
committerMark Brown <broonie@kernel.org>
Mon, 8 Apr 2024 15:38:12 +0000 (16:38 +0100)
commitce75e06eea9cfdddaa0082cef663cf2d4aa5ed1d
treec7c35354abdf5e3206dabb329f12677d12572ec1
parent7903d15f008056c8c152f2aa3b36217917853264
regmap: kunit: Use a KUnit action to call regmap_exit()

Registert a KUnit action handler to call regmap_exit() when a test
terminates. This ensures that regmap_exit() will be called if a test
function returns early or aborts.

Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com>
Link: https://msgid.link/r/20240408144600.230848-9-rf@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/base/regmap/regmap-kunit.c