]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.19-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 7 May 2019 12:50:36 +0000 (14:50 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 7 May 2019 12:50:36 +0000 (14:50 +0200)
added patches:
asoc-wm_adsp-check-for-buffer-in-trigger-stop.patch
mm-kmemleak.c-fix-unused-function-warning.patch

queue-4.19/asoc-wm_adsp-check-for-buffer-in-trigger-stop.patch [new file with mode: 0644]
queue-4.19/mm-kmemleak.c-fix-unused-function-warning.patch [new file with mode: 0644]
queue-4.19/series

diff --git a/queue-4.19/asoc-wm_adsp-check-for-buffer-in-trigger-stop.patch b/queue-4.19/asoc-wm_adsp-check-for-buffer-in-trigger-stop.patch
new file mode 100644 (file)
index 0000000..b9314a4
--- /dev/null
@@ -0,0 +1,35 @@
+From 43d147be5738a9ed6cfb25c285ac50d6dd5793be Mon Sep 17 00:00:00 2001
+From: Charles Keepax <ckeepax@opensource.cirrus.com>
+Date: Tue, 2 Apr 2019 13:49:14 +0100
+Subject: ASoC: wm_adsp: Check for buffer in trigger stop
+
+From: Charles Keepax <ckeepax@opensource.cirrus.com>
+
+commit 43d147be5738a9ed6cfb25c285ac50d6dd5793be upstream.
+
+Trigger stop can be called in situations where trigger start failed
+and as such it can't be assumed the buffer is already attached to
+the compressed stream or a NULL pointer may be dereferenced.
+
+Fixes: 639e5eb3c7d6 ("ASoC: wm_adsp: Correct handling of compressed streams that restart")
+Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
+Signed-off-by: Mark Brown <broonie@kernel.org>
+Cc: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@toshiba.co.jp>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/soc/codecs/wm_adsp.c |    3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/sound/soc/codecs/wm_adsp.c
++++ b/sound/soc/codecs/wm_adsp.c
+@@ -3452,7 +3452,8 @@ int wm_adsp_compr_trigger(struct snd_com
+               }
+               break;
+       case SNDRV_PCM_TRIGGER_STOP:
+-              wm_adsp_buffer_clear(compr->buf);
++              if (wm_adsp_compr_attached(compr))
++                      wm_adsp_buffer_clear(compr->buf);
+               break;
+       default:
+               ret = -EINVAL;
diff --git a/queue-4.19/mm-kmemleak.c-fix-unused-function-warning.patch b/queue-4.19/mm-kmemleak.c-fix-unused-function-warning.patch
new file mode 100644 (file)
index 0000000..021e31a
--- /dev/null
@@ -0,0 +1,49 @@
+From dce5b0bdeec61bdbee56121ceb1d014151d5cab1 Mon Sep 17 00:00:00 2001
+From: Arnd Bergmann <arnd@arndb.de>
+Date: Thu, 18 Apr 2019 17:50:48 -0700
+Subject: mm/kmemleak.c: fix unused-function warning
+
+From: Arnd Bergmann <arnd@arndb.de>
+
+commit dce5b0bdeec61bdbee56121ceb1d014151d5cab1 upstream.
+
+The only references outside of the #ifdef have been removed, so now we
+get a warning in non-SMP configurations:
+
+  mm/kmemleak.c:1404:13: error: unused function 'scan_large_block' [-Werror,-Wunused-function]
+
+Add a new #ifdef around it.
+
+Link: http://lkml.kernel.org/r/20190416123148.3502045-1-arnd@arndb.de
+Fixes: 298a32b13208 ("kmemleak: powerpc: skip scanning holes in the .bss section")
+Signed-off-by: Arnd Bergmann <arnd@arndb.de>
+Acked-by: Catalin Marinas <catalin.marinas@arm.com>
+Cc: Vincent Whitchurch <vincent.whitchurch@axis.com>
+Cc: Michael Ellerman <mpe@ellerman.id.au>
+Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+Cc: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@toshiba.co.jp>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ mm/kmemleak.c |    2 ++
+ 1 file changed, 2 insertions(+)
+
+--- a/mm/kmemleak.c
++++ b/mm/kmemleak.c
+@@ -1373,6 +1373,7 @@ static void scan_block(void *_start, voi
+ /*
+  * Scan a large memory block in MAX_SCAN_SIZE chunks to reduce the latency.
+  */
++#ifdef CONFIG_SMP
+ static void scan_large_block(void *start, void *end)
+ {
+       void *next;
+@@ -1384,6 +1385,7 @@ static void scan_large_block(void *start
+               cond_resched();
+       }
+ }
++#endif
+ /*
+  * Scan a memory block corresponding to a kmemleak_object. A condition is
index 1d423c6b668cfbec81e3aec50d797f76185d9453..56e2369a831c69b1a8e0666abb77eba7093d2a03 100644 (file)
@@ -97,3 +97,5 @@ x86-mm-fix-a-crash-with-kmemleak_scan.patch
 x86-mm-tlb-revert-x86-mm-align-tlb-invalidation-info.patch
 i2c-i2c-stm32f7-fix-sdadel-minimum-formula.patch
 media-v4l2-i2c-ov7670-fix-pll-bypass-register-values.patch
+asoc-wm_adsp-check-for-buffer-in-trigger-stop.patch
+mm-kmemleak.c-fix-unused-function-warning.patch