ALSA: hda: cs35l41: Use auto-cleanup for firmware loading

Simplify the code to manage the firmware loading with auto-cleanup
with __free(firmware).  A NULL clear is added at
cs35l41_request_firmware_file() for avoiding the double-free.

Note that the driver still keeps a few manual firmware releases
because it retries with different firmware files when one of firmware
pairs fails.

Only the code refactoring, no functional changes.

Cc: patches@opensource.cirrus.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Link: https://patch.msgid.link/20260729083735.120219-6-tiwai@suse.de
This commit is contained in:
Takashi Iwai 2026-07-29 10:37:23 +02:00
commit 81d3f40154