bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] Fix compilation warning implicit function declaration kdbprintf


From: David Höppner
Subject: [PATCH] Fix compilation warning implicit function declaration kdbprintf
Date: Tue, 1 Jan 2013 17:28:48 +0100

Hi,

this is a small patch (also attached) for fix a compilation warning in gnumach.

thanks,
David


Fix compilation warning implicit function declaration
 kdbprintf

When kernel debugger support is requested ipc and vm do not
include the prototype for the debugger function kdbprintf.

* ddb/db_output.h: Add prototype for kdbprintf.
* ipc/ipc_object.c: Add include file ddb/db_output.h
* ipc/ipc_port.c: Likewise.
* ipc/ipc_pset.c: Likewise.
* vm/vm_map.c: Likewise.
* vm/vm_object.c: Likewise.
* vm/vm_resident.c: Likewise.
---
 ddb/db_output.h  |    6 +++---
 ipc/ipc_object.c |    5 +++++
 ipc/ipc_port.c   |    3 +++
 ipc/ipc_pset.c   |    4 ++++
 vm/vm_map.c      |    5 +++++
 vm/vm_object.c   |    4 ++++
 vm/vm_resident.c |    5 +++++
 7 files changed, 29 insertions(+), 3 deletions(-)

diff --git a/ddb/db_output.h b/ddb/db_output.h
index 3203e30..1159c6b 100644
--- a/ddb/db_output.h
+++ b/ddb/db_output.h
@@ -35,6 +35,6 @@
 extern void    db_force_whitespace(void);
 extern int     db_print_position(void);
 extern void    db_end_line(void);
-extern void    db_printf( const char *fmt, ...);
-extern void db_putchar(int c);
-
+extern void    db_printf(const char *fmt, ...);
+extern void    db_putchar(int c);
+extern void    kdbprintf(const char *fmt, ...);
diff --git a/ipc/ipc_object.c b/ipc/ipc_object.c
index 4850fb1..b8cae8f 100644
--- a/ipc/ipc_object.c
+++ b/ipc/ipc_object.c
@@ -49,6 +49,11 @@
 #include <kern/printf.h>
 #include <kern/slab.h>

+#if    MACH_KDB
+#include <ddb/db_output.h>
+#endif /* MACH_KDB */
+
+
 struct kmem_cache ipc_object_caches[IOT_NUMBER];


diff --git a/ipc/ipc_port.c b/ipc/ipc_port.c
index ce0dbeb..8e41c3c 100644
--- a/ipc/ipc_port.c
+++ b/ipc/ipc_port.c
@@ -51,6 +51,9 @@
 #include <ipc/ipc_mqueue.h>
 #include <ipc/ipc_notify.h>

+#if    MACH_KDB
+#include <ddb/db_output.h>
+#endif /* MACH_KDB */


 decl_simple_lock_data(, ipc_port_multiple_lock_data)
diff --git a/ipc/ipc_pset.c b/ipc/ipc_pset.c
index 141cbdb..e2b3c86 100644
--- a/ipc/ipc_pset.c
+++ b/ipc/ipc_pset.c
@@ -46,6 +46,10 @@
 #include <ipc/ipc_right.h>
 #include <ipc/ipc_space.h>

+#if    MACH_KDB
+#include <ddb/db_output.h>
+#endif /* MACH_KDB */
+

 /*
  *     Routine:        ipc_pset_alloc
diff --git a/vm/vm_map.c b/vm/vm_map.c
index 22fa836..47db118 100644
--- a/vm/vm_map.c
+++ b/vm/vm_map.c
@@ -53,6 +53,11 @@
 #include <vm/vm_kern.h>
 #include <ipc/ipc_port.h>

+#if    MACH_KDB
+#include <ddb/db_output.h>
+#endif /* MACH_KDB */
+
+
 /* Forward declarations */
 kern_return_t vm_map_delete(
     vm_map_t   map,
diff --git a/vm/vm_object.c b/vm/vm_object.c
index 7eae3d7..d83c39f 100644
--- a/vm/vm_object.c
+++ b/vm/vm_object.c
@@ -55,6 +55,10 @@
 #include <vm/vm_page.h>
 #include <vm/vm_pageout.h>

+#if    MACH_KDB
+#include <ddb/db_output.h>
+#endif /* MACH_KDB */
+

 void memory_object_release(
        ipc_port_t      pager,
diff --git a/vm/vm_resident.c b/vm/vm_resident.c
index 581a9c4..7cf4fb1 100644
--- a/vm/vm_resident.c
+++ b/vm/vm_resident.c
@@ -58,6 +58,11 @@
 #include <vm/vm_user.h>
 #endif

+#if    MACH_KDB
+#include <ddb/db_output.h>
+#endif /* MACH_KDB */
+
+
 /*
  *     Associated with eacn page of user-allocatable memory is a
  *     page structure.
-- 
1.7.10.4

Attachment: 001-gnumach-kdbprintf.patch
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]