Browse Source

Merge branch 'for-3.0' into for-3.1

Mark Brown 14 years ago
parent
commit
bd4f2acb8d
1 changed files with 3 additions and 0 deletions
  1. 3 0
      sound/soc/soc-cache.c

+ 3 - 0
sound/soc/soc-cache.c

@@ -463,6 +463,9 @@ static bool snd_soc_set_cache_val(void *base, unsigned int idx,
 static unsigned int snd_soc_get_cache_val(const void *base, unsigned int idx,
 		unsigned int word_size)
 {
+	if (!base)
+		return -1;
+
 	switch (word_size) {
 	case 1: {
 		const u8 *cache = base;