From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pg1-f181.google.com (mail-pg1-f181.google.com [209.85.215.181]) (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 7051437475D for ; Fri, 8 May 2026 06:36:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.215.181 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778222209; cv=none; b=aLJTCFfK8XPyiOKlt+ZKX0IDf+DBfsCUrIh7fH844Vrj7tbW9WXa0PKZ9IYWmRQynYA4hmIl99yKvJAMqOrbvqDvqwY+myT2SU/ayIhy2LYlew02K1FVubGBFomlz7O99iubcH9XjDCLv3pmaSqhT2kqXSMmeIiBi22cqpGKitI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778222209; c=relaxed/simple; bh=9jqLAACjfGjKanuQVNeQ7eoQMeqQBRzeZ3dpRjunfuQ=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=XvsNoRghi5ZqEXz7bs/uh1nRFNnJ8VonQHqlF+d5BgvTyKGYDLj5uPuofCvAhFoTuP6ZF/sXYfPPAIcU3rsQ76maWpfV1kQ8MpmWf5ETkuwo8AmvUAKQca3cV2LUowz5z/k6hI7upBnKP0g8WdLMcDvabjFq4eNGnGDq7lMUtS8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org; spf=pass smtp.mailfrom=chromium.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b=V4KBoMSO; arc=none smtp.client-ip=209.85.215.181 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=chromium.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="V4KBoMSO" Received: by mail-pg1-f181.google.com with SMTP id 41be03b00d2f7-c80148ae949so723324a12.2 for ; Thu, 07 May 2026 23:36:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1778222202; x=1778827002; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=22ncQpWLdF2X8pTtJBnqzgTb5DeYk3+PKhZtvYNM/EM=; b=V4KBoMSOVmUilffq/53aV8sUf+yvt7SDCNNXjUJpOemFFhyW9EYBhX91yjFh3+jBOg ifnM4Puk0SkxvCcYvKTCy/oQdJ72WZ5zdA5ULyBiCzYc06/hJ1twPiMLI93GqoCrUdoY szZCnvJqgbcrrMTv8y0yX6I/5AmrF5NEOreBs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778222202; x=1778827002; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=22ncQpWLdF2X8pTtJBnqzgTb5DeYk3+PKhZtvYNM/EM=; b=A0hvmieuCHOSZHVOo4gVu8XcXVaqn1xA/CJJP3i6JeCTK/vsg/ee0wZKZkzzNqc0dB vDivkoH1J3DJE8flh3K+OAcahVUQut+qnyFYG7XHcMnJrzzZtuRG8hQj5t3G0+N+CEmn r4O+jBByyaY9+TPlDohdn9iodLOIGZgPDDjBabRoc7RkZ3EZFLrG8zbDgYoW0DqKi/4A 1KbE0uDQeyJ8kPwh3ZlvVdzIAunn1QIbpxWWlQ2pfN2mw2RTyIwwVruc11xhA4aWHGed TzPRCU5h4iObHxUHVuhZ6+uXHMHD5gmyLryunucD4MHTJP+iPehE4XlSa/G2O2MU1fh3 nKJg== X-Forwarded-Encrypted: i=1; AFNElJ8cT1g173s4MWtuijCuivj5QgjfwdgaXO3CseryIasrmFee9r1vOEvB/6OGPZhNl4Bk4flvbLRU9LtLavw=@vger.kernel.org X-Gm-Message-State: AOJu0YwowaBpp8on3RtVNsdPWJuMG3n/IbpVQ+gkg3wWD1mXZjm7EYm5 g/Kf6RxlrF21PBKsXs04yZMgYRi1g9DNFZwI2uYkf6Xbki2k8oCEkqp1tNXVnhoSGQ== X-Gm-Gg: AeBDieto0wkH9np+xWNYl7VdVIFu4+8dqXjCW/yiKKrdi5V+fvAxdMFkenqHq4B3hlM ogPdtUrbnUF+XtvRv1FIiZ9mbXiTJZZyL8eTonYcfZmkUBDDxGk0t1mDfFKicP+RR8hnyAshjeh 8vzA3NKYA3hiVAKryYYYgH9LJ5hnPAoVHwaIswsU5fi2tKp1b95B9Lf7exYdrOSRBEjYLiKznyN HxsdL24n+KOFkVWjlvGpdZvQ9wK9lzTBDbSI3O+jfaTWYeWohZt69UxIEacYNhg7Br3QqjHQEUq CE+K7bb70O9h1BcPxMKzmP5Qt97oIj8cz3z9RLnx21XMX/qYFGzUd/eHqFY2Ygi+Sr/tRoeLNma GGevR5rM+aR0I6ru0jxj2smlT4IGlmR7+jf3K6bPmkE8Bk3Ab/E7foehdS8+rDckfAjZj+NrtFA 6JvlHYCWhfmORu6PT5AqiTWG1mACdvXPrqvhpMexSsQCs9BYKxHoYtVdeJB5p42CK1lo2fTfvdF 1OwFkiUvQD04Ixgnw== X-Received: by 2002:a05:6a20:939d:b0:398:6ea8:21f7 with SMTP id adf61e73a8af0-3aa5a9559ebmr11751571637.15.1778222202210; Thu, 07 May 2026 23:36:42 -0700 (PDT) Received: from wenstp920.tpe.corp.google.com ([2a00:79e0:201d:8:bac0:e137:a29f:62c]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-83967dbee14sm14850717b3a.48.2026.05.07.23.36.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 May 2026 23:36:41 -0700 (PDT) From: Chen-Yu Tsai To: Matthias Brugger , AngeloGioacchino Del Regno , Ryder Lee , Lorenzo Pieralisi , =?UTF-8?q?Krzysztof=20Wilczy=C5=84ski?= , Manivannan Sadhasivam , Rob Herring , Bjorn Helgaas , Krzysztof Kozlowski , Conor Dooley Cc: Chen-Yu Tsai , devicetree@vger.kernel.org, linux-pci@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] dt-bindings: PCI: mediatek-gen3: Allow memory-region for restricted DMA buffer Date: Fri, 8 May 2026 14:36:32 +0800 Message-ID: <20260508063633.3894348-1-wenst@chromium.org> X-Mailer: git-send-email 2.54.0.563.g4f69b47b94-goog Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit On some SoCs without an IOMMU behind the PCIe controller, the PCIe controller memory access could be limited to a small region by the firmware configuring a memory protection unit. This memory region must be assigned to the PCIe controller so that the OS knows to use that region. Otherwise PCIe devices would not work properly. Allow the memory-region property with one item pointing to a restricted DMA buffer. Signed-off-by: Chen-Yu Tsai --- This patch compliments another patch that moved the memory-region from the PCIe device to the PCIe controller [1]. [1] https://lore.kernel.org/all/20260430120725.241779-1-wenst@chromium.org/ Documentation/devicetree/bindings/pci/mediatek-pcie-gen3.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Documentation/devicetree/bindings/pci/mediatek-pcie-gen3.yaml b/Documentation/devicetree/bindings/pci/mediatek-pcie-gen3.yaml index 4db700fc36ba..4a9e41d01628 100644 --- a/Documentation/devicetree/bindings/pci/mediatek-pcie-gen3.yaml +++ b/Documentation/devicetree/bindings/pci/mediatek-pcie-gen3.yaml @@ -115,6 +115,10 @@ properties: power-domains: maxItems: 1 + memory-region: + maxItems: 1 + description: phandle to restricted DMA buffer + mediatek,pbus-csr: $ref: /schemas/types.yaml#/definitions/phandle-array items: -- 2.54.0.563.g4f69b47b94-goog