mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH]: x86: Don't check for BIOS corruption in first 64K when there's no need to
@ 2011-02-25 20:31 Naga Chumbalkar
  2011-03-09 11:22 ` [tip:x86/urgent] " tip-bot for Naga Chumbalkar
  2011-03-09 15:40 ` tip-bot for Naga Chumbalkar
  0 siblings, 2 replies; 3+ messages in thread
From: Naga Chumbalkar @ 2011-02-25 20:31 UTC (permalink / raw)
  To: x86
  Cc: Naga Chumbalkar, H. Peter Anvin, linux-kernel, Thomas Gleixner,
	Ingo Molnar

Due to commit 781c5a67f152c17c3e4a9ed9647f8c0be6ea5ae9 it is likely that
the number of areas to scan for BIOS corruption is 0 -- especially when
the first 64K is already reserved (X86_RESERVE_LOW is 64K by default).
If that's the case then don't set up the scan.

Signed-off-by: Naga Chumbalkar <nagananda.chumbalkar@hp.com>
---
 arch/x86/kernel/check.c |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/arch/x86/kernel/check.c b/arch/x86/kernel/check.c
index 13a3891..a9480e1 100644
--- a/arch/x86/kernel/check.c
+++ b/arch/x86/kernel/check.c
@@ -106,8 +106,9 @@ void __init setup_bios_corruption_check(void)
 		addr += size;
 	}
 
-	printk(KERN_INFO "Scanning %d areas for low memory corruption\n",
-	       num_scan_areas);
+	if (num_scan_areas)
+		printk(KERN_INFO "Scanning %d areas for low memory "
+		       "corruption\n", num_scan_areas);
 }
 
 
@@ -148,7 +149,8 @@ static void check_corruption(struct work_struct *dummy)
 
 static int start_periodic_check_for_corruption(void)
 {
-	if (!memory_corruption_check || corruption_check_period == 0)
+	if (!num_scan_areas || !memory_corruption_check ||
+	    corruption_check_period == 0)
 		return 0;
 
 	printk(KERN_INFO "Scanning for low memory corruption every %d seconds\n",
-- 
1.7.1.2


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [tip:x86/urgent] x86: Don't check for BIOS corruption in first 64K when there's no need to
  2011-02-25 20:31 [PATCH]: x86: Don't check for BIOS corruption in first 64K when there's no need to Naga Chumbalkar
@ 2011-03-09 11:22 ` tip-bot for Naga Chumbalkar
  2011-03-09 15:40 ` tip-bot for Naga Chumbalkar
  1 sibling, 0 replies; 3+ messages in thread
From: tip-bot for Naga Chumbalkar @ 2011-03-09 11:22 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: linux-kernel, hpa, mingo, stable, nagananda.chumbalkar, tglx, mingo

Commit-ID:  acc45cf678528c8ebe20e9bb8b51c2ea1022e6d3
Gitweb:     http://git.kernel.org/tip/acc45cf678528c8ebe20e9bb8b51c2ea1022e6d3
Author:     Naga Chumbalkar <nagananda.chumbalkar@hp.com>
AuthorDate: Fri, 25 Feb 2011 20:31:55 +0000
Committer:  Ingo Molnar <mingo@elte.hu>
CommitDate: Wed, 9 Mar 2011 10:34:21 +0100

x86: Don't check for BIOS corruption in first 64K when there's no need to

Due to commit 781c5a67f152c17c3e4a9ed9647f8c0be6ea5ae9 it is
likely that the number of areas to scan for BIOS corruption is 0
 -- especially when the first 64K is already reserved
(X86_RESERVE_LOW is 64K by default).

If that's the case then don't set up the scan.

Signed-off-by: Naga Chumbalkar <nagananda.chumbalkar@hp.com>
Cc: <stable@kernel.org>
LKML-Reference: <20110225202838.2229.71011.sendpatchset@nchumbalkar.americas.hpqcorp.net>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
 arch/x86/kernel/check.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/x86/kernel/check.c b/arch/x86/kernel/check.c
index 13a3891..bfd59ea 100644
--- a/arch/x86/kernel/check.c
+++ b/arch/x86/kernel/check.c
@@ -106,8 +106,8 @@ void __init setup_bios_corruption_check(void)
 		addr += size;
 	}
 
-	printk(KERN_INFO "Scanning %d areas for low memory corruption\n",
-	       num_scan_areas);
+	if (num_scan_areas)
+		printk(KERN_INFO "Scanning %d areas for low memory " "corruption\n", num_scan_areas);
 }
 
 
