ASoC: sma1307: Add NULL check in sma1307_setting_loaded()

All varibale allocated by kzalloc and devm_kzalloc could be NULL.
Multiple pointer checks and their cleanup are added.

This issue is found by our static analysis tool

Signed-off-by: Chenyuan Yang <chenyuan0y@gmail.com>
Link: https://patch.msgid.link/20250311015714.1333857-1-chenyuan0y@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Chenyuan Yang 2025-03-10 20:57:14 -05:00 • committed by Mark Brown
commit 0ec6bd1670
No known key found for this signature in database
GPG key ID: 24D68B725D5487D0