Received: by 2002:a25:31c3:0:0:0:0:0 with SMTP id x186csp1134657ybx; Tue, 5 Nov 2019 10:56:39 -0800 (PST) X-Google-Smtp-Source: APXvYqzl7mIhIFwzVVK1Ld7uSRyh/CJJp1GfnY95xdSlI57wARFr+SovzgAC/HF6MNDLKJI5ibCj X-Received: by 2002:aa7:d95a:: with SMTP id l26mr37390210eds.12.1572980199589; Tue, 05 Nov 2019 10:56:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1572980199; cv=none; d=google.com; s=arc-20160816; b=c7vBnVvLNyPbxA0NNMcdh5QLvn3X28ag9rWOofCA9C4H18g+VD6bPey82i5QmyHl/f 9rd6uYwfCUTa981n2DjKARX+T0/1VrACsi5pCojcnBNTwxG7z+GUCQzwQF0hzH92rsOf doYP2Pb4W5baTU+GHsNwvwhuMu1YIV0nCEmfgFDV1BidVL5vsh1lNtNDzrjdMV8TkOKK rHlYotA5X1tmDEQmFR1Oe7TVxIJPAVrmyI2TcPWBJdZg4zWRVtr54GCNAM8BnTmbdkkS VtN7Ht0lKoRw2Dy2i2q70lvs9GOdNM1d8TCOlS7jPp87yuiB6BRRfXg9O+fy4O6uLrAK JsoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:message-id:in-reply-to:subject:cc:to :from:dkim-signature; bh=dcXKl/0UqJ+dCjeE5w/EDI2rZhDXMA0VO2ph2g/2lKo=; b=jOFHLWARiwj6K87vxjLbk6w1tB0SOW6XyCFQw/cXavnhPNCeB6EGf/SxcDib8zq2KP sLVdf19kuRaeK124lPzp0Z//U5BPlZ/aKEIeNvD7VeEtysJ8YCw+ugD+igEWtG6szlF+ EuCR2eeiYCg0+Ypken46gwJPm6rjvN1iLkkqgIU4lR3UohyUpmquDMNiCCq3Cf/jupzo aohkzHLIxYqaTzY11Yc6QtmCepq6LdgRZNXnn5NNFvDnYUrLc6sE53plF1GwFUweEsU3 hXy9E0p59S8Pt48yJhOI6KJ5ZVo/uP6TDLvEaMbwVY9nv51714riKpKHgiX0FLqhOOB0 dZkA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=YkXoDtn0; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a3si10575355edb.134.2019.11.05.10.56.15; Tue, 05 Nov 2019 10:56:39 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=YkXoDtn0; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390802AbfKESz2 (ORCPT + 99 others); Tue, 5 Nov 2019 13:55:28 -0500 Received: from heliosphere.sirena.org.uk ([172.104.155.198]:36482 "EHLO heliosphere.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2390651AbfKESz2 (ORCPT ); Tue, 5 Nov 2019 13:55:28 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sirena.org.uk; s=20170815-heliosphere; h=Date:Message-Id:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References: List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner: List-Archive; bh=dcXKl/0UqJ+dCjeE5w/EDI2rZhDXMA0VO2ph2g/2lKo=; b=YkXoDtn0mNp3 jFthqMO+OvdjD02O8vSt6QOaYPW6A2o/HfrkS1KnXTTHqzmAJmr6M16eewkN96qkeu3oNTOX3O1ed hqBjH5+GIdql2zgffYYMjNS78o0IXbse7cvkL9co0/585HrS3ftkHrcJIsy1nelXT1wmAcZh3rnxx zf7Xw=; Received: from cpc102320-sgyl38-2-0-cust46.18-2.cable.virginm.net ([82.37.168.47] helo=ypsilon.sirena.org.uk) by heliosphere.sirena.org.uk with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1iS3z0-0007Pi-Ja; Tue, 05 Nov 2019 18:55:14 +0000 Received: by ypsilon.sirena.org.uk (Postfix, from userid 1000) id 91F312743284; Tue, 5 Nov 2019 18:55:12 +0000 (GMT) From: Mark Brown To: Olivier Moysan Cc: alexandre.torgue@st.com, alsa-devel@alsa-project.org, arnaud.pouliquen@st.com, benjamin.gaignard@st.com, broonie@kernel.org, lgirdwood@gmail.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, Mark Brown , mcoquelin.stm32@gmail.com, olivier.moysan@st.com, perex@perex.cz, tiwai@suse.com Subject: Applied "ASoC: stm32: sai: add restriction on mmap support" to the asoc tree In-Reply-To: <20191104133654.28750-1-olivier.moysan@st.com> X-Patchwork-Hint: ignore Message-Id: <20191105185512.91F312743284@ypsilon.sirena.org.uk> Date: Tue, 5 Nov 2019 18:55:12 +0000 (GMT) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The patch ASoC: stm32: sai: add restriction on mmap support has been applied to the asoc tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.4 All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark From eaf072e512d54c95b0977eda06cbca3151ace1e5 Mon Sep 17 00:00:00 2001 From: Olivier Moysan Date: Mon, 4 Nov 2019 14:36:54 +0100 Subject: [PATCH] ASoC: stm32: sai: add restriction on mmap support Do not support mmap in S/PDIF mode. In S/PDIF mode the buffer has to be copied, to allow the channel status bits insertion. Signed-off-by: Olivier Moysan Link: https://lore.kernel.org/r/20191104133654.28750-1-olivier.moysan@st.com Signed-off-by: Mark Brown --- sound/soc/stm/stm32_sai_sub.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/sound/soc/stm/stm32_sai_sub.c b/sound/soc/stm/stm32_sai_sub.c index a4060813bc74..48e629ac2d88 100644 --- a/sound/soc/stm/stm32_sai_sub.c +++ b/sound/soc/stm/stm32_sai_sub.c @@ -1218,6 +1218,16 @@ static int stm32_sai_pcm_process_spdif(struct snd_pcm_substream *substream, return 0; } +/* No support of mmap in S/PDIF mode */ +static const struct snd_pcm_hardware stm32_sai_pcm_hw_spdif = { + .info = SNDRV_PCM_INFO_INTERLEAVED, + .buffer_bytes_max = 8 * PAGE_SIZE, + .period_bytes_min = 1024, + .period_bytes_max = PAGE_SIZE, + .periods_min = 2, + .periods_max = 8, +}; + static const struct snd_pcm_hardware stm32_sai_pcm_hw = { .info = SNDRV_PCM_INFO_INTERLEAVED | SNDRV_PCM_INFO_MMAP, .buffer_bytes_max = 8 * PAGE_SIZE, @@ -1270,7 +1280,7 @@ static const struct snd_dmaengine_pcm_config stm32_sai_pcm_config = { }; static const struct snd_dmaengine_pcm_config stm32_sai_pcm_config_spdif = { - .pcm_hardware = &stm32_sai_pcm_hw, + .pcm_hardware = &stm32_sai_pcm_hw_spdif, .prepare_slave_config = snd_dmaengine_pcm_prepare_slave_config, .process = stm32_sai_pcm_process_spdif, }; -- 2.20.1