Received: by 2002:ab2:1689:0:b0:1f7:5705:b850 with SMTP id d9csp2056761lqa; Tue, 30 Apr 2024 07:13:17 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWwfTo+6cDJtrzEd1zRWb3ctJH+FqEpuenvBMvSLP5C9HBYa3TlprEQDnZ+oLkiM5b+YxOc8qDm1EUqxiHOmtskIicAyfXXdg33YtLTkQ== X-Google-Smtp-Source: AGHT+IFIq+yVW5vPHjeE9G5B6Ys4VrAeCJrPIf0hVDbX8hUIm6XJWHQF33aTSafiOyGrN2YMCSAe X-Received: by 2002:a05:6808:148c:b0:3c7:148d:660b with SMTP id e12-20020a056808148c00b003c7148d660bmr18178246oiw.59.1714486240460; Tue, 30 Apr 2024 07:10:40 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714486240; cv=pass; d=google.com; s=arc-20160816; b=09dnKCZI+F9asUN9vpnv0aP9CFYrz3lKrtSPuZ3bCT3l8lrujwku2ul4/ivqQSkWQY /v1lRtPBhMsDxS2idSF0y+OY0EYP4oJtfvqS5JqB2AFCu5aqmV6wCOIqwc6zyK0XyDJG 5NEnFGlTRBbVHZw8mJcsF9CHxfjzXVVwM37E6BebWyHFMjfKV+XlT8hfvR26EKvm1j96 yGJdWBpgyZeAKNaV9Q5MJeRi4e0hJX4ebBqJBZHvnohzaDZozz78IIyZhCOQPzy3MpFs PUdE7TPLD++ZCWxg77ASQq+2hSmpEOw+sfG7+3SoJr3GStNSSy0jEgYdEmfSnJJC095F HbCw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=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=sVmB3IwNsO++LEmxsGA1Of52OGeiLTZOoIEqlaO4Y6U=; fh=ugEVnxnsPYCSzYl5a3MMCJVyyulJGC/I95/YeAiVGRg=; b=wQc7fvAkeUtTf9CIghh85AYbFQmlduxiMtO3j4YwizhDd71E0ubbeW0otRL3FUTcAu ODsPi35QDJm2WfpNMtlNJ1TmxLJvgmHjLysEEqVWIdg8qf47vW0nsDo1T1+BsbLG65nv 3KD3GLQ8kHctrKYhEA6fjgJMed2OvZJe9By24TtZdmbHkO1vIja78hdW9NDTE+rhfZt5 IdBU4GgXnOQi3KlX6XVFZZxGxrfAwkGyFpW8u6NYyA7Sw//M8YVplSO7Zb4BJpLkSAkg 6TyTFXjnmcWQx9fs6ue8P9SxjEX20aiL5SUS8q4rDFGC1iNYZQmVsBCBi/cCf8XxjNON aV6A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=JXuJ+FY0; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-164072-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-164072-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id t5-20020ac5c965000000b004df071cab27si147555vkm.299.2024.04.30.07.10.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Apr 2024 07:10:40 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-164072-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=JXuJ+FY0; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-164072-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-164072-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.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 07DB21C22906 for ; Tue, 30 Apr 2024 14:10:40 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6EDC91BED99; Tue, 30 Apr 2024 14:02:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="JXuJ+FY0" Received: from mail-ej1-f46.google.com (mail-ej1-f46.google.com [209.85.218.46]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B61821BED60 for ; Tue, 30 Apr 2024 14:02:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.46 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714485770; cv=none; b=KUWMSRUmfolfQwRT9Dla2HS4zRWJoAd8xfOsEkooGWnpe3jLeW80eRB2A0plmO86SBgEffFfa1cs2YPnFwovaDqIq5csF9ZikCN25EwCdFKEBLhLUYNFoSc9Pr+TCAnqhfiUdh7UiBUya6dpyUSjdcp/a8vMH39D2AOj99u3Cfw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714485770; c=relaxed/simple; bh=eDseprbctVXAhiZOvRsQsRjQ1srjlolDCUwu7Poiuqc=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=qu3yOzliOEsrkqzXUqTdJNxZtjlZFSjStCwjoQIz9fIb5I+qEAvhrWNPBrLfu9dOhnibmXrKRKRrMGbEqGpSqL+C8xTHUIkxsnObEsRrmwtkM3YxzhJQaK0D82r7jCACFMvL8sHg9ebwis87pIULsAoFzcdpMv6goKQnwS7WuPU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=JXuJ+FY0; arc=none smtp.client-ip=209.85.218.46 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-ej1-f46.google.com with SMTP id a640c23a62f3a-a58872c07d8so1172672566b.0 for ; Tue, 30 Apr 2024 07:02:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1714485767; x=1715090567; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=sVmB3IwNsO++LEmxsGA1Of52OGeiLTZOoIEqlaO4Y6U=; b=JXuJ+FY0c0lAPiN6GB2Bftfx2yBNQjdDyx2Vqhmu6/+risPyomjPYAhmOZJaa+3BXb iinwmCmGuEc4H/bqmw8lVdKGp2ePsAiQpN0iwDpHEygvh6TNvCvENONKSpDhGAgIxNrY wFTQ65p/NHJmHOQXidyMw1wib/2MSYOe0K/5WdnQgGcbhYhNbA3tbTi89PG96qo3th6j rlGFEpsqsMPDx0M/hxv9VxJ0eEKwE5yyxTuGJ6MTRqnPqKPkLN+b7H927IOXsTIGCJDT SfOjkWLYFZ03yy5aQRkIzYZa70STynBdeopSugN5jTUjr1FWxt86c3Oxxe6jvSRwHZTd p9VQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714485767; x=1715090567; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=sVmB3IwNsO++LEmxsGA1Of52OGeiLTZOoIEqlaO4Y6U=; b=wvazS6sj6UydD7Bs+9lq4qC8bhXYKxny63uZo528vipgQXxuAfXpVX/vREpneODZIT Jg4wSM/mjG2zVD0bCuc+GNFWQEUMbjjCvULy2VCtV7iHrz8s4PH7r+00C7+UMXZ/I37E ansapMorFI4idjHgMuGiCN2DPPRCIs+VkLeBKKZfIFI6j1evK7z9Yhprx68rgX5HPom8 /6QUvqDZE4YVP1ONN5Wz2wK0QLvbyjjOKrpMstC6jdiCOD0Ms+hTTQSofTjFZM4vWu11 fAQRaWCvxqBoEQU6R59Wk3R3cBgYVo7amzD+q4DIf2SiWtNPwWVD1SmROExLjGBQ9B43 XI0A== X-Forwarded-Encrypted: i=1; AJvYcCVZ3H9zQnEZa/DShIq7iFU+OD0End3nQ/DuQYD3nrCJeX8+8JkY9fgLrhTMFbyFUxvw75WFpm9pYBM83J68d3MHNhmcS0ydw6DgmIvZ X-Gm-Message-State: AOJu0Yxh/A/Ifgu0ofubM54pIHtHHFhGOGOTymXT5fgH22Wc3W33GKzJ MrLGX15G0BuoC0X3PpW8up9NISKRgzUaszMGcWsL+9PgOk8NbbYBknWI37AtZh4= X-Received: by 2002:a17:906:3ac3:b0:a58:ebdd:8aa4 with SMTP id z3-20020a1709063ac300b00a58ebdd8aa4mr2360562ejd.20.1714485766998; Tue, 30 Apr 2024 07:02:46 -0700 (PDT) Received: from [127.0.1.1] ([178.197.223.16]) by smtp.gmail.com with ESMTPSA id pv27-20020a170907209b00b00a5940af3f67sm31434ejb.16.2024.04.30.07.02.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Apr 2024 07:02:46 -0700 (PDT) From: Krzysztof Kozlowski Date: Tue, 30 Apr 2024 16:02:13 +0200 Subject: [PATCH 04/13] ASoC: arm: Use snd_soc_substream_to_rtd() for accessing private_data 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: <20240430-asoc-snd-substream-clean-v1-4-6f8a8902b479@linaro.org> References: <20240430-asoc-snd-substream-clean-v1-0-6f8a8902b479@linaro.org> In-Reply-To: <20240430-asoc-snd-substream-clean-v1-0-6f8a8902b479@linaro.org> To: Srinivas Kandagatla , Banajit Goswami , Liam Girdwood , Mark Brown , Jaroslav Kysela , Takashi Iwai , Thierry Reding , Jonathan Hunter , Peter Ujfalusi , Jarkko Nikula , Daniel Mack , Haojian Zhuang , Robert Jarzmik , Shengjiu Wang , Xiubo Li , Fabio Estevam , Nicolin Chen , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Matthias Brugger , AngeloGioacchino Del Regno , Jerome Brunet , Neil Armstrong , Kevin Hilman , Martin Blumenstingl , Sylwester Nawrocki , Ban Tao , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland Cc: alsa-devel@alsa-project.org, linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linuxppc-dev@lists.ozlabs.org, imx@lists.linux.dev, linux-mediatek@lists.infradead.org, linux-amlogic@lists.infradead.org, linux-sunxi@lists.linux.dev, Krzysztof Kozlowski X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1205; i=krzysztof.kozlowski@linaro.org; h=from:subject:message-id; bh=eDseprbctVXAhiZOvRsQsRjQ1srjlolDCUwu7Poiuqc=; b=owEBbQKS/ZANAwAKAcE3ZuaGi4PXAcsmYgBmMPnwqTKqjOWhyghuqcWCQALMCLVh7T8zMCEGN dvM+Z0GdNKJAjMEAAEKAB0WIQTd0mIoPREbIztuuKjBN2bmhouD1wUCZjD58AAKCRDBN2bmhouD 18RiD/4qLIFwqpuprQ1tMuUxq4zKnCWe3121KK341e3C6K9aJyN/BTLnFTKGCeHCS8O34sFL66W T7sO0tVkpzvEVFOfhdAxTxVSNxk8b8r6nlylo9rzqkM9QzU1SQsGJxog0QKojxAO0I6sntjpOI1 C4eLl6KKsV1j1hvxU76kJP6e32eMeIdiZaAxMmQsQSK0v013+TK6DZ0Pzoka7GW21s3JFCovROF vXxmHvtZZeMHmbCCg5y/XZBWunSMfsNrjjgO+mIu7XV7gkK7P9MQYjLZJqqQZ+vhoD2Qg9UAnk7 OQE9DLavtk9A5wwayHHudVq/E4K3OsGqYV+1R5o5G1+IXBsr5pk5VcYEwd60z1VKxXXSO/b83Yc ENbgYWPE1yLUGcTgo4uG5za0uVWxDFi/b7wDRbmmROHuH09+9ryGv2cvKPGHQDn8f6u5L/cH8NS Ks+CcsLhi9wVjDnpMDTWNA/8OLpqgOgk1oqEI3Ef0cIjYKbQDoqPj8qg/30LXXJWsi3ixd/UGXX LNNqCHmIDRExk6Qjid/ky+fQP2yP3ITflnWYCAlkkGB6jsfhk/qkiIbv4uytjIVSSs+x9OJUdPk 73ZmPvgfk/AnUFwJpDnK2XdUlBKSk6Z3H5g0na7JWMYATpXKrxMAJjcyW1bMqbdfGqkv8gNWzrz mSfEosfDuUmcoLg== X-Developer-Key: i=krzysztof.kozlowski@linaro.org; a=openpgp; fpr=9BD07E0E0C51F8D59677B7541B93437D3B41629B Do not open-code snd_soc_substream_to_rtd(). Signed-off-by: Krzysztof Kozlowski --- sound/arm/pxa2xx-pcm-lib.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/arm/pxa2xx-pcm-lib.c b/sound/arm/pxa2xx-pcm-lib.c index 51d2ff80df16..571e9d909cdf 100644 --- a/sound/arm/pxa2xx-pcm-lib.c +++ b/sound/arm/pxa2xx-pcm-lib.c @@ -33,7 +33,7 @@ int pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, struct snd_pcm_hw_params *params) { struct dma_chan *chan = snd_dmaengine_pcm_get_chan(substream); - struct snd_soc_pcm_runtime *rtd = substream->private_data; + struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream); struct snd_dmaengine_dai_dma_data *dma_params; struct dma_slave_config config; int ret; @@ -79,7 +79,7 @@ EXPORT_SYMBOL(pxa2xx_pcm_prepare); int pxa2xx_pcm_open(struct snd_pcm_substream *substream) { - struct snd_soc_pcm_runtime *rtd = substream->private_data; + struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream); struct snd_pcm_runtime *runtime = substream->runtime; struct snd_dmaengine_dai_dma_data *dma_params; int ret; -- 2.43.0