]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: nau8821: Don't unconditionally free interrupt
authorMark Brown <broonie@kernel.org>
Mon, 18 Jul 2022 14:04:05 +0000 (15:04 +0100)
committerMark Brown <broonie@kernel.org>
Tue, 19 Jul 2022 13:54:26 +0000 (14:54 +0100)
commitf60372c4bde61a26341b8f3ca7527bbd587a15df
tree93ebbf88deb57e12c746f99e99a7555e69ea81e2
parent2c940640ed549d87f56081f119971cb8391ee5b3
ASoC: nau8821: Don't unconditionally free interrupt

The remove() operation unconditionally frees the interrupt for the device
but we may not actually have an interrupt so there might be nothing to
free. Since the interrupt is requested after all other resources we don't
need the explicit free anyway, unwinding is guaranteed to be safe, so just
delete the remove() function and let devm take care of things.

Reported-by: Zheyu Ma <zheyuma97@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Tested-by: Zheyu Ma <zheyuma97@gmail.com>
Link: https://lore.kernel.org/r/20220718140405.57233-1-broonie@kernel.org
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/nau8821.c