aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2011-10-31 20:11:33 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-10-31 20:30:54 -0400
commitb9075fa968a0a4347aef35e235e2995c0e57dddd (patch)
treecf9f9716784e790d8a43339653256d9cf9178ff3 /fs
parentae29bc92da01a2e9d278a9a58c3b307d41cc0254 (diff)
treewide: use __printf not __attribute__((format(printf,...)))
Standardize the style for compiler based printf format verification. Standardized the location of __printf too. Done via script and a little typing. $ grep -rPl --include=*.[ch] -w "__attribute__" * | \ grep -vP "^(tools|scripts|include/linux/compiler-gcc.h)" | \ xargs perl -n -i -e 'local $/; while (<>) { s/\b__attribute__\s*\(\s*\(\s*format\s*\(\s*printf\s*,\s*(.+)\s*,\s*(.+)\s*\)\s*\)\s*\)/__printf($1, $2)/g ; print; }' [akpm@linux-foundation.org: revert arch bits] Signed-off-by: Joe Perches <joe@perches.com> Cc: "Kirill A. Shutemov" <kirill@shutemov.name> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs')
-rw-r--r--fs/ecryptfs/ecryptfs_kernel.h2
-rw-r--r--fs/ext2/ext2.h8
-rw-r--r--fs/ext4/ext4.h44
-rw-r--r--fs/fat/fat.h9
-rw-r--r--fs/gfs2/glock.h2
-rw-r--r--fs/hpfs/hpfs_fn.h4
-rw-r--r--fs/nilfs2/nilfs.h8
-rw-r--r--fs/ntfs/debug.h15
-rw-r--r--fs/ocfs2/super.h14
-rw-r--r--fs/partitions/ldm.c16
-rw-r--r--fs/udf/udfdecl.h4
-rw-r--r--fs/ufs/ufs.h9
-rw-r--r--fs/xfs/xfs_message.h42
13 files changed, 90 insertions, 87 deletions
diff --git a/fs/ecryptfs/ecryptfs_kernel.h b/fs/ecryptfs/ecryptfs_kernel.h
index b36c5572b3f3..54481a3b2c79 100644
--- a/fs/ecryptfs/ecryptfs_kernel.h
+++ b/fs/ecryptfs/ecryptfs_kernel.h
@@ -514,7 +514,7 @@ ecryptfs_set_dentry_lower_mnt(struct dentry *dentry, struct vfsmount *lower_mnt)
514 514
515#define ecryptfs_printk(type, fmt, arg...) \ 515#define ecryptfs_printk(type, fmt, arg...) \
516 __ecryptfs_printk(type "%s: " fmt, __func__, ## arg); 516 __ecryptfs_printk(type "%s: " fmt, __func__, ## arg);
517__attribute__ ((format(printf, 1, 2))) 517__printf(1, 2)
518void __ecryptfs_printk(const char *fmt, ...); 518void __ecryptfs_printk(const char *fmt, ...);
519 519
520extern const struct file_operations ecryptfs_main_fops; 520extern const struct file_operations ecryptfs_main_fops;
diff --git a/fs/ext2/ext2.h b/fs/ext2/ext2.h
index af9fc89b1b2d..9a4e5e206d08 100644
--- a/fs/ext2/ext2.h
+++ b/fs/ext2/ext2.h
@@ -135,10 +135,10 @@ extern long ext2_compat_ioctl(struct file *, unsigned int, unsigned long);
135struct dentry *ext2_get_parent(struct dentry *child); 135struct dentry *ext2_get_parent(struct dentry *child);
136 136
137/* super.c */ 137/* super.c */
138extern void ext2_error (struct super_block *, const char *, const char *, ...) 138extern __printf(3, 4)
139 __attribute__ ((format (printf, 3, 4))); 139void ext2_error(struct super_block *, const char *, const char *, ...);
140extern void ext2_msg(struct super_block *, const char *, const char *, ...) 140extern __printf(3, 4)
141 __attribute__ ((format (printf, 3, 4))); 141void ext2_msg(struct super_block *, const char *, const char *, ...);
142extern void ext2_update_dynamic_rev (struct super_block *sb); 142extern void ext2_update_dynamic_rev (struct super_block *sb);
143extern void ext2_write_super (struct super_block *); 143extern void ext2_write_super (struct super_block *);
144 144
diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h
index b7d7bd0f066e..cec3145e532c 100644
--- a/fs/ext4/ext4.h
+++ b/fs/ext4/ext4.h
@@ -1878,40 +1878,40 @@ extern int ext4_group_extend(struct super_block *sb,
1878extern void *ext4_kvmalloc(size_t size, gfp_t flags); 1878extern void *ext4_kvmalloc(size_t size, gfp_t flags);
1879extern void *ext4_kvzalloc(size_t size, gfp_t flags); 1879extern void *ext4_kvzalloc(size_t size, gfp_t flags);
1880extern void ext4_kvfree(void *ptr); 1880extern void ext4_kvfree(void *ptr);
1881extern void __ext4_error(struct super_block *, const char *, unsigned int, 1881extern __printf(4, 5)
1882 const char *, ...) 1882void __ext4_error(struct super_block *, const char *, unsigned int,
1883 __attribute__ ((format (printf, 4, 5))); 1883 const char *, ...);
1884#define ext4_error(sb, message...) __ext4_error(sb, __func__, \ 1884#define ext4_error(sb, message...) __ext4_error(sb, __func__, \
1885 __LINE__, ## message) 1885 __LINE__, ## message)
1886extern void ext4_error_inode(struct inode *, const char *, unsigned int, 1886extern __printf(5, 6)
1887 ext4_fsblk_t, const char *, ...) 1887void ext4_error_inode(struct inode *, const char *, unsigned int, ext4_fsblk_t,
1888 __attribute__ ((format (printf, 5, 6))); 1888 const char *, ...);
1889extern void ext4_error_file(struct file *, const char *, unsigned int, 1889extern __printf(5, 6)
1890 ext4_fsblk_t, const char *, ...) 1890void ext4_error_file(struct file *, const char *, unsigned int, ext4_fsblk_t,
1891 __attribute__ ((format (printf, 5, 6))); 1891 const char *, ...);
1892extern void __ext4_std_error(struct super_block *, const char *, 1892extern void __ext4_std_error(struct super_block *, const char *,
1893 unsigned int, int); 1893 unsigned int, int);
1894extern void __ext4_abort(struct super_block *, const char *, unsigned int, 1894extern __printf(4, 5)
1895 const char *, ...) 1895void __ext4_abort(struct super_block *, const char *, unsigned int,
1896 __attribute__ ((format (printf, 4, 5))); 1896 const char *, ...);
1897#define ext4_abort(sb, message...) __ext4_abort(sb, __func__, \ 1897#define ext4_abort(sb, message...) __ext4_abort(sb, __func__, \
1898 __LINE__, ## message) 1898 __LINE__, ## message)
1899extern void __ext4_warning(struct super_block *, const char *, unsigned int, 1899extern __printf(4, 5)
1900 const char *, ...) 1900void __ext4_warning(struct super_block *, const char *, unsigned int,
1901 __attribute__ ((format (printf, 4, 5))); 1901 const char *, ...);
1902#define ext4_warning(sb, message...) __ext4_warning(sb, __func__, \ 1902#define ext4_warning(sb, message...) __ext4_warning(sb, __func__, \
1903 __LINE__, ## message) 1903 __LINE__, ## message)
1904extern void ext4_msg(struct super_block *, const char *, const char *, ...) 1904extern __printf(3, 4)
1905 __attribute__ ((format (printf, 3, 4))); 1905void ext4_msg(struct super_block *, const char *, const char *, ...);
1906extern void __dump_mmp_msg(struct super_block *, struct mmp_struct *mmp, 1906extern void __dump_mmp_msg(struct super_block *, struct mmp_struct *mmp,
1907 const char *, unsigned int, const char *); 1907 const char *, unsigned int, const char *);
1908#define dump_mmp_msg(sb, mmp, msg) __dump_mmp_msg(sb, mmp, __func__, \ 1908#define dump_mmp_msg(sb, mmp, msg) __dump_mmp_msg(sb, mmp, __func__, \
1909 __LINE__, msg) 1909 __LINE__, msg)
1910extern void __ext4_grp_locked_error(const char *, unsigned int, \ 1910extern __printf(7, 8)
1911 struct super_block *, ext4_group_t, \ 1911void __ext4_grp_locked_error(const char *, unsigned int,
1912 unsigned long, ext4_fsblk_t, \ 1912 struct super_block *, ext4_group_t,
1913 const char *, ...) 1913 unsigned long, ext4_fsblk_t,
1914 __attribute__ ((format (printf, 7, 8))); 1914 const char *, ...);
1915#define ext4_grp_locked_error(sb, grp, message...) \ 1915#define ext4_grp_locked_error(sb, grp, message...) \
1916 __ext4_grp_locked_error(__func__, __LINE__, (sb), (grp), ## message) 1916 __ext4_grp_locked_error(__func__, __LINE__, (sb), (grp), ## message)
1917extern void ext4_update_dynamic_rev(struct super_block *sb); 1917extern void ext4_update_dynamic_rev(struct super_block *sb);
diff --git a/fs/fat/fat.h b/fs/fat/fat.h
index a5d3853822e0..1510a4d51990 100644
--- a/fs/fat/fat.h
+++ b/fs/fat/fat.h
@@ -326,15 +326,14 @@ extern int fat_fill_super(struct super_block *sb, void *data, int silent,
326extern int fat_flush_inodes(struct super_block *sb, struct inode *i1, 326extern int fat_flush_inodes(struct super_block *sb, struct inode *i1,
327 struct inode *i2); 327 struct inode *i2);
328/* fat/misc.c */ 328/* fat/misc.c */
329extern void 329extern __printf(3, 4) __cold
330__fat_fs_error(struct super_block *sb, int report, const char *fmt, ...) 330void __fat_fs_error(struct super_block *sb, int report, const char *fmt, ...);
331 __attribute__ ((format (printf, 3, 4))) __cold;
332#define fat_fs_error(sb, fmt, args...) \ 331#define fat_fs_error(sb, fmt, args...) \
333 __fat_fs_error(sb, 1, fmt , ## args) 332 __fat_fs_error(sb, 1, fmt , ## args)
334#define fat_fs_error_ratelimit(sb, fmt, args...) \ 333#define fat_fs_error_ratelimit(sb, fmt, args...) \
335 __fat_fs_error(sb, __ratelimit(&MSDOS_SB(sb)->ratelimit), fmt , ## args) 334 __fat_fs_error(sb, __ratelimit(&MSDOS_SB(sb)->ratelimit), fmt , ## args)
336void fat_msg(struct super_block *sb, const char *level, const char *fmt, ...) 335__printf(3, 4) __cold
337 __attribute__ ((format (printf, 3, 4))) __cold; 336void fat_msg(struct super_block *sb, const char *level, const char *fmt, ...);
338extern int fat_clusters_flush(struct super_block *sb); 337extern int fat_clusters_flush(struct super_block *sb);
339extern int fat_chain_add(struct inode *inode, int new_dclus, int nr_cluster); 338extern int fat_chain_add(struct inode *inode, int new_dclus, int nr_cluster);
340extern void fat_time_fat2unix(struct msdos_sb_info *sbi, struct timespec *ts, 339extern void fat_time_fat2unix(struct msdos_sb_info *sbi, struct timespec *ts,
diff --git a/fs/gfs2/glock.h b/fs/gfs2/glock.h
index 66707118af25..2553b858a72e 100644
--- a/fs/gfs2/glock.h
+++ b/fs/gfs2/glock.h
@@ -201,7 +201,7 @@ int gfs2_glock_nq_m(unsigned int num_gh, struct gfs2_holder *ghs);
201void gfs2_glock_dq_m(unsigned int num_gh, struct gfs2_holder *ghs); 201void gfs2_glock_dq_m(unsigned int num_gh, struct gfs2_holder *ghs);
202void gfs2_glock_dq_uninit_m(unsigned int num_gh, struct gfs2_holder *ghs); 202void gfs2_glock_dq_uninit_m(unsigned int num_gh, struct gfs2_holder *ghs);
203 203
204__attribute__ ((format(printf, 2, 3))) 204__printf(2, 3)
205void gfs2_print_dbg(struct seq_file *seq, const char *fmt, ...); 205void gfs2_print_dbg(struct seq_file *seq, const char *fmt, ...);
206 206
207/** 207/**
diff --git a/fs/hpfs/hpfs_fn.h b/fs/hpfs/hpfs_fn.h
index 331b5e234ef3..de946170ebb1 100644
--- a/fs/hpfs/hpfs_fn.h
+++ b/fs/hpfs/hpfs_fn.h
@@ -311,8 +311,8 @@ static inline struct hpfs_sb_info *hpfs_sb(struct super_block *sb)
311 311
312/* super.c */ 312/* super.c */
313 313
314void hpfs_error(struct super_block *, const char *, ...) 314__printf(2, 3)
315 __attribute__((format (printf, 2, 3))); 315void hpfs_error(struct super_block *, const char *, ...);
316int hpfs_stop_cycles(struct super_block *, int, int *, int *, char *); 316int hpfs_stop_cycles(struct super_block *, int, int *, int *, char *);
317unsigned hpfs_count_one_bitmap(struct super_block *, secno); 317unsigned hpfs_count_one_bitmap(struct super_block *, secno);
318 318
diff --git a/fs/nilfs2/nilfs.h b/fs/nilfs2/nilfs.h
index 255d5e1c03b7..3777d138f895 100644
--- a/fs/nilfs2/nilfs.h
+++ b/fs/nilfs2/nilfs.h
@@ -276,10 +276,10 @@ int nilfs_fiemap(struct inode *inode, struct fiemap_extent_info *fieinfo,
276/* super.c */ 276/* super.c */
277extern struct inode *nilfs_alloc_inode(struct super_block *); 277extern struct inode *nilfs_alloc_inode(struct super_block *);
278extern void nilfs_destroy_inode(struct inode *); 278extern void nilfs_destroy_inode(struct inode *);
279extern void nilfs_error(struct super_block *, const char *, const char *, ...) 279extern __printf(3, 4)
280 __attribute__ ((format (printf, 3, 4))); 280void nilfs_error(struct super_block *, const char *, const char *, ...);
281extern void nilfs_warning(struct super_block *, const char *, const char *, ...) 281extern __printf(3, 4)
282 __attribute__ ((format (printf, 3, 4))); 282void nilfs_warning(struct super_block *, const char *, const char *, ...);
283extern struct nilfs_super_block * 283extern struct nilfs_super_block *
284nilfs_read_super_block(struct super_block *, u64, int, struct buffer_head **); 284nilfs_read_super_block(struct super_block *, u64, int, struct buffer_head **);
285extern int nilfs_store_magic_and_option(struct super_block *, 285extern int nilfs_store_magic_and_option(struct super_block *,
diff --git a/fs/ntfs/debug.h b/fs/ntfs/debug.h
index 2142b1c68b61..53c27eaf2307 100644
--- a/fs/ntfs/debug.h
+++ b/fs/ntfs/debug.h
@@ -30,8 +30,9 @@
30 30
31extern int debug_msgs; 31extern int debug_msgs;
32 32
33extern void __ntfs_debug(const char *file, int line, const char *function, 33extern __printf(4, 5)
34 const char *format, ...) __attribute__ ((format (printf, 4, 5))); 34void __ntfs_debug(const char *file, int line, const char *function,
35 const char *format, ...);
35/** 36/**
36 * ntfs_debug - write a debug level message to syslog 37 * ntfs_debug - write a debug level message to syslog
37 * @f: a printf format string containing the message 38 * @f: a printf format string containing the message
@@ -52,12 +53,14 @@ extern void ntfs_debug_dump_runlist(const runlist_element *rl);
52 53
53#endif /* !DEBUG */ 54#endif /* !DEBUG */
54 55
55extern void __ntfs_warning(const char *function, const struct super_block *sb, 56extern __printf(3, 4)
56 const char *fmt, ...) __attribute__ ((format (printf, 3, 4))); 57void __ntfs_warning(const char *function, const struct super_block *sb,
58 const char *fmt, ...);
57#define ntfs_warning(sb, f, a...) __ntfs_warning(__func__, sb, f, ##a) 59#define ntfs_warning(sb, f, a...) __ntfs_warning(__func__, sb, f, ##a)
58 60
59extern void __ntfs_error(const char *function, const struct super_block *sb, 61extern __printf(3, 4)
60 const char *fmt, ...) __attribute__ ((format (printf, 3, 4))); 62void __ntfs_error(const char *function, const struct super_block *sb,
63 const char *fmt, ...);
61#define ntfs_error(sb, f, a...) __ntfs_error(__func__, sb, f, ##a) 64#define ntfs_error(sb, f, a...) __ntfs_error(__func__, sb, f, ##a)
62 65
63#endif /* _LINUX_NTFS_DEBUG_H */ 66#endif /* _LINUX_NTFS_DEBUG_H */
diff --git a/fs/ocfs2/super.h b/fs/ocfs2/super.h
index 40c7de084c10..74ff74cf78fe 100644
--- a/fs/ocfs2/super.h
+++ b/fs/ocfs2/super.h
@@ -31,17 +31,15 @@ extern struct workqueue_struct *ocfs2_wq;
31int ocfs2_publish_get_mount_state(struct ocfs2_super *osb, 31int ocfs2_publish_get_mount_state(struct ocfs2_super *osb,
32 int node_num); 32 int node_num);
33 33
34void __ocfs2_error(struct super_block *sb, 34__printf(3, 4)
35 const char *function, 35void __ocfs2_error(struct super_block *sb, const char *function,
36 const char *fmt, ...) 36 const char *fmt, ...);
37 __attribute__ ((format (printf, 3, 4)));
38 37
39#define ocfs2_error(sb, fmt, args...) __ocfs2_error(sb, __PRETTY_FUNCTION__, fmt, ##args) 38#define ocfs2_error(sb, fmt, args...) __ocfs2_error(sb, __PRETTY_FUNCTION__, fmt, ##args)
40 39
41void __ocfs2_abort(struct super_block *sb, 40__printf(3, 4)
42 const char *function, 41void __ocfs2_abort(struct super_block *sb, const char *function,
43 const char *fmt, ...) 42 const char *fmt, ...);
44 __attribute__ ((format (printf, 3, 4)));
45 43
46#define ocfs2_abort(sb, fmt, args...) __ocfs2_abort(sb, __PRETTY_FUNCTION__, fmt, ##args) 44#define ocfs2_abort(sb, fmt, args...) __ocfs2_abort(sb, __PRETTY_FUNCTION__, fmt, ##args)
47 45
diff --git a/fs/partitions/ldm.c b/fs/partitions/ldm.c
index af9fdf046769..bd8ae788f689 100644
--- a/fs/partitions/ldm.c
+++ b/fs/partitions/ldm.c
@@ -49,18 +49,20 @@
49#define ldm_error(f, a...) _ldm_printk (KERN_ERR, __func__, f, ##a) 49#define ldm_error(f, a...) _ldm_printk (KERN_ERR, __func__, f, ##a)
50#define ldm_info(f, a...) _ldm_printk (KERN_INFO, __func__, f, ##a) 50#define ldm_info(f, a...) _ldm_printk (KERN_INFO, __func__, f, ##a)
51 51
52__attribute__ ((format (printf, 3, 4))) 52static __printf(3, 4)
53static void _ldm_printk (const char *level, const char *function, 53void _ldm_printk(const char *level, const char *function, const char *fmt, ...)
54 const char *fmt, ...)
55{ 54{
56 static char buf[128]; 55 struct va_format vaf;
57 va_list args; 56 va_list args;
58 57
59 va_start (args, fmt); 58 va_start (args, fmt);
60 vsnprintf (buf, sizeof (buf), fmt, args);
61 va_end (args);
62 59
63 printk ("%s%s(): %s\n", level, function, buf); 60 vaf.fmt = fmt;
61 vaf.va = &args;
62
63 printk("%s%s(): %pV\n", level, function, &vaf);
64
65 va_end(args);
64} 66}
65 67
66/** 68/**
diff --git a/fs/udf/udfdecl.h b/fs/udf/udfdecl.h
index dbd52d4b5eed..dc8a8dcc5ae1 100644
--- a/fs/udf/udfdecl.h
+++ b/fs/udf/udfdecl.h
@@ -112,8 +112,8 @@ struct extent_position {
112 112
113/* super.c */ 113/* super.c */
114 114
115__attribute__((format(printf, 3, 4))) 115extern __printf(3, 4) void udf_warning(struct super_block *, const char *,
116extern void udf_warning(struct super_block *, const char *, const char *, ...); 116 const char *, ...);
117static inline void udf_updated_lvid(struct super_block *sb) 117static inline void udf_updated_lvid(struct super_block *sb)
118{ 118{
119 struct buffer_head *bh = UDF_SB(sb)->s_lvid_bh; 119 struct buffer_head *bh = UDF_SB(sb)->s_lvid_bh;
diff --git a/fs/ufs/ufs.h b/fs/ufs/ufs.h
index 5be2755dd715..c26f2bcec264 100644
--- a/fs/ufs/ufs.h
+++ b/fs/ufs/ufs.h
@@ -117,9 +117,12 @@ extern int ufs_getfrag_block (struct inode *inode, sector_t fragment, struct buf
117extern const struct file_operations ufs_dir_operations; 117extern const struct file_operations ufs_dir_operations;
118 118
119/* super.c */ 119/* super.c */
120extern void ufs_warning (struct super_block *, const char *, const char *, ...) __attribute__ ((format (printf, 3, 4))); 120extern __printf(3, 4)
121extern void ufs_error (struct super_block *, const char *, const char *, ...) __attribute__ ((format (printf, 3, 4))); 121void ufs_warning(struct super_block *, const char *, const char *, ...);
122extern void ufs_panic (struct super_block *, const char *, const char *, ...) __attribute__ ((format (printf, 3, 4))); 122extern __printf(3, 4)
123void ufs_error(struct super_block *, const char *, const char *, ...);
124extern __printf(3, 4)
125void ufs_panic(struct super_block *, const char *, const char *, ...);
123 126
124/* symlink.c */ 127/* symlink.c */
125extern const struct inode_operations ufs_fast_symlink_inode_operations; 128extern const struct inode_operations ufs_fast_symlink_inode_operations;
diff --git a/fs/xfs/xfs_message.h b/fs/xfs/xfs_message.h
index 7fb7ea007672..56dc0c17f16a 100644
--- a/fs/xfs/xfs_message.h
+++ b/fs/xfs/xfs_message.h
@@ -3,31 +3,29 @@
3 3
4struct xfs_mount; 4struct xfs_mount;
5 5
6extern void xfs_emerg(const struct xfs_mount *mp, const char *fmt, ...) 6extern __printf(2, 3)
7 __attribute__ ((format (printf, 2, 3))); 7void xfs_emerg(const struct xfs_mount *mp, const char *fmt, ...);
8extern void xfs_alert(const struct xfs_mount *mp, const char *fmt, ...) 8extern __printf(2, 3)
9 __attribute__ ((format (printf, 2, 3))); 9void xfs_alert(const struct xfs_mount *mp, const char *fmt, ...);
10extern void xfs_alert_tag(const struct xfs_mount *mp, int tag, 10extern __printf(3, 4)
11 const char *fmt, ...) 11void xfs_alert_tag(const struct xfs_mount *mp, int tag, const char *fmt, ...);
12 __attribute__ ((format (printf, 3, 4))); 12extern __printf(2, 3)
13extern void xfs_crit(const struct xfs_mount *mp, const char *fmt, ...) 13void xfs_crit(const struct xfs_mount *mp, const char *fmt, ...);
14 __attribute__ ((format (printf, 2, 3))); 14extern __printf(2, 3)
15extern void xfs_err(const struct xfs_mount *mp, const char *fmt, ...) 15void xfs_err(const struct xfs_mount *mp, const char *fmt, ...);
16 __attribute__ ((format (printf, 2, 3))); 16extern __printf(2, 3)
17extern void xfs_warn(const struct xfs_mount *mp, const char *fmt, ...) 17void xfs_warn(const struct xfs_mount *mp, const char *fmt, ...);
18 __attribute__ ((format (printf, 2, 3))); 18extern __printf(2, 3)
19extern void xfs_notice(const struct xfs_mount *mp, const char *fmt, ...) 19void xfs_notice(const struct xfs_mount *mp, const char *fmt, ...);
20 __attribute__ ((format (printf, 2, 3))); 20extern __printf(2, 3)
21extern void xfs_info(const struct xfs_mount *mp, const char *fmt, ...) 21void xfs_info(const struct xfs_mount *mp, const char *fmt, ...);
22 __attribute__ ((format (printf, 2, 3)));
23 22
24#ifdef DEBUG 23#ifdef DEBUG
25extern void xfs_debug(const struct xfs_mount *mp, const char *fmt, ...) 24extern __printf(2, 3)
26 __attribute__ ((format (printf, 2, 3))); 25void xfs_debug(const struct xfs_mount *mp, const char *fmt, ...);
27#else 26#else
28static inline void 27static inline __printf(2, 3)
29__attribute__ ((format (printf, 2, 3))) 28void xfs_debug(const struct xfs_mount *mp, const char *fmt, ...)
30xfs_debug(const struct xfs_mount *mp, const char *fmt, ...)
31{ 29{
32} 30}
33#endif 31#endif