2019-03-29 14:12:17 +08:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
2018-10-16 02:05:43 +08:00
|
|
|
From: Ramesh Babu <ramesh.babu@intel.com>
|
|
|
|
Date: Mon, 23 Nov 2015 03:22:40 +0530
|
2019-03-29 14:12:17 +08:00
|
|
|
Subject: [PATCH] ASoC: intel: skylake: mark ring buffer as non-cacheble
|
2018-10-16 02:05:43 +08:00
|
|
|
|
|
|
|
Change-Id: I8c08f3a91682654e5f1db95033b580258201da91
|
|
|
|
Signed-off-by: Ramesh Babu <ramesh.babu@intel.com>
|
|
|
|
Reviewed-on:
|
|
|
|
---
|
|
|
|
sound/soc/intel/skylake/skl-pcm.c | 10 +++++++++-
|
|
|
|
1 file changed, 9 insertions(+), 1 deletion(-)
|
|
|
|
|
|
|
|
diff --git a/sound/soc/intel/skylake/skl-pcm.c b/sound/soc/intel/skylake/skl-pcm.c
|
2020-05-05 09:02:46 +08:00
|
|
|
index 6b2c8c6e7..fcd9523d7 100644
|
2018-10-16 02:05:43 +08:00
|
|
|
--- a/sound/soc/intel/skylake/skl-pcm.c
|
|
|
|
+++ b/sound/soc/intel/skylake/skl-pcm.c
|
|
|
|
@@ -80,17 +80,25 @@ static int skl_substream_alloc_pages(struct hdac_bus *bus,
|
|
|
|
size_t size)
|
|
|
|
{
|
|
|
|
struct hdac_ext_stream *stream = get_hdac_ext_stream(substream);
|
|
|
|
+ int ret;
|
|
|
|
|
|
|
|
hdac_stream(stream)->bufsize = 0;
|
|
|
|
hdac_stream(stream)->period_bytes = 0;
|
|
|
|
hdac_stream(stream)->format_val = 0;
|
|
|
|
|
|
|
|
- return snd_pcm_lib_malloc_pages(substream, size);
|
|
|
|
+ ret = snd_pcm_lib_malloc_pages(substream, size);
|
|
|
|
+ if (ret < 0)
|
|
|
|
+ return ret;
|
|
|
|
+ ebus->bus.io_ops->mark_pages_uc(snd_pcm_get_dma_buf(substream), true);
|
|
|
|
+
|
|
|
|
+ return ret;
|
|
|
|
}
|
|
|
|
|
|
|
|
static int skl_substream_free_pages(struct hdac_bus *bus,
|
|
|
|
struct snd_pcm_substream *substream)
|
|
|
|
{
|
|
|
|
+ bus->io_ops->mark_pages_uc(snd_pcm_get_dma_buf(substream), false);
|
|
|
|
+
|
|
|
|
return snd_pcm_lib_free_pages(substream);
|
|
|
|
}
|
|
|
|
|
|
|
|
--
|
2019-04-08 18:08:36 +08:00
|
|
|
https://clearlinux.org
|
2018-10-16 02:05:43 +08:00
|
|
|
|