Skip to contentSkip to conversation

iommu: Remove stack trace from broken irq remapping warning

PATCH Applied Neil Horman 4 participants 8 messages Sep 27, 2013 – Oct 4, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 iommu: Remove stack trace from broken irq remapping warning

The warning for the irq remapping broken check in intel_irq_remapping.c is pretty pointless. We need the warning, but we know where its comming from, the stack trace will always be the same, and it needlessly triggers things like Abrt. This changes the warning to just print a text warning about BIOS being broken, without the stack trace, then sets the appropriate taint bit. Since we automatically disable irq remapping, theres no need to contiue making Abrt jump at this problem

CC Joerg Roedel <[email protected]>
CC Bjorn Helgaas <[email protected]>
CC Andy Lutomirski <[email protected]>
CC Konrad Rzeszutek Wilk <[email protected]>
CC Sebastian Andrzej Siewior <[email protected]>
---
 drivers/iommu/intel_irq_remapping.c | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
drivers/iommu/intel_irq_remapping.c +7 -6
index f71673d..b97d70b 100644
@@ -525,12 +525,13 @@ static int __init intel_irq_remapping_supported(void)
 	if (disable_irq_remap)
 		return 0;
 	if (irq_remap_broken) {
-		WARN_TAINT(1, TAINT_FIRMWARE_WORKAROUND,
-			   "This system BIOS has enabled interrupt remapping\n"
-			   "on a chipset that contains an erratum making that\n"
-			   "feature unstable.  To maintain system stability\n"
-			   "interrupt remapping is being disabled.  Please\n"
-			   "contact your BIOS vendor for an update\n");
+		printk(KERN_WARNING
+			"This system BIOS has enabled interrupt remapping\n"
+			"on a chipset that contains an erratum making that\n"
+			"feature unstable.  To maintain system stability\n"
+			"interrupt remapping is being disabled.  Please\n"
+			"contact your BIOS vendor for an update\n");
+		add_taint(TAINT_FIRMWARE_WORKAROUND, LOCKDEP_STILL_OK);
 		disable_irq_remap = 1;
 		return 0;
 	}
Signature · 1 line
1.8.3.1
#1 lore raw
Quoted 29 lines · Neil Horman

The warning for the irq remapping broken check in intel_irq_remapping.c is pretty pointless. We need the warning, but we know where its comming from, the stack trace will always be the same, and it needlessly triggers things like Abrt. This changes the warning to just print a text warning about BIOS being broken, without the stack trace, then sets the appropriate taint bit. Since we automatically disable irq remapping, theres no need to contiue making Abrt jump at this problem

CC Joerg Roedel <[email protected]>
CC Bjorn Helgaas <[email protected]>
CC Andy Lutomirski <[email protected]>
CC Konrad Rzeszutek Wilk <[email protected]>
CC Sebastian Andrzej Siewior <[email protected]>
---
 drivers/iommu/intel_irq_remapping.c | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
