From: Takashi Iwai <tiwai@suse.de>
To: <twischer@de.adit-jv.com>
Cc: <broonie@kernel.org>, <perex@perex.cz>, <tiwai@suse.com>,
alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org
Subject: Re: [ALSA patch] [PATCH] ALSA: pcm: Enable MMAP status and control for ARMv7 and ARMv8
Date: Wed, 17 Apr 2019 11:21:48 +0200 [thread overview]
Message-ID: <s5hlg093s2b.wl-tiwai@suse.de> (raw)
In-Reply-To: <1555490771-13242-1-git-send-email-twischer@de.adit-jv.com>
On Wed, 17 Apr 2019 10:46:11 +0200,
<twischer@de.adit-jv.com> wrote:
>
> From: Timo Wischer <twischer@de.adit-jv.com>
>
> Since ARMv7 hardware cache coherence is supported.
> "The SCU maintains coherency between the individual data caches in the
> Cortex-A5 MPCore processor using a variation of the MOESI protocol" [1].
>
> Therefore this patch enables the MMAP access to the status and control
> structures. This avoids HWSYYNC ioctl calls and therefore lowers the CPU
> usage.
>
> [1] http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.ddi0434c/
> BABJECBF.html
Interesting... I thought it would never work properly on ARM.
If it really works like that, I'd happily apply the change.
But I'd like to hear a confirmation from ARM people before merging
such an intensive change.
thanks,
Takashi
>
> Signed-off-by: Timo Wischer <twischer@de.adit-jv.com>
> ---
> sound/core/pcm_native.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/sound/core/pcm_native.c b/sound/core/pcm_native.c
> index 1d84529..b8019ef 100644
> --- a/sound/core/pcm_native.c
> +++ b/sound/core/pcm_native.c
> @@ -3225,7 +3225,8 @@ static __poll_t snd_pcm_poll(struct file *file, poll_table *wait)
> * Only on coherent architectures, we can mmap the status and the control records
> * for effcient data transfer. On others, we have to use HWSYNC ioctl...
> */
> -#if defined(CONFIG_X86) || defined(CONFIG_PPC) || defined(CONFIG_ALPHA)
> +#if defined(CONFIG_X86) || defined(CONFIG_PPC) || defined(CONFIG_ALPHA) || \
> + (defined(CONFIG_ARM) && defined(CONFIG_CPU_V7)) || defined(CONFIG_ARM64)
> /*
> * mmap status record
> */
> --
> 2.7.4
>
> _______________________________________________
> Patch mailing list
> Patch@alsa-project.org
> https://mailman.alsa-project.org/mailman/listinfo/patch
>
next prev parent reply other threads:[~2019-04-17 9:21 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-17 8:46 [PATCH] ALSA: pcm: Enable MMAP status and control for ARMv7 and ARMv8 twischer
2019-04-17 9:21 ` Takashi Iwai [this message]
2019-04-17 9:30 ` [ALSA patch] " Timo Wischer
2019-04-17 9:40 ` Takashi Iwai
2019-07-10 8:42 ` Timo Wischer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=s5hlg093s2b.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=perex@perex.cz \
--cc=tiwai@suse.com \
--cc=twischer@de.adit-jv.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox