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>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <b9395c2aeb22a47833787494090774f38aa04f58.1280417117.git.siccegge@cs.fau.de>
Date:	Thu, 29 Jul 2010 17:29:12 +0200
From:	Christoph Egger <siccegge@...fau.de>
To:	Jeff Dike <jdike@...toit.com>,
	user-mode-linux-devel@...ts.sourceforge.net,
	linux-kernel@...r.kernel.org
Cc:	vamos-dev@...informatik.uni-erlangen.de
Subject: [PATCH 3/3] Removing dead copy&paste code

In arch/um there's a lot of code that is copied from their original
arch (but out of sync) and contains code blocks that are either dead
because these options disappearedd or because the arch/x86 Kconfig
stuff doesn't reach arch/um.

X86_OOSTORE is a bit tricky because it's in itself seemingly available
on arch/um but depends on MTRR which isn't in arch/um.

Signed-off-by: Christoph Egger <siccegge@...fau.de>
---
 arch/um/sys-i386/asm/archparam.h          |    4 ----
 arch/um/sys-i386/shared/sysdep/system.h   |   11 +----------
 arch/um/sys-ppc/misc.S                    |    6 ------
 arch/um/sys-x86_64/shared/sysdep/system.h |   10 +---------
 4 files changed, 2 insertions(+), 29 deletions(-)

diff --git a/arch/um/sys-i386/asm/archparam.h b/arch/um/sys-i386/asm/archparam.h
index 2a18a88..b2072c9 100644
--- a/arch/um/sys-i386/asm/archparam.h
+++ b/arch/um/sys-i386/asm/archparam.h
@@ -6,11 +6,7 @@
 #ifndef __UM_ARCHPARAM_I386_H
 #define __UM_ARCHPARAM_I386_H
 
-#ifdef CONFIG_X86_PAE
-#define LAST_PKMAP 512
-#else
 #define LAST_PKMAP 1024
-#endif
 
 #endif
 
diff --git a/arch/um/sys-i386/shared/sysdep/system.h b/arch/um/sys-i386/shared/sysdep/system.h
index d1b93c4..be25c95 100644
--- a/arch/um/sys-i386/shared/sysdep/system.h
+++ b/arch/um/sys-i386/shared/sysdep/system.h
@@ -10,12 +10,7 @@
 #include <linux/kernel.h>
 #include <linux/irqflags.h>
 
-/* entries in ARCH_DLINFO: */
-#ifdef CONFIG_IA32_EMULATION
-# define AT_VECTOR_SIZE_ARCH 2
-#else
-# define AT_VECTOR_SIZE_ARCH 1
-#endif
+#define AT_VECTOR_SIZE_ARCH 1
 
 extern unsigned long arch_align_stack(unsigned long sp);
 
@@ -101,11 +96,7 @@ void default_idle(void);
 #else
 # define smp_rmb()	barrier()
 #endif
-#ifdef CONFIG_X86_OOSTORE
-# define smp_wmb() 	wmb()
-#else
 # define smp_wmb()	barrier()
-#endif
 #define smp_read_barrier_depends()	read_barrier_depends()
 #define set_mb(var, value) do { (void)xchg(&var, value); } while (0)
 #else
diff --git a/arch/um/sys-ppc/misc.S b/arch/um/sys-ppc/misc.S
index 1364b7d..962e4af 100644
--- a/arch/um/sys-ppc/misc.S
+++ b/arch/um/sys-ppc/misc.S
@@ -18,15 +18,9 @@
 #include <asm/processor.h>
 #include "ppc_asm.h"
 
-#if defined(CONFIG_4xx) || defined(CONFIG_8xx)
-#define CACHE_LINE_SIZE		16
-#define LG_CACHE_LINE_SIZE	4
-#define MAX_COPY_PREFETCH	1
-#else
 #define CACHE_LINE_SIZE		32
 #define LG_CACHE_LINE_SIZE	5
 #define MAX_COPY_PREFETCH	4
-#endif /* CONFIG_4xx || CONFIG_8xx */
 
 	.text
 
diff --git a/arch/um/sys-x86_64/shared/sysdep/system.h b/arch/um/sys-x86_64/shared/sysdep/system.h
index d1b93c4..511241f 100644
--- a/arch/um/sys-x86_64/shared/sysdep/system.h
+++ b/arch/um/sys-x86_64/shared/sysdep/system.h
@@ -11,11 +11,7 @@
 #include <linux/irqflags.h>
 
 /* entries in ARCH_DLINFO: */
-#ifdef CONFIG_IA32_EMULATION
-# define AT_VECTOR_SIZE_ARCH 2
-#else
-# define AT_VECTOR_SIZE_ARCH 1
-#endif
+#define AT_VECTOR_SIZE_ARCH 1
 
 extern unsigned long arch_align_stack(unsigned long sp);
 
@@ -101,11 +97,7 @@ void default_idle(void);
 #else
 # define smp_rmb()	barrier()
 #endif
-#ifdef CONFIG_X86_OOSTORE
-# define smp_wmb() 	wmb()
-#else
 # define smp_wmb()	barrier()
-#endif
 #define smp_read_barrier_depends()	read_barrier_depends()
 #define set_mb(var, value) do { (void)xchg(&var, value); } while (0)
 #else
-- 
1.7.0.4

--
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