ALSA: mpu401: Allocate resources with device-managed APIs
authorTakashi Iwai <tiwai@suse.de>
Thu, 15 Jul 2021 07:59:38 +0000 (09:59 +0200)
committerTakashi Iwai <tiwai@suse.de>
Mon, 19 Jul 2021 14:17:30 +0000 (16:17 +0200)
commitde74763295a8a2b219be43b41513285a82920c4e
treeabc111cd9de9c0a2399bed5b849b432eea47c704
parent60d03de81c40270eab06b29c502a12ccb3b1cf4c
ALSA: mpu401: Allocate resources with device-managed APIs

This patch converts the card object management with devres as a clean
up.  The remove callback gets reduced by that.

This should give no user-visible functional changes.

Note that this converts only the mpu401 card driver.  The mpu401_uart
component is still managed with snd_device.  It's for the case where
the mpu401_uart component may be removed dynamically without the
actual device unbind.

Link: https://lore.kernel.org/r/20210715075941.23332-77-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/drivers/mpu401/mpu401.c