Linux-mediatek Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Chen-Yu Tsai <wenst@chromium.org>
To: Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>,
	Matthias Brugger <matthias.bgg@gmail.com>,
	AngeloGioacchino Del Regno
	<angelogioacchino.delregno@collabora.com>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>
Cc: Chen-Yu Tsai <wenst@chromium.org>,
	Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
	Jiaxin Yu <jiaxin.yu@mediatek.com>,
	linux-sound@vger.kernel.org, devicetree@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: [PATCH v2 12/13] arm64: dts: mediatek: mt8186-corsola: Reserve memory for audio frontend
Date: Thu, 24 Apr 2025 18:25:06 +0800	[thread overview]
Message-ID: <20250424102509.1083185-13-wenst@chromium.org> (raw)
In-Reply-To: <20250424102509.1083185-1-wenst@chromium.org>

Some MediaTek platforms already reserve a small block of memory for the
audio frontend. These platforms reserve it at a fixed address, though it
is unclear if that is due to hardware access restrictions or simply
compacting the reserved memory blocks together.

Reserve the same size of memory on the MT8186 Corsola family as well, to
align with the other MediaTek-based ChromeOS platforms. This also helps
with memory starvation as these devices sometimes end up in low memory
conditions.

Signed-off-by: Chen-Yu Tsai <wenst@chromium.org>
---
 arch/arm64/boot/dts/mediatek/mt8186-corsola.dtsi | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/arch/arm64/boot/dts/mediatek/mt8186-corsola.dtsi b/arch/arm64/boot/dts/mediatek/mt8186-corsola.dtsi
index c864ed495702..b139588ae246 100644
--- a/arch/arm64/boot/dts/mediatek/mt8186-corsola.dtsi
+++ b/arch/arm64/boot/dts/mediatek/mt8186-corsola.dtsi
@@ -161,6 +161,13 @@ reserved_memory: reserved-memory {
 		#size-cells = <2>;
 		ranges;
 
+		afe_dma_mem: audio-dma-pool {
+			compatible = "shared-dma-pool";
+			size = <0 0x100000>;
+			alignment = <0 0x10>;
+			no-map;
+		};
+
 		adsp_dma_mem: memory@61000000 {
 			compatible = "shared-dma-pool";
 			reg = <0 0x61000000 0 0x100000>;
@@ -310,6 +317,7 @@ &adsp {
 };
 
 &afe {
+	memory-region = <&afe_dma_mem>;
 	status = "okay";
 };
 
-- 
2.49.0.805.g082f7c87e0-goog



  parent reply	other threads:[~2025-04-24 11:45 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-24 10:24 [PATCH v2 00/13] ASoC: mediatek: use reserved memory or enable buffer pre-allocation Chen-Yu Tsai
2025-04-24 10:24 ` [PATCH v2 01/13] ASoC: dt-bindings: Convert MT8173 AFE binding to dt-schema Chen-Yu Tsai
2025-04-28  7:24   ` Krzysztof Kozlowski
2025-04-24 10:24 ` [PATCH v2 02/13] ASoC: dt-bindings: mt8173-afe-pcm: Add power domain Chen-Yu Tsai
2025-05-09 18:08   ` Rob Herring (Arm)
2025-04-24 10:24 ` [PATCH v2 03/13] ASoC: dt-bindings: mt8173-afe-pcm: Allow specifying reserved memory region Chen-Yu Tsai
2025-05-09 18:08   ` Rob Herring (Arm)
2025-04-24 10:24 ` [PATCH v2 04/13] ASoC: dt-bindings: mt8186-afe-pcm: " Chen-Yu Tsai
2025-05-09 18:08   ` Rob Herring (Arm)
2025-04-24 10:24 ` [PATCH v2 05/13] ASoC: dt-bindings: mt8192-afe-pcm: " Chen-Yu Tsai
2025-05-09 18:09   ` Rob Herring (Arm)
2025-04-24 10:25 ` [PATCH v2 06/13] ASoC: mediatek: use reserved memory or enable buffer pre-allocation Chen-Yu Tsai
2025-04-24 10:25 ` [PATCH v2 07/13] ASoC: mediatek: mt8183-afe-pcm: Support >32 bit DMA addresses Chen-Yu Tsai
2025-06-11 16:21   ` Mark Brown
2025-04-24 10:25 ` [PATCH v2 08/13] ASoC: mediatek: mt8173-afe-pcm: use local `dev` pointer in driver callbacks Chen-Yu Tsai
2025-04-24 10:25 ` [PATCH v2 09/13] ASoC: mediatek: mt8183-afe-pcm: " Chen-Yu Tsai
2025-06-11 16:22   ` Mark Brown
2025-04-24 10:25 ` [PATCH v2 10/13] arm64: dts: mediatek: mt8173: Reserve memory for audio frontend Chen-Yu Tsai
2025-04-24 10:25 ` [PATCH v2 11/13] arm64: dts: mediatek: mt8183-kukui: " Chen-Yu Tsai
2025-04-24 10:25 ` Chen-Yu Tsai [this message]
2025-04-24 10:25 ` [PATCH v2 13/13] arm64: dts: mediatek: mt8192-asurada: " Chen-Yu Tsai
2025-05-14  8:54 ` [PATCH v2 00/13] ASoC: mediatek: use reserved memory or enable buffer pre-allocation Mark Brown
2025-06-11 10:22   ` AngeloGioacchino Del Regno
2025-06-11 10:31     ` AngeloGioacchino Del Regno
2025-06-14 11:12 ` (subset) " Mark Brown

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=20250424102509.1083185-13-wenst@chromium.org \
    --to=wenst@chromium.org \
    --cc=angelogioacchino.delregno@collabora.com \
    --cc=broonie@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=jiaxin.yu@mediatek.com \
    --cc=krzk+dt@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=matthias.bgg@gmail.com \
    --cc=perex@perex.cz \
    --cc=robh@kernel.org \
    --cc=tiwai@suse.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