regmap: kunit: Replace a kmalloc/kfree() pair with KUnit-managed alloc
authorRichard Fitzgerald <rf@opensource.cirrus.com>
Mon, 8 Apr 2024 14:45:58 +0000 (15:45 +0100)
committerMark Brown <broonie@kernel.org>
Mon, 8 Apr 2024 15:38:13 +0000 (16:38 +0100)
commitd6f2fd7adcb5f25ac661808be9409f846b1de6fe
tree6753e1f336b1d96e42b5fdb150764a55fc427aee
parentce75e06eea9cfdddaa0082cef663cf2d4aa5ed1d
regmap: kunit: Replace a kmalloc/kfree() pair with KUnit-managed alloc

Replace the kmalloc() and kfree() in raw_read_defaults() with a
kunit_kmalloc() so that KUnit will free it automatically.

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