diff options
author | Heiko Carstens <heiko.carstens@de.ibm.com> | 2011-09-22 21:34:33 +0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-09-27 03:21:15 +0400 |
commit | c4253cb0748cd50060d04d838c38b07f1ad0e6e5 (patch) | |
tree | d6a1e256622a8cb48ff093e5fc7351ce76749262 /fs/sysfs | |
parent | bcbe4f94d15ae1c985336bb3c35605e595fdde0d (diff) | |
download | linux-c4253cb0748cd50060d04d838c38b07f1ad0e6e5.tar.xz |
sysfs: add unsigned long cast to prevent compile warning
"sysfs: use rb-tree for inode number lookup" added a new printk which
causes a new compile warning on s390 (and few other architectures):
fs/sysfs/dir.c: In function 'sysfs_link_sibling':
fs/sysfs/dir.c:63:4: warning: format '%lx' expects argument of type
'long unsigned int', but argument 2 has type 'ino_t' [-Wform
Add an explicit unsigned long cast since ino_t is an unsigned long on
most architectures.
Cc: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'fs/sysfs')
-rw-r--r-- | fs/sysfs/dir.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/sysfs/dir.c b/fs/sysfs/dir.c index c3646d93a032..83bb9d1f30aa 100644 --- a/fs/sysfs/dir.c +++ b/fs/sysfs/dir.c @@ -60,7 +60,8 @@ static void sysfs_link_sibling(struct sysfs_dirent *sd) } else if (sd->s_ino > node->s_ino) { p = &node->inode_node.rb_right; } else { - printk(KERN_CRIT "sysfs: inserting duplicate inode '%lx'\n", sd->s_ino); + printk(KERN_CRIT "sysfs: inserting duplicate inode '%lx'\n", + (unsigned long) sd->s_ino); BUG(); } #undef node |