aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sound/soc/soc-cache.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sound/soc/soc-cache.c b/sound/soc/soc-cache.c
index 06b7b81a1601..c005ceb70c9d 100644
--- a/sound/soc/soc-cache.c
+++ b/sound/soc/soc-cache.c
@@ -466,6 +466,9 @@ static bool snd_soc_set_cache_val(void *base, unsigned int idx,
466static unsigned int snd_soc_get_cache_val(const void *base, unsigned int idx, 466static unsigned int snd_soc_get_cache_val(const void *base, unsigned int idx,
467 unsigned int word_size) 467 unsigned int word_size)
468{ 468{
469 if (!base)
470 return -1;
471
469 switch (word_size) { 472 switch (word_size) {
470 case 1: { 473 case 1: {
471 const u8 *cache = base; 474 const u8 *cache = base;