diff options
author | Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> | 2024-08-27 20:32:01 +0800 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2024-08-28 13:01:53 +0100 |
commit | 14e91ddd5c02d8c3e5a682ebfa0546352b459911 (patch) | |
tree | 6a1e1917c3d52fb20f18d0db54df46b3315daf0f /lib/trace_readwrite.c | |
parent | 1ab959bea29c265d7d219346a72ed15b2490d956 (diff) |
ASoC: Intel: boards: always check the result of acpi_dev_get_first_match_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.
Reported-by: Dan Carpenter <dan.carpenter@linaro.org>
Closes: https://lore.kernel.org/alsa-devel/918944d2-3d00-465e-a9d1-5d57fc966113@stanley.mountain/T/#u
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com>
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Link: https://patch.msgid.link/20240827123215.258859-4-yung-chuan.liao@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'lib/trace_readwrite.c')
0 files changed, 0 insertions, 0 deletions