lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20090306001930.GA5881@sgi.com>
Date:	Thu, 5 Mar 2009 18:19:30 -0600
From:	Russ Anderson <rja@....com>
To:	linux-kernel@...r.kernel.org
Subject: [PATCH BUGFIX] x86: Prevent /sys/firmware/sgi_uv from being created on non-uv systems

/sys/firmware/sgi_uv should only be created on uv systems.

Signed-off-by: Russ Anderson <rja@....com>

---
 arch/x86/kernel/uv_sysfs.c |    4 ++++
 1 file changed, 4 insertions(+)

Index: linux/arch/x86/kernel/uv_sysfs.c
===================================================================
--- linux.orig/arch/x86/kernel/uv_sysfs.c	2009-03-05 14:22:40.000000000 -0600
+++ linux/arch/x86/kernel/uv_sysfs.c	2009-03-05 14:59:16.000000000 -0600
@@ -21,6 +21,7 @@
 
 #include <linux/sysdev.h>
 #include <asm/uv/bios.h>
+#include <asm/genapic.h>
 
 struct kobject *sgi_uv_kobj;
 
@@ -46,6 +47,9 @@ static struct kobj_attribute coherence_i
 static int __init sgi_uv_sysfs_init(void)
 {
 	unsigned long ret;
+
+	if (!is_uv_system())
+		return -ENODEV;
 
 	if (!sgi_uv_kobj)
 		sgi_uv_kobj = kobject_create_and_add("sgi_uv", firmware_kobj);
-- 
Russ Anderson, OS RAS/Partitioning Project Lead  
SGI - Silicon Graphics Inc          rja@....com
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