From 09ea26f1bf31c381faf4504774326755d8c47108 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?=
 <nfraprado@collabora.com>
Date: Mon, 30 Jan 2023 15:08:20 -0500
Subject: [PATCH] arm64: defconfig: Enable DMA_RESTRICTED_POOL
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Enable support for restricted DMA pools which provide a level of DMA
memory protection on systems with limited hardware protection
capabilities, such as those lacking an IOMMU.

For instance, mt8192-asurada-spherion makes use of this to provide a
restricted DMA region for WiFi since its MT7921E WiFi card is connected
through PCIe, and the MT8192 SoC doesn't have an IOMMU context for the
PCIe controller.

Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
Link: https://lore.kernel.org/r/20230130200820.82084-2-nfraprado@collabora.com
Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
---
 arch/arm64/configs/defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig
index ef17d32ed7e2..236b83e62712 100644
--- a/arch/arm64/configs/defconfig
+++ b/arch/arm64/configs/defconfig
@@ -1408,6 +1408,7 @@ CONFIG_CRYPTO_DEV_HISI_SEC2=m
 CONFIG_CRYPTO_DEV_HISI_ZIP=m
 CONFIG_CRYPTO_DEV_HISI_HPRE=m
 CONFIG_CRYPTO_DEV_HISI_TRNG=m
+CONFIG_DMA_RESTRICTED_POOL=y
 CONFIG_CMA_SIZE_MBYTES=32
 CONFIG_PRINTK_TIME=y
 CONFIG_DEBUG_KERNEL=y
-- 
2.30.9