diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2010-01-31 21:28:48 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2010-03-03 14:07:58 -0500 |
commit | 391e8bbd38474b9f85b1f3933394a79ea66fe1e2 (patch) | |
tree | 78298556c37ef09f4f87138bc1c391f4f5dee917 /fs/udf | |
parent | 072f98b4637eddcbdf2178fc84f382e2ee522f08 (diff) |
sanitize const/signedness for udf
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/udf')
-rw-r--r-- | fs/udf/balloc.c | 2 | ||||
-rw-r--r-- | fs/udf/dir.c | 4 | ||||
-rw-r--r-- | fs/udf/inode.c | 2 | ||||
-rw-r--r-- | fs/udf/namei.c | 20 | ||||
-rw-r--r-- | fs/udf/symlink.c | 10 |
5 files changed, 19 insertions, 19 deletions
diff --git a/fs/udf/balloc.c b/fs/udf/balloc.c index 82372e332f08..b2d96f45c12b 100644 --- a/fs/udf/balloc.c +++ b/fs/udf/balloc.c | |||
@@ -547,7 +547,7 @@ static void udf_table_free_blocks(struct super_block *sb, | |||
547 | } | 547 | } |
548 | 548 | ||
549 | if (epos.offset + (2 * adsize) > sb->s_blocksize) { | 549 | if (epos.offset + (2 * adsize) > sb->s_blocksize) { |
550 | char *sptr, *dptr; | 550 | unsigned char *sptr, *dptr; |
551 | int loffset; | 551 | int loffset; |
552 | 552 | ||
553 | brelse(oepos.bh); | 553 | brelse(oepos.bh); |
diff --git a/fs/udf/dir.c b/fs/udf/dir.c index 61d9a76a3a69..f0f2a436251e 100644 --- a/fs/udf/dir.c +++ b/fs/udf/dir.c | |||
@@ -45,8 +45,8 @@ static int do_udf_readdir(struct inode *dir, struct file *filp, | |||
45 | int block, iblock; | 45 | int block, iblock; |
46 | loff_t nf_pos = (filp->f_pos - 1) << 2; | 46 | loff_t nf_pos = (filp->f_pos - 1) << 2; |
47 | int flen; | 47 | int flen; |
48 | char *fname = NULL; | 48 | unsigned char *fname = NULL; |
49 | char *nameptr; | 49 | unsigned char *nameptr; |
50 | uint16_t liu; | 50 | uint16_t liu; |
51 | uint8_t lfi; | 51 | uint8_t lfi; |
52 | loff_t size = udf_ext0_offset(dir) + dir->i_size; | 52 | loff_t size = udf_ext0_offset(dir) + dir->i_size; |
diff --git a/fs/udf/inode.c b/fs/udf/inode.c index f90231eb2916..378a7592257c 100644 --- a/fs/udf/inode.c +++ b/fs/udf/inode.c | |||
@@ -1672,7 +1672,7 @@ int8_t udf_add_aext(struct inode *inode, struct extent_position *epos, | |||
1672 | return -1; | 1672 | return -1; |
1673 | 1673 | ||
1674 | if (epos->offset + (2 * adsize) > inode->i_sb->s_blocksize) { | 1674 | if (epos->offset + (2 * adsize) > inode->i_sb->s_blocksize) { |
1675 | char *sptr, *dptr; | 1675 | unsigned char *sptr, *dptr; |
1676 | struct buffer_head *nbh; | 1676 | struct buffer_head *nbh; |
1677 | int err, loffset; | 1677 | int err, loffset; |
1678 | struct kernel_lb_addr obloc = epos->block; | 1678 | struct kernel_lb_addr obloc = epos->block; |
diff --git a/fs/udf/namei.c b/fs/udf/namei.c index cd2115060fdc..7c56ff00cd53 100644 --- a/fs/udf/namei.c +++ b/fs/udf/namei.c | |||
@@ -34,8 +34,8 @@ | |||
34 | #include <linux/crc-itu-t.h> | 34 | #include <linux/crc-itu-t.h> |
35 | #include <linux/exportfs.h> | 35 | #include <linux/exportfs.h> |
36 | 36 | ||
37 | static inline int udf_match(int len1, const char *name1, int len2, | 37 | static inline int udf_match(int len1, const unsigned char *name1, int len2, |
38 | const char *name2) | 38 | const unsigned char *name2) |
39 | { | 39 | { |
40 | if (len1 != len2) | 40 | if (len1 != len2) |
41 | return 0; | 41 | return 0; |
@@ -142,15 +142,15 @@ int udf_write_fi(struct inode *inode, struct fileIdentDesc *cfi, | |||
142 | } | 142 | } |
143 | 143 | ||
144 | static struct fileIdentDesc *udf_find_entry(struct inode *dir, | 144 | static struct fileIdentDesc *udf_find_entry(struct inode *dir, |
145 | struct qstr *child, | 145 | const struct qstr *child, |
146 | struct udf_fileident_bh *fibh, | 146 | struct udf_fileident_bh *fibh, |
147 | struct fileIdentDesc *cfi) | 147 | struct fileIdentDesc *cfi) |
148 | { | 148 | { |
149 | struct fileIdentDesc *fi = NULL; | 149 | struct fileIdentDesc *fi = NULL; |
150 | loff_t f_pos; | 150 | loff_t f_pos; |
151 | int block, flen; | 151 | int block, flen; |
152 | char *fname = NULL; | 152 | unsigned char *fname = NULL; |
153 | char *nameptr; | 153 | unsigned char *nameptr; |
154 | uint8_t lfi; | 154 | uint8_t lfi; |
155 | uint16_t liu; | 155 | uint16_t liu; |
156 | loff_t size; | 156 | loff_t size; |
@@ -308,7 +308,7 @@ static struct fileIdentDesc *udf_add_entry(struct inode *dir, | |||
308 | { | 308 | { |
309 | struct super_block *sb = dir->i_sb; | 309 | struct super_block *sb = dir->i_sb; |
310 | struct fileIdentDesc *fi = NULL; | 310 | struct fileIdentDesc *fi = NULL; |
311 | char *name = NULL; | 311 | unsigned char *name = NULL; |
312 | int namelen; | 312 | int namelen; |
313 | loff_t f_pos; | 313 | loff_t f_pos; |
314 | loff_t size = udf_ext0_offset(dir) + dir->i_size; | 314 | loff_t size = udf_ext0_offset(dir) + dir->i_size; |
@@ -885,16 +885,16 @@ static int udf_symlink(struct inode *dir, struct dentry *dentry, | |||
885 | { | 885 | { |
886 | struct inode *inode; | 886 | struct inode *inode; |
887 | struct pathComponent *pc; | 887 | struct pathComponent *pc; |
888 | char *compstart; | 888 | const char *compstart; |
889 | struct udf_fileident_bh fibh; | 889 | struct udf_fileident_bh fibh; |
890 | struct extent_position epos = {}; | 890 | struct extent_position epos = {}; |
891 | int eoffset, elen = 0; | 891 | int eoffset, elen = 0; |
892 | struct fileIdentDesc *fi; | 892 | struct fileIdentDesc *fi; |
893 | struct fileIdentDesc cfi; | 893 | struct fileIdentDesc cfi; |
894 | char *ea; | 894 | uint8_t *ea; |
895 | int err; | 895 | int err; |
896 | int block; | 896 | int block; |
897 | char *name = NULL; | 897 | unsigned char *name = NULL; |
898 | int namelen; | 898 | int namelen; |
899 | struct buffer_head *bh; | 899 | struct buffer_head *bh; |
900 | struct udf_inode_info *iinfo; | 900 | struct udf_inode_info *iinfo; |
@@ -970,7 +970,7 @@ static int udf_symlink(struct inode *dir, struct dentry *dentry, | |||
970 | 970 | ||
971 | pc = (struct pathComponent *)(ea + elen); | 971 | pc = (struct pathComponent *)(ea + elen); |
972 | 972 | ||
973 | compstart = (char *)symname; | 973 | compstart = symname; |
974 | 974 | ||
975 | do { | 975 | do { |
976 | symname++; | 976 | symname++; |
diff --git a/fs/udf/symlink.c b/fs/udf/symlink.c index c3265e1385d4..852e91845688 100644 --- a/fs/udf/symlink.c +++ b/fs/udf/symlink.c | |||
@@ -32,12 +32,12 @@ | |||
32 | #include <linux/buffer_head.h> | 32 | #include <linux/buffer_head.h> |
33 | #include "udf_i.h" | 33 | #include "udf_i.h" |
34 | 34 | ||
35 | static void udf_pc_to_char(struct super_block *sb, char *from, int fromlen, | 35 | static void udf_pc_to_char(struct super_block *sb, unsigned char *from, |
36 | char *to) | 36 | int fromlen, unsigned char *to) |
37 | { | 37 | { |
38 | struct pathComponent *pc; | 38 | struct pathComponent *pc; |
39 | int elen = 0; | 39 | int elen = 0; |
40 | char *p = to; | 40 | unsigned char *p = to; |
41 | 41 | ||
42 | while (elen < fromlen) { | 42 | while (elen < fromlen) { |
43 | pc = (struct pathComponent *)(from + elen); | 43 | pc = (struct pathComponent *)(from + elen); |
@@ -75,9 +75,9 @@ static int udf_symlink_filler(struct file *file, struct page *page) | |||
75 | { | 75 | { |
76 | struct inode *inode = page->mapping->host; | 76 | struct inode *inode = page->mapping->host; |
77 | struct buffer_head *bh = NULL; | 77 | struct buffer_head *bh = NULL; |
78 | char *symlink; | 78 | unsigned char *symlink; |
79 | int err = -EIO; | 79 | int err = -EIO; |
80 | char *p = kmap(page); | 80 | unsigned char *p = kmap(page); |
81 | struct udf_inode_info *iinfo; | 81 | struct udf_inode_info *iinfo; |
82 | 82 | ||
83 | lock_kernel(); | 83 | lock_kernel(); |