Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/sys add more missing printf attributes.
details: https://anonhg.NetBSD.org/src/rev/86b2a2abd068
branches: trunk
changeset: 771446:86b2a2abd068
user: christos <christos%NetBSD.org@localhost>
date: Sun Nov 20 23:37:00 2011 +0000
description:
add more missing printf attributes.
diffstat:
sys/sys/aio.h | 5 +++--
sys/sys/buf.h | 5 +++--
sys/sys/kernhist.h | 5 +++--
sys/sys/lockdebug.h | 5 +++--
sys/sys/lwp.h | 5 +++--
sys/sys/malloc.h | 5 +++--
sys/sys/mbuf.h | 5 +++--
sys/sys/module.h | 8 +++++---
sys/sys/mqueue.h | 5 +++--
sys/sys/namei.h | 5 +++--
sys/sys/pool.h | 10 ++++++----
sys/sys/sched.h | 5 +++--
sys/sys/sleepq.h | 5 +++--
sys/sys/vmem.h | 11 +++++++----
sys/sys/vnode.h | 8 +++++---
sys/sys/wapbl.h | 5 +++--
16 files changed, 59 insertions(+), 38 deletions(-)
diffs (truncated from 328 to 300 lines):
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/aio.h
--- a/sys/sys/aio.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/aio.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: aio.h,v 1.9 2009/01/11 02:45:55 christos Exp $ */
+/* $NetBSD: aio.h,v 1.10 2011/11/20 23:37:00 christos Exp $ */
/*
* Copyright (c) 2007, Mindaugas Rasiukevicius <rmind at NetBSD org>
@@ -115,7 +115,8 @@
extern u_int aio_listio_max;
/* Prototypes */
-void aio_print_jobs(void (*pr)(const char *, ...));
+void aio_print_jobs(void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
int aio_suspend1(struct lwp *, struct aiocb **, int, struct timespec *);
#endif /* _KERNEL */
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/buf.h
--- a/sys/sys/buf.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/buf.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: buf.h,v 1.116 2011/04/27 09:47:25 hannken Exp $ */
+/* $NetBSD: buf.h,v 1.117 2011/11/20 23:37:00 christos Exp $ */
/*-
* Copyright (c) 1999, 2000, 2007, 2008 The NetBSD Foundation, Inc.
@@ -290,7 +290,8 @@
int buf_drain(int);
int buf_setvalimit(vsize_t);
#if defined(DDB) || defined(DEBUGPRINT)
-void vfs_buf_print(buf_t *, int, void (*)(const char *, ...));
+void vfs_buf_print(buf_t *, int, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
#endif
buf_t *getiobuf(struct vnode *, bool);
void putiobuf(buf_t *);
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/kernhist.h
--- a/sys/sys/kernhist.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/kernhist.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: kernhist.h,v 1.2 2011/06/10 14:59:35 matt Exp $ */
+/* $NetBSD: kernhist.h,v 1.3 2011/11/20 23:37:00 christos Exp $ */
/*
* Copyright (c) 1997 Charles D. Cranor and Washington University.
@@ -189,7 +189,8 @@
}
#if defined(DDB)
-void kernhist_print(void (*)(const char *, ...));
+void kernhist_print(void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
#endif /* DDB */
#endif /* KERNHIST */
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/lockdebug.h
--- a/sys/sys/lockdebug.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/lockdebug.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: lockdebug.h,v 1.11 2009/03/07 21:59:25 ad Exp $ */
+/* $NetBSD: lockdebug.h,v 1.12 2011/11/20 23:37:00 christos Exp $ */
/*-
* Copyright (c) 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -55,7 +55,8 @@
void lockdebug_abort(volatile void *, lockops_t *,
const char *, const char *);
-void lockdebug_lock_print(void *, void (*)(const char *, ...));
+void lockdebug_lock_print(void *, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
#ifdef LOCKDEBUG
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/lwp.h
--- a/sys/sys/lwp.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/lwp.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: lwp.h,v 1.156 2011/10/31 12:18:32 yamt Exp $ */
+/* $NetBSD: lwp.h,v 1.157 2011/11/20 23:37:00 christos Exp $ */
/*-
* Copyright (c) 2001, 2006, 2007, 2008, 2009, 2010
@@ -356,7 +356,8 @@
int lwp_unpark(lwpid_t, const void *);
/* DDB. */
-void lwp_whatis(uintptr_t, void (*)(const char *, ...));
+void lwp_whatis(uintptr_t, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
/*
* Lock an LWP. XXX _MODULE
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/malloc.h
--- a/sys/sys/malloc.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/malloc.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: malloc.h,v 1.107 2010/04/23 19:09:15 rmind Exp $ */
+/* $NetBSD: malloc.h,v 1.108 2011/11/20 23:37:00 christos Exp $ */
/*
* Copyright (c) 1987, 1993
@@ -108,7 +108,8 @@
int debug_free(void *, struct malloc_type *);
void debug_malloc_print(void);
-void debug_malloc_printit(void (*)(const char *, ...), vaddr_t);
+void debug_malloc_printit(void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2)), vaddr_t));
#endif /* MALLOC_DEBUG */
void *kern_realloc(void *, unsigned long, struct malloc_type *, int);
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/mbuf.h
--- a/sys/sys/mbuf.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/mbuf.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: mbuf.h,v 1.146 2011/09/21 18:10:25 christos Exp $ */
+/* $NetBSD: mbuf.h,v 1.147 2011/11/20 23:37:00 christos Exp $ */
/*-
* Copyright (c) 1996, 1997, 1999, 2001, 2007 The NetBSD Foundation, Inc.
@@ -925,7 +925,8 @@
return pktlen;
}
-void m_print(const struct mbuf *, const char *, void (*)(const char *, ...));
+void m_print(const struct mbuf *, const char *, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
#endif /* _KERNEL */
#endif /* !_SYS_MBUF_H_ */
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/module.h
--- a/sys/sys/module.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/module.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: module.h,v 1.28 2011/10/18 12:25:30 jmcneill Exp $ */
+/* $NetBSD: module.h,v 1.29 2011/11/20 23:37:00 christos Exp $ */
/*-
* Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -141,8 +141,10 @@
void module_thread_kick(void);
void module_load_vfs_init(void);
-void module_whatis(uintptr_t, void (*)(const char *, ...));
-void module_print_list(void (*)(const char *, ...));
+void module_whatis(uintptr_t, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
+void module_print_list(void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
#ifdef _MODULE_INTERNAL
extern
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/mqueue.h
--- a/sys/sys/mqueue.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/mqueue.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: mqueue.h,v 1.14 2011/09/27 01:40:32 christos Exp $ */
+/* $NetBSD: mqueue.h,v 1.15 2011/11/20 23:37:00 christos Exp $ */
/*
* Copyright (c) 2007-2009 Mindaugas Rasiukevicius <rmind at NetBSD org>
@@ -109,7 +109,8 @@
} mq_msg_t;
/* Prototypes */
-void mqueue_print_list(void (*pr)(const char *, ...));
+void mqueue_print_list(void (*pr)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
int mq_send1(mqd_t, const char *, size_t, u_int, struct timespec *);
int mq_recv1(mqd_t, void *, size_t, u_int *, struct timespec *, ssize_t *);
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/namei.h
--- a/sys/sys/namei.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/namei.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: namei.h,v 1.77 2011/04/24 18:46:24 rmind Exp $ */
+/* $NetBSD: namei.h,v 1.78 2011/11/20 23:37:00 christos Exp $ */
/*
@@ -271,7 +271,8 @@
void nchreinit(void);
void cache_cpu_init(struct cpu_info *);
void cache_purgevfs(struct mount *);
-void namecache_print(struct vnode *, void (*)(const char *, ...));
+void namecache_print(struct vnode *, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
#endif
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/pool.h
--- a/sys/sys/pool.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/pool.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pool.h,v 1.70 2010/06/03 10:40:17 pooka Exp $ */
+/* $NetBSD: pool.h,v 1.71 2011/11/20 23:37:00 christos Exp $ */
/*-
* Copyright (c) 1997, 1998, 1999, 2000, 2007 The NetBSD Foundation, Inc.
@@ -302,8 +302,9 @@
*/
void pool_print(struct pool *, const char *);
void pool_printit(struct pool *, const char *,
- void (*)(const char *, ...));
-void pool_printall(const char *, void (*)(const char *, ...));
+ void (*)(const char *, ...) __attribute__((__format__(__printf__, 1, 2))));
+void pool_printall(const char *, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
int pool_chk(struct pool *, const char *);
/*
@@ -333,7 +334,8 @@
#define pool_cache_put(pc, o) pool_cache_put_paddr((pc), (o), \
POOL_PADDR_INVALID)
-void pool_whatis(uintptr_t, void (*)(const char *, ...));
+void pool_whatis(uintptr_t, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
#endif /* _KERNEL */
#endif /* _SYS_POOL_H_ */
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/sched.h
--- a/sys/sys/sched.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/sched.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sched.h,v 1.73 2011/08/07 13:33:02 rmind Exp $ */
+/* $NetBSD: sched.h,v 1.74 2011/11/20 23:37:00 christos Exp $ */
/*-
* Copyright (c) 1999, 2000, 2001, 2002, 2007, 2008 The NetBSD Foundation, Inc.
@@ -248,7 +248,8 @@
void sched_setrunnable(struct lwp *);
struct cpu_info *sched_takecpu(struct lwp *);
-void sched_print_runqueue(void (*pr)(const char *, ...));
+void sched_print_runqueue(void (*pr)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
/* Dispatching */
bool kpreempt(uintptr_t);
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/sleepq.h
--- a/sys/sys/sleepq.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/sleepq.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sleepq.h,v 1.19 2010/12/18 01:36:20 rmind Exp $ */
+/* $NetBSD: sleepq.h,v 1.20 2011/11/20 23:37:00 christos Exp $ */
/*-
* Copyright (c) 2002, 2006, 2007, 2008, 2009 The NetBSD Foundation, Inc.
@@ -171,7 +171,8 @@
void turnstile_exit(wchan_t);
void turnstile_block(turnstile_t *, int, wchan_t, syncobj_t *);
void turnstile_wakeup(turnstile_t *, int, int, lwp_t *);
-void turnstile_print(volatile void *, void (*)(const char *, ...));
+void turnstile_print(volatile void *, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
void turnstile_unsleep(lwp_t *, bool);
void turnstile_changepri(lwp_t *, pri_t);
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/vmem.h
--- a/sys/sys/vmem.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/vmem.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vmem.h,v 1.14 2011/09/02 22:25:08 dyoung Exp $ */
+/* $NetBSD: vmem.h,v 1.15 2011/11/20 23:37:00 christos Exp $ */
/*-
* Copyright (c)2006 YAMAMOTO Takashi,
@@ -58,9 +58,12 @@
vmem_size_t vmem_roundup_size(vmem_t *, vmem_size_t);
bool vmem_reap(vmem_t *);
void vmem_rehash_start(void);
-void vmem_whatis(uintptr_t, void (*)(const char *, ...));
-void vmem_print(uintptr_t, const char *, void (*)(const char *, ...));
-void vmem_printall(const char *, void (*)(const char *, ...));
+void vmem_whatis(uintptr_t, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
+void vmem_print(uintptr_t, const char *, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
+void vmem_printall(const char *, void (*)(const char *, ...)
+ __attribute__((__format__(__printf__, 1, 2))));
/* vm_flag_t */
#define VM_SLEEP 0x00000001
diff -r 8b815d102c59 -r 86b2a2abd068 sys/sys/vnode.h
--- a/sys/sys/vnode.h Sun Nov 20 23:01:18 2011 +0000
+++ b/sys/sys/vnode.h Sun Nov 20 23:37:00 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vnode.h,v 1.233 2011/06/27 11:52:24 uch Exp $ */
+/* $NetBSD: vnode.h,v 1.234 2011/11/20 23:37:00 christos Exp $ */
/*-
* Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -618,8 +618,10 @@
int vfs_drainvnodes(long);
void vfs_timestamp(struct timespec *);
#if defined(DDB) || defined(DEBUGPRINT)
Home |
Main Index |
Thread Index |
Old Index