@@ -143,12 +143,12 @@ static void check_corruption(struct work_struct *dummy)
 {
 	check_for_bios_corruption();
 	schedule_delayed_work(&bios_check_work,
-		round_jiffies_relative(corruption_check_period*HZ)); 
+		round_jiffies_relative(corruption_check_period*HZ));
 }
 
 static int start_periodic_check_for_corruption(void)
 {
-	if (!memory_corruption_check || corruption_check_period == 0)
+	if (!num_scan_areas || !memory_corruption_check || corruption_check_period == 0)
 		return 0;
 
 	printk(KERN_INFO "Scanning for low memory corruption every %d seconds\n",

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [tip:x86/urgent] x86: Don't check for BIOS corruption in first 64K when there's no need to
  2011-02-25 20:31 [PATCH]: x86: Don't check for BIOS corruption in first 64K when there's no need to Naga Chumbalkar
  2011-03-09 11:22 ` [tip:x86/urgent] " tip-bot for Naga Chumbalkar
@ 2011-03-09 15:40 ` tip-bot for Naga Chumbalkar
  1 sibling, 0 replies; 3+ messages in thread
From: tip-bot for Naga Chumbalkar @ 2011-03-09 15:40 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: linux-kernel, hpa, mingo, stable, nagananda.chumbalkar, tglx, mingo

Commit-ID:  a7bd1dafdcc13ec7add4aafc927eb5e3a8d597e6
Gitweb:     http://git.kernel.org/tip/a7bd1dafdcc13ec7add4aafc927eb5e3a8d597e6
Author:     Naga Chumbalkar <nagananda.chumbalkar@hp.com>
AuthorDate: Fri, 25 Feb 2011 20:31:55 +0000
Committer:  Ingo Molnar <mingo@elte.hu>
CommitDate: Wed, 9 Mar 2011 16:36:41 +0100

x86: Don't check for BIOS corruption in first 64K when there's no need to

Due to commit 781c5a67f152c17c3e4a9ed9647f8c0be6ea5ae9 it is
likely that the number of areas to scan for BIOS corruption is 0
 -- especially when the first 64K is already reserved
(X86_RESERVE_LOW is 64K by default).

If that's the case then don't set up the scan.

Signed-off-by: Naga Chumbalkar <nagananda.chumbalkar@hp.com>
Cc: <stable@kernel.org>
LKML-Reference: <20110225202838.2229.71011.sendpatchset@nchumbalkar.americas.hpqcorp.net>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
 arch/x86/kernel/check.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/x86/kernel/check.c b/arch/x86/kernel/check.c
index 13a3891..452932d 100644
--- a/arch/x86/kernel/check.c
+++ b/arch/x86/kernel/check.c
@@ -106,8 +106,8 @@ void __init setup_bios_corruption_check(void)
 		addr += size;
 	}
 
-	printk(KERN_INFO "Scanning %d areas for low memory corruption\n",
-	       num_scan_areas);
+	if (num_scan_areas)
+		printk(KERN_INFO "Scanning %d areas for low memory corruption\n", num_scan_areas);
 }
 
 
@@ -143,12 +143,12 @@ static void check_corruption(struct work_struct *dummy)
 {
 	check_for_bios_corruption();
 	schedule_delayed_work(&bios_check_work,
-		round_jiffies_relative(corruption_check_period*HZ)); 
+		round_jiffies_relative(corruption_check_period*HZ));
 }
 
 static int start_periodic_check_for_corruption(void)
 {
-	if (!memory_corruption_check || corruption_check_period == 0)
+	if (!num_scan_areas || !memory_corruption_check || corruption_check_period == 0)
 		return 0;
 
 	printk(KERN_INFO "Scanning for low memory corruption every %d seconds\n",

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-03-09 15:40 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-02-25 20:31 [PATCH]: x86: Don't check for BIOS corruption in first 64K when there's no need to Naga Chumbalkar
2011-03-09 11:22 ` [tip:x86/urgent] " tip-bot for Naga Chumbalkar
2011-03-09 15:40 ` tip-bot for Naga Chumbalkar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome