From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wr1-f41.google.com (mail-wr1-f41.google.com [209.85.221.41]) (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 7E2DC2F659F for ; Mon, 26 Jan 2026 12:39:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.41 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769431150; cv=none; b=ls5TLorRQi2H2+qrcOGtbpUR+ZAOWB1v5PZijAg7ZfhdGbgIWOSgWyBFuatMvZSxtADGvszqqWuDRrKAtReLvu4N+4uqdYXaviSK845n9mjM9ac4iUij5S3VNPShE/o+h6cR2KDseic05alS5+NdAvsVRguGevcVgR8rugpP+eA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769431150; c=relaxed/simple; bh=cyOIiW4pRspU7Ky5fnCdxX16wwU+4Lx/7snzOfV0wDo=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=uajh5jPaG64K/7BvGSAs4O2qEydY/SqDaYDlHX93XvnAgVuACpjQ7ZIooFp64uuesqDnEX9yBKXrLI3iSwMsLcQgoqAJB+ROJ/IThQfS+dX7Eytr+Dq3cUPOR6gFQr685StY3rkq8TPxcFYFnv5wq8LO11nbUoobvpmnY+5SSUg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=tuxon.dev; spf=pass smtp.mailfrom=tuxon.dev; dkim=pass (2048-bit key) header.d=tuxon.dev header.i=@tuxon.dev header.b=qdP9RXdJ; arc=none smtp.client-ip=209.85.221.41 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=tuxon.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=tuxon.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=tuxon.dev header.i=@tuxon.dev header.b="qdP9RXdJ" Received: by mail-wr1-f41.google.com with SMTP id ffacd0b85a97d-43590777e22so2650718f8f.3 for ; Mon, 26 Jan 2026 04:39:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tuxon.dev; s=google; t=1769431146; x=1770035946; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=h9LPVZSPw9JF8KAbPLK9s3M1ut6MOkLUhCUq7qppfgc=; b=qdP9RXdJjCEm2AMH8YRaUTrD0PF+7Sx7JsYV8tPjWRD7tut1noRqfV/WzSbU7t85Sb TY0See//8mL7TJW+p69ixwPpPLBZ4ysHt+AY4xFyRgbvBoSFnMjEqxP3Bb0PYIOf7E+K BL4elODtMaM76JXafll7dlxDz/fyXFzrkFY+QylFw6eQyYFwRLMHay+82GvN7JA/eZMI gImrvZr/lwKqM2fKh/CyQOiN6p8+lP7vn2+Yw9HfODsevfEEUTMsH1ZnfdXhxaO6Aaph 3dwHQD7fSc6UkSpeS1LP/ZdPrzHj/4emzXKPfIETSijGjkkv+m9HQ7NEWfLRRiVy83cj j0rg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1769431146; x=1770035946; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=h9LPVZSPw9JF8KAbPLK9s3M1ut6MOkLUhCUq7qppfgc=; b=rABxLgM6O5CqHCKuZFOig3xB2hcpwKQuO4qFmVECt8vRPQmfuRO/Ok3y147FVC79fG T9WTFfNkBm7a2KVjaTMuGfIl3xoJYfOMdcgSqobHrNXfSRCoyT5DjnU1pzzpyeKPGldc uk0KvLokXHZxfQkF35KYaZSG67OfElq1UlFusdVcA50zCUGc6jaoW4vXh5lfcKkOF23H myC+A9elTVzE4cObhtqkXmKASO6YyHr8KkJW+kDpbbiSvDZA4sayVTC5hcIzmtqIqSVP WDd2qwoBZGtii59LSPhU4VkNMrAxzR8UzPquSznF9s9pTgk8r1wm0zpqvDu2uahJjVaW UxNw== X-Forwarded-Encrypted: i=1; AJvYcCWyO59zfX/E/dweFt53Ft3Wu/WB9hRm2A7Q7Dn6jwFHxeK9aUAjJhngHHSvVVmkhRKJZgfnQ7LstgnNNAU=@vger.kernel.org X-Gm-Message-State: AOJu0YxDstB1ub0+b896Hz4jVOKjqZ0Li5ElpSLmgNL4evga+esv2U+a y1HUlVk/rLCVgy7qJ34oKtVBmXfaXXajHiLakKD9lc42gLObMcS5ooBQo2LRopxrztY= X-Gm-Gg: AZuq6aIEsL7mop0OI5QgR8aglnXHWO6FMYecT33SfhfHAd8aLmpoPyu9CUW17+QqebA qeP1ufBoI/BOPCn/DRcWQ6M5BuILO/k6KjCE9M2m4I6MJyHdswWgr3xtlS6eRtifTIhcHDDHt6x 6HmuKth+nlsGJPkoANO471uJcO4ZwEeyhni+2EeDCWY03h0OxV92rGCpmDJH6KPRg3fRtH+ReWr 9b/OShV/eei970HXKivNXBb5KMH1CM8hRIzSGwTS8j7q87Ap7cVjVNIW7fQ1dGseFHJB9XaDeep Y2zF+bHmIuxJn8GWg6W65YxlQg3jJb9OnD0O+tf6xrU53o9b6H3pxOaVU0vOBoeTfHmjoQbOB3M nDzmXpWG8bVD6zgL0CtMlJ8q7Nozj8i7QlqEhNZ2N6FoHXgJ0JvWTEVw483o3vFujPtmWXOEbbS /qxIoTAtVR/ZlHRsovDrvd03b8PyN4 X-Received: by 2002:a05:600c:3b8e:b0:47e:e807:a05a with SMTP id 5b1f17b1804b1-4805d064497mr79561075e9.33.1769431145878; Mon, 26 Jan 2026 04:39:05 -0800 (PST) Received: from [192.168.50.4] ([82.78.167.31]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4804d627871sm102636035e9.6.2026.01.26.04.39.04 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 26 Jan 2026 04:39:05 -0800 (PST) Message-ID: <5438ccc8-ed5a-4dd6-8995-e8e9926883a5@tuxon.dev> Date: Mon, 26 Jan 2026 14:39:03 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 5/7] dmaengine: sh: rz-dmac: Add suspend to RAM support To: Biju Das , "vkoul@kernel.org" , Prabhakar Mahadev Lad , "lgirdwood@gmail.com" , "broonie@kernel.org" , "perex@perex.cz" , "tiwai@suse.com" , "p.zabel@pengutronix.de" , "geert+renesas@glider.be" , Fabrizio Castro Cc: "dmaengine@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-sound@vger.kernel.org" , "linux-renesas-soc@vger.kernel.org" , Claudiu Beznea References: <20260126103155.2644586-1-claudiu.beznea.uj@bp.renesas.com> <20260126103155.2644586-6-claudiu.beznea.uj@bp.renesas.com> <16a6f14a-93e6-472c-8718-d46972f0ac5e@tuxon.dev> Content-Language: en-US From: Claudiu Beznea In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 1/26/26 14:10, Biju Das wrote: > > >> -----Original Message----- >> From: Claudiu Beznea >> Sent: 26 January 2026 12:05 >> To: Biju Das ; vkoul@kernel.org; Prabhakar Mahadev Lad > lad.rj@bp.renesas.com>; lgirdwood@gmail.com; broonie@kernel.org; perex@perex.cz; tiwai@suse.com; >> p.zabel@pengutronix.de; geert+renesas@glider.be; Fabrizio Castro >> Cc: dmaengine@vger.kernel.org; linux-kernel@vger.kernel.org; linux-sound@vger.kernel.org; linux- >> renesas-soc@vger.kernel.org; Claudiu Beznea >> Subject: Re: [PATCH 5/7] dmaengine: sh: rz-dmac: Add suspend to RAM support >> >> Hi, >> >> On 1/26/26 13:03, Biju Das wrote: >>> Hi Claudiu, >>> >>> Thanks for the patch. >>> >>>> -----Original Message----- >>>> From: Claudiu >>>> Sent: 26 January 2026 10:32 >>>> Subject: [PATCH 5/7] dmaengine: sh: rz-dmac: Add suspend to RAM >>>> support >>>> >>>> From: Claudiu Beznea >>>> >>>> The Renesas RZ/G3S SoC supports a power saving mode in which power to >>>> most SoC components is turned off, including the DMA IP. Add suspend to RAM support to save and >> restore the DMA IP registers. >>>> >>>> Cyclic DMA channels require special handling. Since they can be >>>> paused and resumed during system suspend and resume, the driver >>>> restores additional registers for these channels during the resume >>>> phase. If a channel was not explicitly paused during suspend, the >>>> driver ensures that it is paused and resumed as part of the system suspend/resume flow. This might >> be the case of a serial device being used with no_console_suspend. >>>> >>>> For non-cyclic channels, the dev_pm_ops::prepare callback waits for >>>> all ongoing transfers to complete before allowing suspend-to-RAM to proceed. >>>> >>>> Signed-off-by: Claudiu Beznea >>>> --- >>>> drivers/dma/sh/rz-dmac.c | 183 +++++++++++++++++++++++++++++++++++++-- >>>> 1 file changed, 175 insertions(+), 8 deletions(-) >>>> >>>> diff --git a/drivers/dma/sh/rz-dmac.c b/drivers/dma/sh/rz-dmac.c >>>> index ab5f49a0b9f2..8f3e2719e639 >>>> + >>>> + pm_runtime_put_sync(dmac->dev); >>>> + >>>> + ret = reset_control_assert(dmac->rstc); >>>> + if (ret) { >>>> + pm_runtime_resume_and_get(dmac->dev); >>>> + rz_dmac_suspend_recover(dmac); >>>> + } >>>> + >>> >>> >>> This patch breaks, s2idle in RZ/G3L as it turns off DMA ACLK and IRQ's >>> are not routed to CPU for wakeup. >> >> Is this particular patch the one that explicitly breaks it? Is there any mainline PM support available >> for RZ/G3L? Can it be fixed along with the RZ/G3L support, if any, as I don't have the board to test >> it? > > Maybe your TF-A is enabling DMAACLK during resume. Can you check that mean time, I will check what you have mentioned > Here? > You used "freeze" in your example. Same did I to check your usecase. That suspend type don't involve TF-A (unless something changes and I'm not aware of). Thank you, Claudiu