[ PATCH 3/7 ] UML - Create arch.h

Previous thread: [ PATCH 6/7 ] UML - Remove user_util.h by Jeff Dike on Thursday, March 22, 2007 - 12:06 pm. (1 message)

Next thread: [ PATCH 2/7 ] UML - Move SIGIO testing to sigio.c by Jeff Dike on Thursday, March 22, 2007 - 12:06 pm. (1 message)
To: Andrew Morton <akpm@...>
Cc: LKML <linux-kernel@...>, uml-devel <user-mode-linux-devel@...>
Date: Thursday, March 22, 2007 - 12:06 pm

This patch moves the declarations of the architecture hooks from
user_util.h to a new header, arch.c, and adds the necessary includes
to files which need those declarations.

Signed-off-by: Jeff Dike <jdike@linux.intel.com>
--
arch/um/include/arch.h | 15 +++++++++++++++
arch/um/include/user_util.h | 4 ----
arch/um/kernel/trap.c | 1 +
arch/um/kernel/um_arch.c | 1 +
4 files changed, 17 insertions(+), 4 deletions(-)

Index: linux-2.6.21-mm/arch/um/include/arch.h
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ linux-2.6.21-mm/arch/um/include/arch.h 2007-03-21 17:29:15.000000000 -0400
@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com)
+ * Licensed under the GPL
+ */
+
+#ifndef __ARCH_H__
+#define __ARCH_H__
+
+#include "sysdep/ptrace.h"
+
+extern void arch_check_bugs(void);
+extern int arch_fixup(unsigned long address, void *sc_ptr);
+extern int arch_handle_signal(int sig, union uml_pt_regs *regs);
+
+#endif
Index: linux-2.6.21-mm/arch/um/kernel/trap.c
===================================================================
--- linux-2.6.21-mm.orig/arch/um/kernel/trap.c 2007-03-21 16:16:43.000000000 -0400
+++ linux-2.6.21-mm/arch/um/kernel/trap.c 2007-03-21 17:29:15.000000000 -0400
@@ -20,6 +20,7 @@
#include "sysdep/sigcontext.h"
#include "user_util.h"
#include "kern_util.h"
+#include "arch.h"
#include "kern.h"
#include "chan_kern.h"
#include "mconsole_kern.h"
Index: linux-2.6.21-mm/arch/um/kernel/um_arch.c
===================================================================
--- linux-2.6.21-mm.orig/arch/um/kernel/um_arch.c 2007-03-21 16:16:43.000000000 -0400
+++ linux-2.6.21-mm/arch/um/kernel/um_arch.c 2007-03-21 17:29:15.000000000 -0400
@@ -28,6 +28,7 @@
#include "asm/current.h"
#include "user_util.h"
#include "kern_util.h"
+#include "arch.h"
#include "kern.h"
#include "mem_user.h"
#include "mem.h"
Index: linux...

Previous thread: [ PATCH 6/7 ] UML - Remove user_util.h by Jeff Dike on Thursday, March 22, 2007 - 12:06 pm. (1 message)

Next thread: [ PATCH 2/7 ] UML - Move SIGIO testing to sigio.c by Jeff Dike on Thursday, March 22, 2007 - 12:06 pm. (1 message)