Received: by 2002:a05:7208:9594:b0:7e:5202:c8b4 with SMTP id gs20csp1153735rbb; Sun, 25 Feb 2024 23:37:24 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVOp2l1zDrUCnncvBTFiUWJUFARsx6B0brtIGPYiUm9iC24mwHX+jS3k9t3QyIv5XXKNEv5GsGbcbIjCGGWpcS4iMfESQnvHtomKwa7nQ== X-Google-Smtp-Source: AGHT+IHzZ8gc+EMXBxgOqh9SgXHHPot7ijYkWxHcwrFcjNIJPT9/wu5Hh2hcndDBaYXDNF/r3GPB X-Received: by 2002:a0c:f58c:0:b0:68f:ad8d:7686 with SMTP id k12-20020a0cf58c000000b0068fad8d7686mr8354043qvm.49.1708933043984; Sun, 25 Feb 2024 23:37:23 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708933043; cv=pass; d=google.com; s=arc-20160816; b=ZFx22yKTULXYaUc42V5WcYWgPCQHrGRfkYRoFCW48wJZ9mQ9S+9tlMMsgZ4ISkpNN3 NXW7I/tKySygFpqlfJBocG5GH5D0xUze9hmSTUJ+444Ygx4kwQIZI+Jy+dvpEcB6775F bF25wQr+nIeGgf1U3tCNm3M124V0aFpkyU8+RDryGVHagxh1kcNQzGT9KXlxCJzvg22s uqirDacuyObTFaeXCq/LdUddxoaDQ7QJUlU+0W0tGTDNggCHtYv0HK9DSCzjazg1hBue qNRtcjwNZLrOSIgm1MVsahOJH1YlFjPNxIw1wP36ejamRvT7khIvAl81BNv1iNPXkwST t+kQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=reply-to:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:subject:date:from:dkim-signature; bh=MzpkELDWnpf78V5M33YY0zUWygTa7I0I/bAEu3zxxzU=; fh=siHl7C4L016iLMpuEy874cYMVnvZucC5wybmLpB6k5k=; b=i4JBg4ymy8z87STHu8nVccf8RvLpw6j5AHfJfuouekamxXirPbxeVqw+qEuClMu/yr rWpIhg+nnDWtt2T3i6+S1OawBuDXFN5v2fJuIpQdv6QMJhrnFAmJQ91KuaFUzp8khHW6 ZyY1Sg5VHnW32YPPnWsWn0XBj5jt2YdTEdsR94gQQ9LxR9jHIo4QgdIw3Qh6Dt33E0Sj brFLik3R7Tq69tu+u1hfEmDXiv/041N+tJIDkDsAA2JuZHLhH4GkX88sQXgzBunev2EC LHWsC6JDPYVSeqV2IoX1DXXcChK9zlSxLSU+ry0QV/rv+qbQ7rZ/Qyv1edGYTwEtWDYL FdrA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=s38xqMW9; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-80663-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-80663-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id jz1-20020a0562140e6100b0068f4d891893si4448443qvb.253.2024.02.25.23.37.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 25 Feb 2024 23:37:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-80663-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=s38xqMW9; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-80663-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-80663-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id A6D7F1C20430 for ; Mon, 26 Feb 2024 07:37:23 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 287F853397; Mon, 26 Feb 2024 07:31:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="s38xqMW9" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C50F81CFB5; Mon, 26 Feb 2024 07:31:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708932683; cv=none; b=OX8xOu7zPRBecXeT4M32HkSbK5rlZoncfJQjFhdy530csCcjCyrYDlTXgFJFq0cOqhSYFuNDKmiFyewJwO+CVPVfmlyHx5Ju7MXbKZssDHdT9c0yuV+Q0K4ivek9ISFbNfYgioqu+qdAHQQxWAlJK/LOGY66VlwNN5ZbmcakC6w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708932683; c=relaxed/simple; bh=8w6Gxnkm6FXrOeCoZ4fa4npbHPlvL7OfG6RGXGY+akc=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=bMBeL2mDygr2CdOVVW4JqgvoIwVp2zgYFI/+PSxx4EKn7Gkc6Vjngl7cf0Pps040LoUNnR2W8LQeciBqRaayt6Aj4Cd7pH+ewglu/32S7q1L10LFzBl+D0LttfLHltA/ql/3wUQ62fLHVqJmi6Vk+ScnzLQkD8/GOYJ7at6UTvM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=s38xqMW9; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPS id 7BC69C4167E; Mon, 26 Feb 2024 07:31:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1708932683; bh=8w6Gxnkm6FXrOeCoZ4fa4npbHPlvL7OfG6RGXGY+akc=; h=From:Date:Subject:References:In-Reply-To:To:Cc:Reply-To:From; b=s38xqMW9T8UA/2sfHQb902SuaVIivdMATpjSPjfahKsbTCfHTkoWfSvIBKy+yWHd5 RHeEbcU7itsmLFeu29nnkusqzjsdqaR2z4ujFoYtYdZhuxw7JiBK6cU2cVTqUwI0CP 5C1vdZMZDXZUEatZzmuujFSPG1pL0CNzxJR0xKedoXr+Q6oiEKeArA+RFj8ZQ17dgF UB85K16i2CW2PeAtRKXRWGo9f00FVk24w5+2K0lMFbPMKH4tQ+Jzog7CbfxHYOv2uj ksB2CZFIaxecuv7tWw8B4BlEuBgMae3Y82799ptHBa2ZmjAEG4lsz/MC2R/aiqSeqf NSclqQLkx6wag== Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6BE86C5478C; Mon, 26 Feb 2024 07:31:23 +0000 (UTC) From: Nikita Shubin via B4 Relay Date: Mon, 26 Feb 2024 10:30:24 +0300 Subject: [PATCH v8 28/38] ASoC: ep93xx: Drop legacy DMA support Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240226-ep93xx-v8-28-3136dca7238f@maquefel.me> References: <20240226-ep93xx-v8-0-3136dca7238f@maquefel.me> In-Reply-To: <20240226-ep93xx-v8-0-3136dca7238f@maquefel.me> To: Liam Girdwood , Mark Brown , Jaroslav Kysela , Takashi Iwai , Alexander Sverdlin , Kuninori Morimoto , Nicolas Ferre , Nikita Shubin , =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= Cc: linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org, Arnd Bergmann X-Mailer: b4 0.13-dev-e3e53 X-Developer-Signature: v=1; a=ed25519-sha256; t=1708932678; l=3001; i=nikita.shubin@maquefel.me; s=20230718; h=from:subject:message-id; bh=Edo7deD4TfxQT1IZ681PPthd594zbg9RMygPGh53NHw=; =?utf-8?q?b=3DbQ42Rl+TVVYV?= =?utf-8?q?umofUYeoOBTAUvLiUdiFPvZTIRvVtkpwB72O0d1pBRm3rzYu+HygavDC2aDrTlbG?= Rb4z9sHADsIBQfkZqVkleFt9hQgelhLPMP9r0QY78qzSdOKZnuY4 X-Developer-Key: i=nikita.shubin@maquefel.me; a=ed25519; pk=vqf5YIUJ7BJv3EJFaNNxWZgGuMgDH6rwufTLflwU9ac= X-Endpoint-Received: by B4 Relay for nikita.shubin@maquefel.me/20230718 with auth_id=65 X-Original-From: Nikita Shubin Reply-To: From: Alexander Sverdlin And rely on OF DMA. Signed-off-by: Alexander Sverdlin Signed-off-by: Nikita Shubin --- sound/soc/cirrus/ep93xx-i2s.c | 19 ------------------- sound/soc/cirrus/ep93xx-pcm.c | 19 +------------------ 2 files changed, 1 insertion(+), 37 deletions(-) diff --git a/sound/soc/cirrus/ep93xx-i2s.c b/sound/soc/cirrus/ep93xx-i2s.c index 522de4b80293..9e83cdf8a943 100644 --- a/sound/soc/cirrus/ep93xx-i2s.c +++ b/sound/soc/cirrus/ep93xx-i2s.c @@ -24,7 +24,6 @@ #include #include -#include #include #include "ep93xx-pcm.h" @@ -80,19 +79,6 @@ struct ep93xx_i2s_info { struct snd_dmaengine_dai_dma_data dma_params_tx; }; -static struct ep93xx_dma_data ep93xx_i2s_dma_data[] = { - [SNDRV_PCM_STREAM_PLAYBACK] = { - .name = "i2s-pcm-out", - .port = EP93XX_DMA_I2S1, - .direction = DMA_MEM_TO_DEV, - }, - [SNDRV_PCM_STREAM_CAPTURE] = { - .name = "i2s-pcm-in", - .port = EP93XX_DMA_I2S1, - .direction = DMA_DEV_TO_MEM, - }, -}; - static inline void ep93xx_i2s_write_reg(struct ep93xx_i2s_info *info, unsigned reg, unsigned val) { @@ -198,11 +184,6 @@ static int ep93xx_i2s_dai_probe(struct snd_soc_dai *dai) { struct ep93xx_i2s_info *info = snd_soc_dai_get_drvdata(dai); - info->dma_params_tx.filter_data = - &ep93xx_i2s_dma_data[SNDRV_PCM_STREAM_PLAYBACK]; - info->dma_params_rx.filter_data = - &ep93xx_i2s_dma_data[SNDRV_PCM_STREAM_CAPTURE]; - snd_soc_dai_init_dma_data(dai, &info->dma_params_tx, &info->dma_params_rx); diff --git a/sound/soc/cirrus/ep93xx-pcm.c b/sound/soc/cirrus/ep93xx-pcm.c index fa72acd8d334..5ecb4671cbba 100644 --- a/sound/soc/cirrus/ep93xx-pcm.c +++ b/sound/soc/cirrus/ep93xx-pcm.c @@ -18,8 +18,6 @@ #include #include -#include - #include "ep93xx-pcm.h" static const struct snd_pcm_hardware ep93xx_pcm_hardware = { @@ -35,30 +33,15 @@ static const struct snd_pcm_hardware ep93xx_pcm_hardware = { .fifo_size = 32, }; -static bool ep93xx_pcm_dma_filter(struct dma_chan *chan, void *filter_param) -{ - struct ep93xx_dma_data *data = filter_param; - - if (data->direction == ep93xx_dma_chan_direction(chan)) { - chan->private = data; - return true; - } - - return false; -} - static const struct snd_dmaengine_pcm_config ep93xx_dmaengine_pcm_config = { .pcm_hardware = &ep93xx_pcm_hardware, - .compat_filter_fn = ep93xx_pcm_dma_filter, .prealloc_buffer_size = 131072, }; int devm_ep93xx_pcm_platform_register(struct device *dev) { return devm_snd_dmaengine_pcm_register(dev, - &ep93xx_dmaengine_pcm_config, - SND_DMAENGINE_PCM_FLAG_NO_DT | - SND_DMAENGINE_PCM_FLAG_COMPAT); + &ep93xx_dmaengine_pcm_config, 0); } EXPORT_SYMBOL_GPL(devm_ep93xx_pcm_platform_register); -- 2.41.0