Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Morton <akpm@osdl.org>2004-02-12 23:46:25 -0800
committerLinus Torvalds <torvalds@home.osdl.org>2004-02-12 23:46:25 -0800
commit74cc3c1aff214f08099804c913f1bd13d7301036 (patch)
tree04978dfeef2497060d1a98c8570c2251395eed57
parentb7e711bad04113ab70e92f2a21974df72b64c17a (diff)
[PATCH] sh: Misc build fixes
From: Paul Mundt <lethal@linux-sh.org> Misc build fixes.. also not horribly exciting.
-rw-r--r--arch/sh/mm/cache-sh3.c5
-rw-r--r--arch/sh/mm/fault.c9
-rw-r--r--include/asm-sh/io_generic.h51
3 files changed, 60 insertions, 5 deletions
diff --git a/arch/sh/mm/cache-sh3.c b/arch/sh/mm/cache-sh3.c
index c3342e1e74da..cb6c0c0c7d56 100644
--- a/arch/sh/mm/cache-sh3.c
+++ b/arch/sh/mm/cache-sh3.c
@@ -1,4 +1,4 @@
-/* $Id: cache-sh3.c,v 1.7 2003/08/28 16:16:09 lethal Exp $
+/* $Id: cache-sh3.c,v 1.8 2004/02/01 16:26:27 lethal Exp $
*
* linux/arch/sh/mm/cache-sh3.c
*
@@ -21,8 +21,7 @@
#include <asm/mmu_context.h>
#include <asm/cacheflush.h>
-static int __init
-detect_cpu_and_cache_system(void)
+int __init detect_cpu_and_cache_system(void)
{
unsigned long addr0, addr1, data0, data1, data2, data3;
diff --git a/arch/sh/mm/fault.c b/arch/sh/mm/fault.c
index 2a83ab51b867..43a9e2689274 100644
--- a/arch/sh/mm/fault.c
+++ b/arch/sh/mm/fault.c
@@ -1,4 +1,4 @@
-/* $Id: fault.c,v 1.13 2003/08/11 11:44:50 lethal Exp $
+/* $Id: fault.c,v 1.14 2004/01/13 05:52:11 kkojima Exp $
*
* linux/arch/sh/mm/fault.c
* Copyright (C) 1999 Niibe Yutaka
@@ -242,7 +242,12 @@ asmlinkage int __do_page_fault(struct pt_regs *regs, unsigned long writeaccess,
* So, we need to flush the entry by ourselves.
*/
- __flush_tlb_page(get_asid(), address&PAGE_MASK);
+ {
+ unsigned long flags;
+ local_irq_save(flags);
+ __flush_tlb_page(get_asid(), address&PAGE_MASK);
+ local_irq_restore(flags);
+ }
#endif
set_pte(pte, entry);
diff --git a/include/asm-sh/io_generic.h b/include/asm-sh/io_generic.h
new file mode 100644
index 000000000000..be14587342f7
--- /dev/null
+++ b/include/asm-sh/io_generic.h
@@ -0,0 +1,51 @@
+/*
+ * include/asm-sh/io_generic.h
+ *
+ * Copyright 2000 Stuart Menefy (stuart.menefy@st.com)
+ *
+ * May be copied or modified under the terms of the GNU General Public
+ * License. See linux/COPYING for more information.
+ *
+ * Generic IO functions
+ */
+
+#ifndef _ASM_SH_IO_GENERIC_H
+#define _ASM_SH_IO_GENERIC_H
+
+extern unsigned long generic_io_base;
+
+extern unsigned char generic_inb(unsigned long port);
+extern unsigned short generic_inw(unsigned long port);
+extern unsigned int generic_inl(unsigned long port);
+
+extern void generic_outb(unsigned char value, unsigned long port);
+extern void generic_outw(unsigned short value, unsigned long port);
+extern void generic_outl(unsigned int value, unsigned long port);
+
+extern unsigned char generic_inb_p(unsigned long port);
+extern unsigned short generic_inw_p(unsigned long port);
+extern unsigned int generic_inl_p(unsigned long port);
+extern void generic_outb_p(unsigned char value, unsigned long port);
+extern void generic_outw_p(unsigned short value, unsigned long port);
+extern void generic_outl_p(unsigned int value, unsigned long port);
+
+extern void generic_insb(unsigned long port, void *addr, unsigned long count);
+extern void generic_insw(unsigned long port, void *addr, unsigned long count);
+extern void generic_insl(unsigned long port, void *addr, unsigned long count);
+extern void generic_outsb(unsigned long port, const void *addr, unsigned long count);
+extern void generic_outsw(unsigned long port, const void *addr, unsigned long count);
+extern void generic_outsl(unsigned long port, const void *addr, unsigned long count);
+
+extern unsigned char generic_readb(unsigned long addr);
+extern unsigned short generic_readw(unsigned long addr);
+extern unsigned int generic_readl(unsigned long addr);
+extern void generic_writeb(unsigned char b, unsigned long addr);
+extern void generic_writew(unsigned short b, unsigned long addr);
+extern void generic_writel(unsigned int b, unsigned long addr);
+
+extern void *generic_ioremap(unsigned long offset, unsigned long size);
+extern void generic_iounmap(void *addr);
+
+extern unsigned long generic_isa_port2addr(unsigned long offset);
+
+#endif /* _ASM_SH_IO_GENERIC_H */