[PATCH] change buffer_head.b_size to size_t
Increase the size of the buffer_head b_size field (only) for 64 bit platforms. Update some old and moldy comments in and around the structure as well. The b_size increase allows us to perform larger mappings and allocations for large I/O requests from userspace, which tie in with other changes allowing the get_block_t() interface to map multiple blocks at once. Signed-off-by: Nathan Scott <nathans@sgi.com> Signed-off-by: Badari Pulavarty <pbadari@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
committed by
Linus Torvalds
parent
d48589bfad
commit
205f87f6b3
@@ -426,8 +426,10 @@ __find_get_block_slow(struct block_device *bdev, sector_t block)
|
||||
if (all_mapped) {
|
||||
printk("__find_get_block_slow() failed. "
|
||||
"block=%llu, b_blocknr=%llu\n",
|
||||
(unsigned long long)block, (unsigned long long)bh->b_blocknr);
|
||||
printk("b_state=0x%08lx, b_size=%u\n", bh->b_state, bh->b_size);
|
||||
(unsigned long long)block,
|
||||
(unsigned long long)bh->b_blocknr);
|
||||
printk("b_state=0x%08lx, b_size=%zu\n",
|
||||
bh->b_state, bh->b_size);
|
||||
printk("device blocksize: %d\n", 1 << bd_inode->i_blkbits);
|
||||
}
|
||||
out_unlock:
|
||||
|
@@ -377,7 +377,7 @@ int ocfs2_journal_access(struct ocfs2_journal_handle *handle,
|
||||
BUG_ON(!bh);
|
||||
BUG_ON(!(handle->flags & OCFS2_HANDLE_STARTED));
|
||||
|
||||
mlog_entry("bh->b_blocknr=%llu, type=%d (\"%s\"), bh->b_size = %hu\n",
|
||||
mlog_entry("bh->b_blocknr=%llu, type=%d (\"%s\"), bh->b_size = %zu\n",
|
||||
(unsigned long long)bh->b_blocknr, type,
|
||||
(type == OCFS2_JOURNAL_ACCESS_CREATE) ?
|
||||
"OCFS2_JOURNAL_ACCESS_CREATE" :
|
||||
|
@@ -143,7 +143,7 @@ static void sprintf_buffer_head(char *buf, struct buffer_head *bh)
|
||||
char b[BDEVNAME_SIZE];
|
||||
|
||||
sprintf(buf,
|
||||
"dev %s, size %d, blocknr %llu, count %d, state 0x%lx, page %p, (%s, %s, %s)",
|
||||
"dev %s, size %zd, blocknr %llu, count %d, state 0x%lx, page %p, (%s, %s, %s)",
|
||||
bdevname(bh->b_bdev, b), bh->b_size,
|
||||
(unsigned long long)bh->b_blocknr, atomic_read(&(bh->b_count)),
|
||||
bh->b_state, bh->b_page,
|
||||
|
Reference in New Issue
Block a user