Skip to contentSkip to conversation

x86/io changes for v2.6.34

GIT PULL Ingo Molnar 1 participant 1 message Feb 27, 2010

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

Linus,

Please pull the latest x86-io-for-linus git tree from:

git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git x86-io-for-linus

Thanks,

Ingo

------------------>
Brian Gerst (7):
x86-32: Move XQUAD definitions to numaq.h
x86-32: Remove _local variants of in/out from io_32.h
x86-64: Reorganize io_64.h
x86-64: Use BUILDIO in io_64.h
x86: Clean up mem*io functions.
x86: Simplify flush_write_buffers()
x86: Merge io.h

 arch/x86/boot/compressed/misc.c |   13 +--
 arch/x86/include/asm/io.h       |  155 ++++++++++++++++++++++++++++++-
 arch/x86/include/asm/io_32.h    |  196 ---------------------------------------
 arch/x86/include/asm/io_64.h    |  181 ------------------------------------
 arch/x86/include/asm/numaq.h    |    4 +
 arch/x86/lib/Makefile           |    2 +-
 arch/x86/lib/io_64.c            |   25 -----
 arch/x86/pci/numaq_32.c         |    6 +-
 8 files changed, 162 insertions(+), 420 deletions(-)
 delete mode 100644 arch/x86/include/asm/io_32.h
 delete mode 100644 arch/x86/include/asm/io_64.h
 delete mode 100644 arch/x86/lib/io_64.c
arch/x86/boot/compressed/misc.c +4 -9
index 3b22fe8..88042e8 100644
@@ -19,11 +19,6 @@
 #define _ASM_X86_DESC_H 1
 #endif
 
-#ifdef CONFIG_X86_64
-#define _LINUX_STRING_H_ 1
-#define __LINUX_BITMAP_H 1
-#endif
-
 #include <linux/linkage.h>
 #include <linux/screen_info.h>
 #include <linux/elf.h>
@@ -131,8 +126,8 @@ static void error(char *m);
 static struct boot_params *real_mode;		/* Pointer to real-mode data */
 static int quiet;
 
-static void *memset(void *s, int c, unsigned n);
-void *memcpy(void *dest, const void *src, unsigned n);
+void *memset(void *s, int c, size_t n);
+void *memcpy(void *dest, const void *src, size_t n);
 
 static void __putstr(int, const char *);
 #define putstr(__x)  __putstr(0, __x)
@@ -223,7 +218,7 @@ static void __putstr(int error, const char *s)
 	outb(0xff & (pos >> 1), vidport+1);
 }
 
-static void *memset(void *s, int c, unsigned n)
+void *memset(void *s, int c, size_t n)
 {
 	int i;
 	char *ss = s;
@@ -233,7 +228,7 @@ static void *memset(void *s, int c, unsigned n)
 	return s;
 }
 
-void *memcpy(void *dest, const void *src, unsigned n)
+void *memcpy(void *dest, const void *src, size_t n)
 {
 	int i;
 	const char *s = src;
arch/x86/include/asm/io.h +152 -3

171 lines not on this page · raw message

arch/x86/include/asm/io_32.h deleted +0 -196

196 lines not on this page · raw message

arch/x86/include/asm/io_64.h deleted +0 -181

181 lines not on this page · raw message

arch/x86/include/asm/numaq.h +4 -0
index 9f0a5f5..13370b9 100644
@@ -33,6 +33,10 @@ extern int get_memcfg_numaq(void);
 
 extern void *xquad_portio;
 
+#define XQUAD_PORTIO_BASE 0xfe400000
+#define XQUAD_PORTIO_QUAD 0x40000  /* 256k per quad. */
+#define XQUAD_PORT_ADDR(port, quad) (xquad_portio + (XQUAD_PORTIO_QUAD*quad) + port)
+
 /*
  * SYS_CFG_DATA_PRIV_ADDR, struct eachquadmem, and struct sys_cfg_data are the
  */
arch/x86/lib/Makefile +1 -1
index cffd754..fff1427 100644
@@ -34,7 +34,7 @@ ifneq ($(CONFIG_X86_CMPXCHG64),y)
 endif
         lib-$(CONFIG_X86_USE_3DNOW) += mmx_32.o
 else
-        obj-y += io_64.o iomap_copy_64.o
+        obj-y += iomap_copy_64.o
         lib-y += csum-partial_64.o csum-copy_64.o csum-wrappers_64.o
         lib-y += thunk_64.o clear_page_64.o copy_page_64.o
         lib-y += memmove_64.o memset_64.o
arch/x86/lib/io_64.c deleted +0 -25
deleted file mode 100644
index 3f1eb59..0000000
@@ -1,25 +0,0 @@
-#include <linux/string.h>
-#include <linux/module.h>
-#include <asm/io.h>
-
-void __memcpy_toio(unsigned long dst, const void *src, unsigned len)
-{
-	__inline_memcpy((void *)dst, src, len);
-}
-EXPORT_SYMBOL(__memcpy_toio);
-
-void __memcpy_fromio(void *dst, unsigned long src, unsigned len)
-{
-	__inline_memcpy(dst, (const void *)src, len);
-}
-EXPORT_SYMBOL(__memcpy_fromio);
-
-void memset_io(volatile void __iomem *a, int b, size_t c)
-{
-	/*
-	 * TODO: memset can mangle the IO patterns quite a bit.
-	 * perhaps it would be better to use a dumb one:
-	 */
-	memset((void *)a, b, c);
-}
-EXPORT_SYMBOL(memset_io);
arch/x86/pci/numaq_32.c +1 -5
index 8eb295e..8884a1c 100644
@@ -8,9 +8,7 @@
 #include <asm/apic.h>
 #include <asm/mpspec.h>
 #include <asm/pci_x86.h>
-
-#define XQUAD_PORTIO_BASE 0xfe400000
-#define XQUAD_PORTIO_QUAD 0x40000  /* 256k per quad. */
+#include <asm/numaq.h>
 
 #define BUS2QUAD(global) (mp_bus_id_to_node[global])
 
@@ -18,8 +16,6 @@
 
 #define QUADLOCAL2BUS(quad,local) (quad_local_to_mp_bus_id[quad][local])
 
-#define XQUAD_PORT_ADDR(port, quad) (xquad_portio + (XQUAD_PORTIO_QUAD*quad) + port)
-
 #define PCI_CONF1_MQ_ADDRESS(bus, devfn, reg) \
 	(0x80000000 | (BUS2LOCAL(bus) << 16) | (devfn << 8) | (reg & ~3))