ALSA: hda/ca0132 - Simplify alt firmware loading code
authorTakashi Iwai <tiwai@suse.de>
Fri, 22 Mar 2019 14:51:36 +0000 (15:51 +0100)
committerTakashi Iwai <tiwai@suse.de>
Fri, 22 Mar 2019 19:57:29 +0000 (20:57 +0100)
commit4fc90fb883fcb72d6bfbf84d554a3e820a05ef62
treeae5dc16bdacbe8069ffea550e153a052051bd081
parentca0214ee2802dd47239a4e39fb21c5b00ef61b22
ALSA: hda/ca0132 - Simplify alt firmware loading code

ca0132 codec driver loads the firmware selectively depending on the
model in addition to the fallback of the default firmware.  The code
works good, but a minor problem is that the current code seems
confusing for Clang where it spews a warning about uninitialized
variable.

This patch simplifies the code flow for such a false-positive
warning.  After this refactoring, the ca0132_spec.alt_firmware_present
field is no longer used, hence it's eliminated as well.

Reported-and-tested-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Nathan Chancellor <natechancellor@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/hda/patch_ca0132.c