From patchwork Mon Jul 11 14:48:08 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Peter_M=C3=BCller?= X-Patchwork-Id: 5743 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384 client-signature ECDSA (P-384) client-digest SHA384) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4LhRZn5N1vz3x1v for ; Mon, 11 Jul 2022 14:48:17 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384 client-signature ECDSA (P-384) client-digest SHA384) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4LhRZl0crZzd6; Mon, 11 Jul 2022 14:48:15 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4LhRZk74Jvz2ypS; Mon, 11 Jul 2022 14:48:14 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384 client-signature ECDSA (P-384) client-digest SHA384) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4LhRZj328cz2xHs for ; Mon, 11 Jul 2022 14:48:13 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4LhRZg30jxzGR for ; Mon, 11 Jul 2022 14:48:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1657550892; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=xR1jMqKs0e1yERo/FvjCF/bUBUCFgn7Nmjqm6lH/zUs=; b=IHjbMg/+goGml1uedFb5d/fQ6TZA8J5m7kFpoJnYgJxbgTQB40oAM809TYVEKkYJlVquwa 61wCh+s3wHagI+S3IGqKoC3oEtf3SgyFfO406DJHWeFgLjU6wUiF7j2pgSUHTwR8aPTTLj 2FNTw1XxS1zwTiiuhze0niwXoPDvx+NaCNRcZi+45CRwaIUoSdzsflOFhY6wm2JQ/LQMO2 Z7ikg1uO8ugL1ER5h+f8fEIXrEuYGFgn+43rh7gd6OnBfQM0MPv6ncuqCxsuabDuEomTbv LnhOXjdrv+8kVWIAkfNQSdnSn8A1UhoNadRzYF2tbqlspbehMyz8mhtqKfvK4Q== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1657550892; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=xR1jMqKs0e1yERo/FvjCF/bUBUCFgn7Nmjqm6lH/zUs=; b=+mlduex2R7WCkVDZ1+xiH+qyheskPG7bmQP2QGlwVWA2zpMgAMslEiDihvwJTYdQviq20D qcg5gqgJzE6AeqBQ== Message-ID: <1416c8e1-d570-475b-8811-78ad39793078@ipfire.org> Date: Mon, 11 Jul 2022 14:48:08 +0000 MIME-Version: 1.0 Content-Language: en-US To: "IPFire: Development" From: =?utf-8?q?Peter_M=C3=BCller?= Subject: [PATCH] linux: Enable Intel DMA Remapping Devices by default on x86_64 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" If available, the kernel will enable IOMMU (a/k/a DMA remapping) by default on boot. To tools making use of that, particularly hypervisors, this provides better security without any downsides. Signed-off-by: Peter Müller --- config/kernel/kernel.config.x86_64-ipfire | 2 +- config/rootfiles/common/x86_64/linux | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/config/kernel/kernel.config.x86_64-ipfire b/config/kernel/kernel.config.x86_64-ipfire index 06d98e325..a5c5a4e29 100644 --- a/config/kernel/kernel.config.x86_64-ipfire +++ b/config/kernel/kernel.config.x86_64-ipfire @@ -6488,7 +6488,7 @@ CONFIG_AMD_IOMMU_V2=y CONFIG_DMAR_TABLE=y CONFIG_INTEL_IOMMU=y CONFIG_INTEL_IOMMU_SVM=y -# CONFIG_INTEL_IOMMU_DEFAULT_ON is not set +CONFIG_INTEL_IOMMU_DEFAULT_ON=y CONFIG_INTEL_IOMMU_FLOPPY_WA=y # CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON is not set CONFIG_IRQ_REMAP=y diff --git a/config/rootfiles/common/x86_64/linux b/config/rootfiles/common/x86_64/linux index 326bc6c6e..22c8cf352 100644 --- a/config/rootfiles/common/x86_64/linux +++ b/config/rootfiles/common/x86_64/linux @@ -8071,6 +8071,7 @@ etc/modprobe.d/ipv6.conf #lib/modules/KVER-ipfire/build/include/config/INTEL_INT0002_VGPIO #lib/modules/KVER-ipfire/build/include/config/INTEL_IOATDMA #lib/modules/KVER-ipfire/build/include/config/INTEL_IOMMU +#lib/modules/KVER-ipfire/build/include/config/INTEL_IOMMU_DEFAULT_ON #lib/modules/KVER-ipfire/build/include/config/INTEL_IOMMU_FLOPPY_WA #lib/modules/KVER-ipfire/build/include/config/INTEL_IOMMU_SVM #lib/modules/KVER-ipfire/build/include/config/INTEL_IPS