drivers/iommu/intel_irq_remapping.c +0 -3
index f71673d..b97d70b 100644
@@ -525,12 +525,13 @@ static int __init intel_irq_remapping_supported(void)
        if (disable_irq_remap)
                return 0;
        if (irq_remap_broken) {
-               WARN_TAINT(1, TAINT_FIRMWARE_WORKAROUND,
-                          "This system BIOS has enabled interrupt remapping\n"
-                          "on a chipset that contains an erratum making that\n"

drivers/iommu/intel_irq_remapping.c static int __init intel_irq_remapping_supported(void) · line 534

Quoted 10 lines
drivers/iommu/intel_irq_remapping.c +7 -3
-                          "feature unstable.  To maintain system stability\n"
-                          "interrupt remapping is being disabled.  Please\n"
-                          "contact your BIOS vendor for an update\n");
+               printk(KERN_WARNING
+                       "This system BIOS has enabled interrupt remapping\n"
+                       "on a chipset that contains an erratum making that\n"
+                       "feature unstable.  To maintain system stability\n"
+                       "interrupt remapping is being disabled.  Please\n"
+                       "contact your BIOS vendor for an update\n");
+               add_taint(TAINT_FIRMWARE_WORKAROUND, LOCKDEP_STILL_OK);

Is the taint bit actually useful? It seems like functionality will be missing if this workaround happens, but everything should be stable.

--Andy

#2 lore raw
Quoted 35 lines · Andy Lutomirski
Quoted 34 lines · Neil Horman

The warning for the irq remapping broken check in intel_irq_remapping.c is pretty pointless. We need the warning, but we know where its comming from, the stack trace will always be the same, and it needlessly triggers things like Abrt. This changes the warning to just print a text warning about BIOS being broken, without the stack trace, then sets the appropriate taint bit. Since we automatically disable irq remapping, theres no need to contiue making Abrt jump at this problem

CC Joerg Roedel <[email protected]>
CC Bjorn Helgaas <[email protected]>
CC Andy Lutomirski <[email protected]>
CC Konrad Rzeszutek Wilk <[email protected]>
CC Sebastian Andrzej Siewior <[email protected]>
---
 drivers/iommu/intel_irq_remapping.c | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
drivers/iommu/intel_irq_remapping.c +2 -6
index f71673d..b97d70b 100644
@@ -525,12 +525,13 @@ static int __init intel_irq_remapping_supported(void)
        if (disable_irq_remap)
                return 0;
        if (irq_remap_broken) {
-               WARN_TAINT(1, TAINT_FIRMWARE_WORKAROUND,
-                          "This system BIOS has enabled interrupt remapping\n"
-                          "on a chipset that contains an erratum making that\n"
-                          "feature unstable.  To maintain system stability\n"
-                          "interrupt remapping is being disabled.  Please\n"
-                          "contact your BIOS vendor for an update\n");
+               printk(KERN_WARNING
+                       "This system BIOS has enabled interrupt remapping\n"
Quoted 9 lines

drivers/iommu/intel_irq_remapping.c static int __init intel_irq_remapping_supported(void) · line 534

Quoted 5 lines
drivers/iommu/intel_irq_remapping.c +5 -0
+                       "on a chipset that contains an erratum making that\n"
+                       "feature unstable.  To maintain system stability\n"
+                       "interrupt remapping is being disabled.  Please\n"
+                       "contact your BIOS vendor for an update\n");
+               add_taint(TAINT_FIRMWARE_WORKAROUND, LOCKDEP_STILL_OK);

Is the taint bit actually useful? It seems like functionality will be missing if this workaround happens, but everything should be stable.

I think its useful yes. The system will be stable, an in fact should run exactly as it did before, but since the errata indicates this should be fixed in BIOS, its a reminder to the admin that you should investigate an update, or take action in manually disabling iommu on the command line

Its also in keeping with the way this was structured previously. Neil

Quoted 2 lines

--Andy

#3 lore raw
In reply to Neil Horman
Quoted 46 lines · Neil Horman

The warning for the irq remapping broken check in intel_irq_remapping.c is pretty pointless. We need the warning, but we know where its comming from, the stack trace will always be the same, and it needlessly triggers things like Abrt. This changes the warning to just print a text warning about BIOS being broken, without the stack trace, then sets the appropriate taint bit. Since we automatically disable irq remapping, theres no need to contiue making Abrt jump at this problem

CC Joerg Roedel <[email protected]>
CC Bjorn Helgaas <[email protected]>
CC Andy Lutomirski <[email protected]>
CC Konrad Rzeszutek Wilk <[email protected]>
CC Sebastian Andrzej Siewior <[email protected]>
---
 drivers/iommu/intel_irq_remapping.c | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
drivers/iommu/intel_irq_remapping.c +7 -6
index f71673d..b97d70b 100644
@@ -525,12 +525,13 @@ static int __init intel_irq_remapping_supported(void)
 	if (disable_irq_remap)
 		return 0;
 	if (irq_remap_broken) {
-		WARN_TAINT(1, TAINT_FIRMWARE_WORKAROUND,
-			   "This system BIOS has enabled interrupt remapping\n"
-			   "on a chipset that contains an erratum making that\n"
-			   "feature unstable.  To maintain system stability\n"
-			   "interrupt remapping is being disabled.  Please\n"
-			   "contact your BIOS vendor for an update\n");
+		printk(KERN_WARNING
+			"This system BIOS has enabled interrupt remapping\n"
+			"on a chipset that contains an erratum making that\n"
+			"feature unstable.  To maintain system stability\n"
+			"interrupt remapping is being disabled.  Please\n"
+			"contact your BIOS vendor for an update\n");
+		add_taint(TAINT_FIRMWARE_WORKAROUND, LOCKDEP_STILL_OK);
 		disable_irq_remap = 1;
 		return 0;
 	}
Signature · 1 line
1.8.3.1

Ping Bjorn, Jeorg, any thoughts here?
Neil

maintainer
#4 lore raw
Quoted 41 lines · Neil Horman
Quoted 40 lines · Neil Horman

The warning for the irq remapping broken check in intel_irq_remapping.c is pretty pointless. We need the warning, but we know where its comming from, the stack trace will always be the same, and it needlessly triggers things like Abrt. This changes the warning to just print a text warning about BIOS being broken, without the stack trace, then sets the appropriate taint bit. Since we automatically disable irq remapping, theres no need to contiue making Abrt jump at this problem

CC Joerg Roedel <[email protected]>
CC Bjorn Helgaas <[email protected]>
CC Andy Lutomirski <[email protected]>
CC Konrad Rzeszutek Wilk <[email protected]>
CC Sebastian Andrzej Siewior <[email protected]>
---
 drivers/iommu/intel_irq_remapping.c | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
drivers/iommu/intel_irq_remapping.c +7 -6
index f71673d..b97d70b 100644
@@ -525,12 +525,13 @@ static int __init intel_irq_remapping_supported(void)
      if (disable_irq_remap)
              return 0;
      if (irq_remap_broken) {
-             WARN_TAINT(1, TAINT_FIRMWARE_WORKAROUND,
-                        "This system BIOS has enabled interrupt remapping\n"
-                        "on a chipset that contains an erratum making that\n"
-                        "feature unstable.  To maintain system stability\n"
-                        "interrupt remapping is being disabled.  Please\n"
-                        "contact your BIOS vendor for an update\n");
+             printk(KERN_WARNING
+                     "This system BIOS has enabled interrupt remapping\n"
+                     "on a chipset that contains an erratum making that\n"
+                     "feature unstable.  To maintain system stability\n"
+                     "interrupt remapping is being disabled.  Please\n"
+                     "contact your BIOS vendor for an update\n");
+             add_taint(TAINT_FIRMWARE_WORKAROUND, LOCKDEP_STILL_OK);
              disable_irq_remap = 1;
Quoted 8 lines
Quoted 6 lines
drivers/iommu/intel_irq_remapping.c +0 -1
              return 0;
      }
--

1.8.3.1

Ping Bjorn, Jeorg, any thoughts here?

This is in drivers/iommu, so I'd prefer that Joerg handle this.

My opinion is that this patch does the right thing in dropping the backtrace and keeping the taint.

I tend to agree with Andy that we should also consider a second patch that drops the taint, because this is basically just a quirk that avoids broken chipset functionality, but as far as I can tell, there's no reason to fear an undebuggable problem related to disabling interrupt remapping. We don't taint the kernel for other similar quirks, so I don't see why we should here.

Bjorn

maintainer
#5 lore raw
In reply to Neil Horman
Quoted 9 lines · Neil Horman
Quoted 8 lines · Neil Horman

The warning for the irq remapping broken check in intel_irq_remapping.c is pretty pointless. We need the warning, but we know where its comming from, the stack trace will always be the same, and it needlessly triggers things like Abrt. This changes the warning to just print a text warning about BIOS being broken, without the stack trace, then sets the appropriate taint bit. Since we automatically disable irq remapping, theres no need to contiue making Abrt jump at this problem

Quoted 8 lines
Quoted 6 lines
CC Joerg Roedel <[email protected]>
CC Bjorn Helgaas <[email protected]>
CC Andy Lutomirski <[email protected]>
CC Konrad Rzeszutek Wilk <[email protected]>
CC Sebastian Andrzej Siewior <[email protected]>

Ping Bjorn, Jeorg, any thoughts here?

Yes, the patch is doing the right thing. I have it already on my list and will merge it soon.

Joerg

#6 lore raw
Quoted 17 lines · Joerg Roedel
Quoted 16 lines · Neil Horman
Quoted 14 lines · Neil Horman

The warning for the irq remapping broken check in intel_irq_remapping.c is pretty pointless. We need the warning, but we know where its comming from, the stack trace will always be the same, and it needlessly triggers things like Abrt. This changes the warning to just print a text warning about BIOS being broken, without the stack trace, then sets the appropriate taint bit. Since we automatically disable irq remapping, theres no need to contiue making Abrt jump at this problem

CC Joerg Roedel <[email protected]>
CC Bjorn Helgaas <[email protected]>
CC Andy Lutomirski <[email protected]>
CC Konrad Rzeszutek Wilk <[email protected]>
CC Sebastian Andrzej Siewior <[email protected]>
Quoted 5 lines
Quoted 1 line

Ping Bjorn, Jeorg, any thoughts here?

Yes, the patch is doing the right thing. I have it already on my list and will merge it soon.

Awesome, thanks guys. Regarding the taint, I'll propose something for that early next week.

Regards
Neil

Quoted 5 lines

Joerg

maintainer Applied
#7 lore raw
In reply to Neil Horman
Quoted 7 lines · Neil Horman

The warning for the irq remapping broken check in intel_irq_remapping.c is pretty pointless. We need the warning, but we know where its comming from, the stack trace will always be the same, and it needlessly triggers things like Abrt. This changes the warning to just print a text warning about BIOS being broken, without the stack trace, then sets the appropriate taint bit. Since we automatically disable irq remapping, theres no need to contiue making Abrt jump at this problem

Applied to x86/vt-d, thanks Neil.