diff mbox series

[U/N,1/1] UBUNTU: [Config] enable Intel DMA remapping by default

Message ID 20240221085633.419512-1-andrea.righi@canonical.com
State New
Headers show
Series [U/N,1/1] UBUNTU: [Config] enable Intel DMA remapping by default | expand

Commit Message

Andrea Righi Feb. 21, 2024, 8:56 a.m. UTC
BugLink: https://bugs.launchpad.net/bugs/1951440

We have tried in the past to enable CONFIG_INTEL_IOMMU_DEFAULT_ON and
CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON (starting with Jammy), but
there were multiple issues (especially with old hardware), so we ended
up disabling these options afterwards, see LP: #1971699.

Considering that IOMMU is enabled by default in upstream kernels,
probably most of these issues are solved now (or old hardware has been
decommissioned).

Moreover, having this enabled by default can prevent potential issues
with modern hardware and drivers (see for example LP #1958004).

Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
---
 debian.master/config/annotations | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

Comments

Andrei Gherzan Feb. 21, 2024, 10:44 a.m. UTC | #1
On 24/02/21 09:56AM, Andrea Righi wrote:
> BugLink: https://bugs.launchpad.net/bugs/1951440
> 
> We have tried in the past to enable CONFIG_INTEL_IOMMU_DEFAULT_ON and
> CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON (starting with Jammy), but
> there were multiple issues (especially with old hardware), so we ended
> up disabling these options afterwards, see LP: #1971699.
> 
> Considering that IOMMU is enabled by default in upstream kernels,
> probably most of these issues are solved now (or old hardware has been
> decommissioned).
> 
> Moreover, having this enabled by default can prevent potential issues
> with modern hardware and drivers (see for example LP #1958004).
> 
> Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
> ---
>  debian.master/config/annotations | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/debian.master/config/annotations b/debian.master/config/annotations
> index 5c9c4f9afb11..d459e470d806 100644
> --- a/debian.master/config/annotations
> +++ b/debian.master/config/annotations
> @@ -321,8 +321,11 @@ CONFIG_INTEL_ATOMISP                            note<'LP: #2017444'>
>  CONFIG_INTEL_ATOMISP2_PM                        policy<{'amd64': 'm'}>
>  CONFIG_INTEL_ATOMISP2_PM                        note<'LP: #2017444'>
>  
> -CONFIG_INTEL_IOMMU_DEFAULT_ON                   policy<{'amd64': 'n'}>
> -CONFIG_INTEL_IOMMU_DEFAULT_ON                   note<'LP: #1971699'>
> +CONFIG_INTEL_IOMMU_DEFAULT_ON                   policy<{'amd64': 'y'}>
> +CONFIG_INTEL_IOMMU_DEFAULT_ON                   note<'LP: #1951440'>
> +
> +CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     policy<{'amd64': 'y'}>
> +CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     note<'LP: #1951440'>
>  
>  CONFIG_IOMMU_DEBUGFS                            policy<{'amd64': 'n', 'arm64': 'n', 'armhf': 'n', 'ppc64el': 'n', 'riscv64': 'n', 's390x': 'n'}>
>  CONFIG_IOMMU_DEBUGFS                            note<'LP: #1861057'>
> @@ -6567,7 +6570,6 @@ CONFIG_INTEL_IOATDMA                            policy<{'amd64': 'm'}>
>  CONFIG_INTEL_IOMMU                              policy<{'amd64': 'y'}>
>  CONFIG_INTEL_IOMMU_FLOPPY_WA                    policy<{'amd64': 'y'}>
>  CONFIG_INTEL_IOMMU_PERF_EVENTS                  policy<{'amd64': 'y'}>
> -CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     policy<{'amd64': 'n'}>
>  CONFIG_INTEL_IOMMU_SVM                          policy<{'amd64': 'y'}>
>  CONFIG_INTEL_IPS                                policy<{'amd64': 'm'}>
>  CONFIG_INTEL_ISHTP_ECLITE                       policy<{'amd64': 'm'}>

Acked-by: Andrei Gherzan <andrei.gherzan@canonical.com>
Philip Cox Feb. 21, 2024, 11:19 a.m. UTC | #2
On Wed, 2024-02-21 at 09:56 +0100, Andrea Righi wrote:
> BugLink: https://bugs.launchpad.net/bugs/1951440
> 
> We have tried in the past to enable CONFIG_INTEL_IOMMU_DEFAULT_ON and
> CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON (starting with Jammy),
> but
> there were multiple issues (especially with old hardware), so we
> ended
> up disabling these options afterwards, see LP: #1971699.
> 
> Considering that IOMMU is enabled by default in upstream kernels,
> probably most of these issues are solved now (or old hardware has
> been
> decommissioned).
> 
> Moreover, having this enabled by default can prevent potential issues
> with modern hardware and drivers (see for example LP #1958004).
> 
> Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
> ---
>  debian.master/config/annotations | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/debian.master/config/annotations
> b/debian.master/config/annotations
> index 5c9c4f9afb11..d459e470d806 100644
> --- a/debian.master/config/annotations
> +++ b/debian.master/config/annotations
> @@ -321,8 +321,11 @@ CONFIG_INTEL_ATOMISP                           
> note<'LP: #2017444'>
>  CONFIG_INTEL_ATOMISP2_PM                        policy<{'amd64':
> 'm'}>
>  CONFIG_INTEL_ATOMISP2_PM                        note<'LP: #2017444'>
>  
> -CONFIG_INTEL_IOMMU_DEFAULT_ON                   policy<{'amd64':
> 'n'}>
> -CONFIG_INTEL_IOMMU_DEFAULT_ON                   note<'LP: #1971699'>
> +CONFIG_INTEL_IOMMU_DEFAULT_ON                   policy<{'amd64':
> 'y'}>
> +CONFIG_INTEL_IOMMU_DEFAULT_ON                   note<'LP: #1951440'>
> +
> +CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     policy<{'amd64':
> 'y'}>
> +CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     note<'LP: #1951440'>
>  
>  CONFIG_IOMMU_DEBUGFS                            policy<{'amd64':
> 'n', 'arm64': 'n', 'armhf': 'n', 'ppc64el': 'n', 'riscv64': 'n',
> 's390x': 'n'}>
>  CONFIG_IOMMU_DEBUGFS                            note<'LP: #1861057'>
> @@ -6567,7 +6570,6 @@ CONFIG_INTEL_IOATDMA                           
> policy<{'amd64': 'm'}>
>  CONFIG_INTEL_IOMMU                              policy<{'amd64':
> 'y'}>
>  CONFIG_INTEL_IOMMU_FLOPPY_WA                    policy<{'amd64':
> 'y'}>
>  CONFIG_INTEL_IOMMU_PERF_EVENTS                  policy<{'amd64':
> 'y'}>
> -CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     policy<{'amd64':
> 'n'}>
>  CONFIG_INTEL_IOMMU_SVM                          policy<{'amd64':
> 'y'}>
>  CONFIG_INTEL_IPS                                policy<{'amd64':
> 'm'}>
>  CONFIG_INTEL_ISHTP_ECLITE                       policy<{'amd64':
> 'm'}>
> -- 
> 2.43.0
> 
>
Philip Cox Feb. 21, 2024, 11:23 a.m. UTC | #3
On Wed, Feb 21, 2024 at 3:57 AM Andrea Righi <andrea.righi@canonical.com>
wrote:

> BugLink: https://bugs.launchpad.net/bugs/1951440
>
> We have tried in the past to enable CONFIG_INTEL_IOMMU_DEFAULT_ON and
> CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON (starting with Jammy), but
> there were multiple issues (especially with old hardware), so we ended
> up disabling these options afterwards, see LP: #1971699.
>
> Considering that IOMMU is enabled by default in upstream kernels,
> probably most of these issues are solved now (or old hardware has been
> decommissioned).
>
> Moreover, having this enabled by default can prevent potential issues
> with modern hardware and drivers (see for example LP #1958004).
>
> Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
> ---
>  debian.master/config/annotations | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/debian.master/config/annotations
> b/debian.master/config/annotations
> index 5c9c4f9afb11..d459e470d806 100644
> --- a/debian.master/config/annotations
> +++ b/debian.master/config/annotations
> @@ -321,8 +321,11 @@ CONFIG_INTEL_ATOMISP
> note<'LP: #2017444'>
>  CONFIG_INTEL_ATOMISP2_PM                        policy<{'amd64': 'm'}>
>  CONFIG_INTEL_ATOMISP2_PM                        note<'LP: #2017444'>
>
> -CONFIG_INTEL_IOMMU_DEFAULT_ON                   policy<{'amd64': 'n'}>
> -CONFIG_INTEL_IOMMU_DEFAULT_ON                   note<'LP: #1971699'>
> +CONFIG_INTEL_IOMMU_DEFAULT_ON                   policy<{'amd64': 'y'}>
> +CONFIG_INTEL_IOMMU_DEFAULT_ON                   note<'LP: #1951440'>
> +
> +CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     policy<{'amd64': 'y'}>
> +CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     note<'LP: #1951440'>
>
>  CONFIG_IOMMU_DEBUGFS                            policy<{'amd64': 'n',
> 'arm64': 'n', 'armhf': 'n', 'ppc64el': 'n', 'riscv64': 'n', 's390x': 'n'}>
>  CONFIG_IOMMU_DEBUGFS                            note<'LP: #1861057'>
> @@ -6567,7 +6570,6 @@ CONFIG_INTEL_IOATDMA
> policy<{'amd64': 'm'}>
>  CONFIG_INTEL_IOMMU                              policy<{'amd64': 'y'}>
>  CONFIG_INTEL_IOMMU_FLOPPY_WA                    policy<{'amd64': 'y'}>
>  CONFIG_INTEL_IOMMU_PERF_EVENTS                  policy<{'amd64': 'y'}>
> -CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     policy<{'amd64': 'n'}>
>  CONFIG_INTEL_IOMMU_SVM                          policy<{'amd64': 'y'}>
>  CONFIG_INTEL_IPS                                policy<{'amd64': 'm'}>
>  CONFIG_INTEL_ISHTP_ECLITE                       policy<{'amd64': 'm'}>
> --
> 2.43.0
>
>
Andrea Righi Feb. 21, 2024, 11:27 a.m. UTC | #4
On Wed, Feb 21, 2024 at 09:56:33AM +0100, Andrea Righi wrote:
> BugLink: https://bugs.launchpad.net/bugs/1951440
> 
> We have tried in the past to enable CONFIG_INTEL_IOMMU_DEFAULT_ON and
> CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON (starting with Jammy), but
> there were multiple issues (especially with old hardware), so we ended
> up disabling these options afterwards, see LP: #1971699.
> 
> Considering that IOMMU is enabled by default in upstream kernels,
> probably most of these issues are solved now (or old hardware has been
> decommissioned).
> 
> Moreover, having this enabled by default can prevent potential issues
> with modern hardware and drivers (see for example LP #1958004).
> 
> Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
> ---

Applied to noble/linux and noble/linux-unstable.

-Andrea

>  debian.master/config/annotations | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/debian.master/config/annotations b/debian.master/config/annotations
> index 5c9c4f9afb11..d459e470d806 100644
> --- a/debian.master/config/annotations
> +++ b/debian.master/config/annotations
> @@ -321,8 +321,11 @@ CONFIG_INTEL_ATOMISP                            note<'LP: #2017444'>
>  CONFIG_INTEL_ATOMISP2_PM                        policy<{'amd64': 'm'}>
>  CONFIG_INTEL_ATOMISP2_PM                        note<'LP: #2017444'>
>  
> -CONFIG_INTEL_IOMMU_DEFAULT_ON                   policy<{'amd64': 'n'}>
> -CONFIG_INTEL_IOMMU_DEFAULT_ON                   note<'LP: #1971699'>
> +CONFIG_INTEL_IOMMU_DEFAULT_ON                   policy<{'amd64': 'y'}>
> +CONFIG_INTEL_IOMMU_DEFAULT_ON                   note<'LP: #1951440'>
> +
> +CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     policy<{'amd64': 'y'}>
> +CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     note<'LP: #1951440'>
>  
>  CONFIG_IOMMU_DEBUGFS                            policy<{'amd64': 'n', 'arm64': 'n', 'armhf': 'n', 'ppc64el': 'n', 'riscv64': 'n', 's390x': 'n'}>
>  CONFIG_IOMMU_DEBUGFS                            note<'LP: #1861057'>
> @@ -6567,7 +6570,6 @@ CONFIG_INTEL_IOATDMA                            policy<{'amd64': 'm'}>
>  CONFIG_INTEL_IOMMU                              policy<{'amd64': 'y'}>
>  CONFIG_INTEL_IOMMU_FLOPPY_WA                    policy<{'amd64': 'y'}>
>  CONFIG_INTEL_IOMMU_PERF_EVENTS                  policy<{'amd64': 'y'}>
> -CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     policy<{'amd64': 'n'}>
>  CONFIG_INTEL_IOMMU_SVM                          policy<{'amd64': 'y'}>
>  CONFIG_INTEL_IPS                                policy<{'amd64': 'm'}>
>  CONFIG_INTEL_ISHTP_ECLITE                       policy<{'amd64': 'm'}>
> -- 
> 2.43.0
Andrea Righi Feb. 21, 2024, 5:14 p.m. UTC | #5
On Wed, Feb 21, 2024 at 12:27:22PM +0100, Andrea Righi wrote:
> On Wed, Feb 21, 2024 at 09:56:33AM +0100, Andrea Righi wrote:
> > BugLink: https://bugs.launchpad.net/bugs/1951440
> > 
> > We have tried in the past to enable CONFIG_INTEL_IOMMU_DEFAULT_ON and
> > CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON (starting with Jammy), but
> > there were multiple issues (especially with old hardware), so we ended
> > up disabling these options afterwards, see LP: #1971699.
> > 
> > Considering that IOMMU is enabled by default in upstream kernels,
> > probably most of these issues are solved now (or old hardware has been
> > decommissioned).
> > 
> > Moreover, having this enabled by default can prevent potential issues
> > with modern hardware and drivers (see for example LP #1958004).
> > 
> > Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
> > ---
> 
> Applied to noble/linux and noble/linux-unstable.
> 
> -Andrea

After an internal discussion we have decided to not apply this in
noble/linux, but keep it only in noble/linux-unstable for now.

Therefore, I have un-applied this from noble/linux.

-Andrea
Andrea Righi Feb. 29, 2024, 2:11 p.m. UTC | #6
On Wed, Feb 21, 2024 at 09:56:33AM +0100, Andrea Righi wrote:
> BugLink: https://bugs.launchpad.net/bugs/1951440
> 
> We have tried in the past to enable CONFIG_INTEL_IOMMU_DEFAULT_ON and
> CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON (starting with Jammy), but
> there were multiple issues (especially with old hardware), so we ended
> up disabling these options afterwards, see LP: #1971699.
> 
> Considering that IOMMU is enabled by default in upstream kernels,
> probably most of these issues are solved now (or old hardware has been
> decommissioned).
> 
> Moreover, having this enabled by default can prevent potential issues
> with modern hardware and drivers (see for example LP #1958004).
> 
> Signed-off-by: Andrea Righi <andrea.righi@canonical.com>

Applied to noble/linux.

-Andrea
diff mbox series

Patch

diff --git a/debian.master/config/annotations b/debian.master/config/annotations
index 5c9c4f9afb11..d459e470d806 100644
--- a/debian.master/config/annotations
+++ b/debian.master/config/annotations
@@ -321,8 +321,11 @@  CONFIG_INTEL_ATOMISP                            note<'LP: #2017444'>
 CONFIG_INTEL_ATOMISP2_PM                        policy<{'amd64': 'm'}>
 CONFIG_INTEL_ATOMISP2_PM                        note<'LP: #2017444'>
 
-CONFIG_INTEL_IOMMU_DEFAULT_ON                   policy<{'amd64': 'n'}>
-CONFIG_INTEL_IOMMU_DEFAULT_ON                   note<'LP: #1971699'>
+CONFIG_INTEL_IOMMU_DEFAULT_ON                   policy<{'amd64': 'y'}>
+CONFIG_INTEL_IOMMU_DEFAULT_ON                   note<'LP: #1951440'>
+
+CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     policy<{'amd64': 'y'}>
+CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     note<'LP: #1951440'>
 
 CONFIG_IOMMU_DEBUGFS                            policy<{'amd64': 'n', 'arm64': 'n', 'armhf': 'n', 'ppc64el': 'n', 'riscv64': 'n', 's390x': 'n'}>
 CONFIG_IOMMU_DEBUGFS                            note<'LP: #1861057'>
@@ -6567,7 +6570,6 @@  CONFIG_INTEL_IOATDMA                            policy<{'amd64': 'm'}>
 CONFIG_INTEL_IOMMU                              policy<{'amd64': 'y'}>
 CONFIG_INTEL_IOMMU_FLOPPY_WA                    policy<{'amd64': 'y'}>
 CONFIG_INTEL_IOMMU_PERF_EVENTS                  policy<{'amd64': 'y'}>
-CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON     policy<{'amd64': 'n'}>
 CONFIG_INTEL_IOMMU_SVM                          policy<{'amd64': 'y'}>
 CONFIG_INTEL_IPS                                policy<{'amd64': 'm'}>
 CONFIG_INTEL_ISHTP_ECLITE                       policy<{'amd64': 'm'}>