]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
ufs: the offsets ufs_block_to_path() puts into array are not sector_t
authorAl Viro <viro@zeniv.linux.org.uk>
Thu, 4 Jun 2015 18:13:14 +0000 (14:13 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Mon, 6 Jul 2015 21:39:31 +0000 (17:39 -0400)
type makes no sense - those are indices in block number arrays, not
block numbers.  And no, UFS is not likely to grow indirect blocks with
4Gpointers in them...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/ufs/inode.c

index ec758edbda4785ea05f6ef0b2900756c46a0211a..43672183fee33aed9cec936156546c3a30cbd243 100644 (file)
@@ -41,7 +41,7 @@
 #include "swab.h"
 #include "util.h"
 
-static int ufs_block_to_path(struct inode *inode, sector_t i_block, sector_t offsets[4])
+static int ufs_block_to_path(struct inode *inode, sector_t i_block, unsigned offsets[4])
 {
        struct ufs_sb_private_info *uspi = UFS_SB(inode->i_sb)->s_uspi;
        int ptrs = uspi->s_apb;
@@ -153,7 +153,7 @@ again:
        while (--depth) {
                __fs32 *ptr;
                struct buffer_head *bh;
-               sector_t n = *p++;
+               unsigned n = *p++;
 
                bh = sb_bread(sb, uspi->s_sbbase +
                                  fs32_to_cpu(sb, q->key32) + (n>>shift));
@@ -177,7 +177,7 @@ ufs2:
        while (--depth) {
                __fs64 *ptr;
                struct buffer_head *bh;
-               sector_t n = *p++;
+               unsigned n = *p++;
 
                bh = sb_bread(sb, uspi->s_sbbase +
                                  fs64_to_cpu(sb, q->key64) + (n>>shift));