Re: vfat: attempt to access beyond end of device

OGAWA Hirofumi (hirofumi@mail.parknet.co.jp)
14 Jul 2001 00:13:40 +0900


Hi,

Alexander Griesser <tuxx@aon.at> writes:

> When I try to write new files on it, I get:
> kernel: attempt to access beyond end of device
> kernel: 16:01: rw=0, want=2081231810, limit=80035798
>
> According to his Problewm:
> Shouldn't an "int" be enough?
>
> 2^31 = 2147483648
> And he "wants": 2081231810
>
> Should do, or did I miss something?

kernel: attempt to access beyond end of device
kernel: 16:01: rw=0, want=2081231810, limit=80035798
kernel: dev = 16:01, ino = -2120058812
^^^^^^^^^^^^
kernel: Filesystem panic (dev 16:01).

i_pos is -2120058812.

fat_write_inode()
i_pos = -2120058812; /* -2120058812 */
fat_bread(sb, i_pos >> 4); /* -132503676 */
...
getblk()
blocknr = block; /* 4162463620 */
...
submit_bh()
bh->b_rsector = bh->b_blocknr * count;
generic_make_request()
unsigned long sector = bh->b_rsector;

printk(KERN_INFO "%s: rw=%d, want=%ld, limit=%d\n",
kdevname(bh->b_rdev), rw,
(sector + count)>>1, minorsize); /* 2081231810 */

Thanks.

-- 
OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/