Closed plbossart closed 4 months ago
sof_wm8804.c is missed. adev = acpi_dev_get_first_match_dev(mach->id, NULL, -1);
sof_wm8804.c is missed. adev = acpi_dev_get_first_match_dev(mach->id, NULL, -1);
indeed, thanks for noticing @bardliao. Fixed now.
updated commit title, no code change.
…_dev()
The code seems mostly copy-pasted, with some machine drivers forgetting to test if the 'adev' result is NULL.
Add this check when missing, and use -ENOENT consistently as an error code.
Link: https://lore.kernel.org/alsa-devel/918944d2-3d00-465e-a9d1-5d57fc966113@stanley.mountain/T/#u Reported-by: Dan Carpenter dan.carpenter@linaro.org