diff options
author | Joe Perches <joe@perches.com> | 2013-04-30 18:27:55 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-04-30 20:04:05 -0400 |
commit | d614267329f2bee7a082ed8781c581c0f3aaa808 (patch) | |
tree | edade57808a2a2e327daf83991a31a76660b7a41 /fs/hfsplus/attributes.c | |
parent | c2b3e1f76e5c90215bc7f740b376c0220eb8a8e3 (diff) |
hfs/hfsplus: convert printks to pr_<level>
Use a more current logging style.
Add #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
hfsplus now uses "hfsplus: " for all messages.
Coalesce formats.
Prefix debugging messages too.
Signed-off-by: Joe Perches <joe@perches.com>
Cc: Vyacheslav Dubeyko <slava@dubeyko.com>
Cc: Hin-Tak Leung <htl10@users.sourceforge.net>
Cc: Christoph Hellwig <hch@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/hfsplus/attributes.c')
-rw-r--r-- | fs/hfsplus/attributes.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/fs/hfsplus/attributes.c b/fs/hfsplus/attributes.c index 2043b50c5418..0f47890299c4 100644 --- a/fs/hfsplus/attributes.c +++ b/fs/hfsplus/attributes.c | |||
@@ -56,7 +56,7 @@ int hfsplus_attr_build_key(struct super_block *sb, hfsplus_btree_key *key, | |||
56 | if (name) { | 56 | if (name) { |
57 | len = strlen(name); | 57 | len = strlen(name); |
58 | if (len > HFSPLUS_ATTR_MAX_STRLEN) { | 58 | if (len > HFSPLUS_ATTR_MAX_STRLEN) { |
59 | printk(KERN_ERR "hfs: invalid xattr name's length\n"); | 59 | pr_err("invalid xattr name's length\n"); |
60 | return -EINVAL; | 60 | return -EINVAL; |
61 | } | 61 | } |
62 | hfsplus_asc2uni(sb, | 62 | hfsplus_asc2uni(sb, |
@@ -169,7 +169,7 @@ int hfsplus_find_attr(struct super_block *sb, u32 cnid, | |||
169 | hfs_dbg(ATTR_MOD, "find_attr: %s,%d\n", name ? name : NULL, cnid); | 169 | hfs_dbg(ATTR_MOD, "find_attr: %s,%d\n", name ? name : NULL, cnid); |
170 | 170 | ||
171 | if (!HFSPLUS_SB(sb)->attr_tree) { | 171 | if (!HFSPLUS_SB(sb)->attr_tree) { |
172 | printk(KERN_ERR "hfs: attributes file doesn't exist\n"); | 172 | pr_err("attributes file doesn't exist\n"); |
173 | return -EINVAL; | 173 | return -EINVAL; |
174 | } | 174 | } |
175 | 175 | ||
@@ -232,7 +232,7 @@ int hfsplus_create_attr(struct inode *inode, | |||
232 | name ? name : NULL, inode->i_ino); | 232 | name ? name : NULL, inode->i_ino); |
233 | 233 | ||
234 | if (!HFSPLUS_SB(sb)->attr_tree) { | 234 | if (!HFSPLUS_SB(sb)->attr_tree) { |
235 | printk(KERN_ERR "hfs: attributes file doesn't exist\n"); | 235 | pr_err("attributes file doesn't exist\n"); |
236 | return -EINVAL; | 236 | return -EINVAL; |
237 | } | 237 | } |
238 | 238 | ||
@@ -307,10 +307,10 @@ static int __hfsplus_delete_attr(struct inode *inode, u32 cnid, | |||
307 | break; | 307 | break; |
308 | case HFSPLUS_ATTR_FORK_DATA: | 308 | case HFSPLUS_ATTR_FORK_DATA: |
309 | case HFSPLUS_ATTR_EXTENTS: | 309 | case HFSPLUS_ATTR_EXTENTS: |
310 | printk(KERN_ERR "hfs: only inline data xattr are supported\n"); | 310 | pr_err("only inline data xattr are supported\n"); |
311 | return -EOPNOTSUPP; | 311 | return -EOPNOTSUPP; |
312 | default: | 312 | default: |
313 | printk(KERN_ERR "hfs: invalid extended attribute record\n"); | 313 | pr_err("invalid extended attribute record\n"); |
314 | return -ENOENT; | 314 | return -ENOENT; |
315 | } | 315 | } |
316 | 316 | ||
@@ -332,7 +332,7 @@ int hfsplus_delete_attr(struct inode *inode, const char *name) | |||
332 | name ? name : NULL, inode->i_ino); | 332 | name ? name : NULL, inode->i_ino); |
333 | 333 | ||
334 | if (!HFSPLUS_SB(sb)->attr_tree) { | 334 | if (!HFSPLUS_SB(sb)->attr_tree) { |
335 | printk(KERN_ERR "hfs: attributes file doesn't exist\n"); | 335 | pr_err("attributes file doesn't exist\n"); |
336 | return -EINVAL; | 336 | return -EINVAL; |
337 | } | 337 | } |
338 | 338 | ||
@@ -346,7 +346,7 @@ int hfsplus_delete_attr(struct inode *inode, const char *name) | |||
346 | if (err) | 346 | if (err) |
347 | goto out; | 347 | goto out; |
348 | } else { | 348 | } else { |
349 | printk(KERN_ERR "hfs: invalid extended attribute name\n"); | 349 | pr_err("invalid extended attribute name\n"); |
350 | err = -EINVAL; | 350 | err = -EINVAL; |
351 | goto out; | 351 | goto out; |
352 | } | 352 | } |
@@ -372,7 +372,7 @@ int hfsplus_delete_all_attrs(struct inode *dir, u32 cnid) | |||
372 | hfs_dbg(ATTR_MOD, "delete_all_attrs: %d\n", cnid); | 372 | hfs_dbg(ATTR_MOD, "delete_all_attrs: %d\n", cnid); |
373 | 373 | ||
374 | if (!HFSPLUS_SB(dir->i_sb)->attr_tree) { | 374 | if (!HFSPLUS_SB(dir->i_sb)->attr_tree) { |
375 | printk(KERN_ERR "hfs: attributes file doesn't exist\n"); | 375 | pr_err("attributes file doesn't exist\n"); |
376 | return -EINVAL; | 376 | return -EINVAL; |
377 | } | 377 | } |
378 | 378 | ||
@@ -384,7 +384,7 @@ int hfsplus_delete_all_attrs(struct inode *dir, u32 cnid) | |||
384 | err = hfsplus_find_attr(dir->i_sb, cnid, NULL, &fd); | 384 | err = hfsplus_find_attr(dir->i_sb, cnid, NULL, &fd); |
385 | if (err) { | 385 | if (err) { |
386 | if (err != -ENOENT) | 386 | if (err != -ENOENT) |
387 | printk(KERN_ERR "hfs: xattr search failed.\n"); | 387 | pr_err("xattr search failed\n"); |
388 | goto end_delete_all; | 388 | goto end_delete_all; |
389 | } | 389 | } |
390 | 390 | ||