diff options
Diffstat (limited to 'fs/ocfs2/file.c')
-rw-r--r-- | fs/ocfs2/file.c | 42 |
1 files changed, 23 insertions, 19 deletions
diff --git a/fs/ocfs2/file.c b/fs/ocfs2/file.c index 8a4048b55fdc..4b4cbadd5838 100644 --- a/fs/ocfs2/file.c +++ b/fs/ocfs2/file.c | |||
@@ -220,8 +220,9 @@ static int ocfs2_truncate_file(struct inode *inode, | |||
220 | struct ocfs2_super *osb = OCFS2_SB(inode->i_sb); | 220 | struct ocfs2_super *osb = OCFS2_SB(inode->i_sb); |
221 | struct ocfs2_truncate_context *tc = NULL; | 221 | struct ocfs2_truncate_context *tc = NULL; |
222 | 222 | ||
223 | mlog_entry("(inode = %"MLFu64", new_i_size = %"MLFu64"\n", | 223 | mlog_entry("(inode = %llu, new_i_size = %llu\n", |
224 | OCFS2_I(inode)->ip_blkno, new_i_size); | 224 | (unsigned long long)OCFS2_I(inode)->ip_blkno, |
225 | (unsigned long long)new_i_size); | ||
225 | 226 | ||
226 | truncate_inode_pages(inode->i_mapping, new_i_size); | 227 | truncate_inode_pages(inode->i_mapping, new_i_size); |
227 | 228 | ||
@@ -233,23 +234,26 @@ static int ocfs2_truncate_file(struct inode *inode, | |||
233 | } | 234 | } |
234 | 235 | ||
235 | mlog_bug_on_msg(le64_to_cpu(fe->i_size) != i_size_read(inode), | 236 | mlog_bug_on_msg(le64_to_cpu(fe->i_size) != i_size_read(inode), |
236 | "Inode %"MLFu64", inode i_size = %lld != di " | 237 | "Inode %llu, inode i_size = %lld != di " |
237 | "i_size = %"MLFu64", i_flags = 0x%x\n", | 238 | "i_size = %llu, i_flags = 0x%x\n", |
238 | OCFS2_I(inode)->ip_blkno, | 239 | (unsigned long long)OCFS2_I(inode)->ip_blkno, |
239 | i_size_read(inode), | 240 | i_size_read(inode), |
240 | le64_to_cpu(fe->i_size), le32_to_cpu(fe->i_flags)); | 241 | (unsigned long long)le64_to_cpu(fe->i_size), |
242 | le32_to_cpu(fe->i_flags)); | ||
241 | 243 | ||
242 | if (new_i_size > le64_to_cpu(fe->i_size)) { | 244 | if (new_i_size > le64_to_cpu(fe->i_size)) { |
243 | mlog(0, "asked to truncate file with size (%"MLFu64") " | 245 | mlog(0, "asked to truncate file with size (%llu) to size (%llu)!\n", |
244 | "to size (%"MLFu64")!\n", | 246 | (unsigned long long)le64_to_cpu(fe->i_size), |
245 | le64_to_cpu(fe->i_size), new_i_size); | 247 | (unsigned long long)new_i_size); |
246 | status = -EINVAL; | 248 | status = -EINVAL; |
247 | mlog_errno(status); | 249 | mlog_errno(status); |
248 | goto bail; | 250 | goto bail; |
249 | } | 251 | } |
250 | 252 | ||
251 | mlog(0, "inode %"MLFu64", i_size = %"MLFu64", new_i_size = %"MLFu64"\n", | 253 | mlog(0, "inode %llu, i_size = %llu, new_i_size = %llu\n", |
252 | le64_to_cpu(fe->i_blkno), le64_to_cpu(fe->i_size), new_i_size); | 254 | (unsigned long long)le64_to_cpu(fe->i_blkno), |
255 | (unsigned long long)le64_to_cpu(fe->i_size), | ||
256 | (unsigned long long)new_i_size); | ||
253 | 257 | ||
254 | /* lets handle the simple truncate cases before doing any more | 258 | /* lets handle the simple truncate cases before doing any more |
255 | * cluster locking. */ | 259 | * cluster locking. */ |
@@ -378,8 +382,8 @@ int ocfs2_do_extend_allocation(struct ocfs2_super *osb, | |||
378 | } | 382 | } |
379 | 383 | ||
380 | block = ocfs2_clusters_to_blocks(osb->sb, bit_off); | 384 | block = ocfs2_clusters_to_blocks(osb->sb, bit_off); |
381 | mlog(0, "Allocating %u clusters at block %u for inode %"MLFu64"\n", | 385 | mlog(0, "Allocating %u clusters at block %u for inode %llu\n", |
382 | num_bits, bit_off, OCFS2_I(inode)->ip_blkno); | 386 | num_bits, bit_off, (unsigned long long)OCFS2_I(inode)->ip_blkno); |
383 | status = ocfs2_insert_extent(osb, handle, inode, fe_bh, block, | 387 | status = ocfs2_insert_extent(osb, handle, inode, fe_bh, block, |
384 | num_bits, meta_ac); | 388 | num_bits, meta_ac); |
385 | if (status < 0) { | 389 | if (status < 0) { |
@@ -449,9 +453,9 @@ static int ocfs2_extend_allocation(struct inode *inode, | |||
449 | restart_all: | 453 | restart_all: |
450 | BUG_ON(le32_to_cpu(fe->i_clusters) != OCFS2_I(inode)->ip_clusters); | 454 | BUG_ON(le32_to_cpu(fe->i_clusters) != OCFS2_I(inode)->ip_clusters); |
451 | 455 | ||
452 | mlog(0, "extend inode %"MLFu64", i_size = %lld, fe->i_clusters = %u, " | 456 | mlog(0, "extend inode %llu, i_size = %lld, fe->i_clusters = %u, " |
453 | "clusters_to_add = %u\n", | 457 | "clusters_to_add = %u\n", |
454 | OCFS2_I(inode)->ip_blkno, i_size_read(inode), | 458 | (unsigned long long)OCFS2_I(inode)->ip_blkno, i_size_read(inode), |
455 | fe->i_clusters, clusters_to_add); | 459 | fe->i_clusters, clusters_to_add); |
456 | 460 | ||
457 | handle = ocfs2_alloc_handle(osb); | 461 | handle = ocfs2_alloc_handle(osb); |
@@ -569,8 +573,8 @@ restarted_transaction: | |||
569 | } | 573 | } |
570 | } | 574 | } |
571 | 575 | ||
572 | mlog(0, "fe: i_clusters = %u, i_size=%"MLFu64"\n", | 576 | mlog(0, "fe: i_clusters = %u, i_size=%llu\n", |
573 | fe->i_clusters, fe->i_size); | 577 | fe->i_clusters, (unsigned long long)fe->i_size); |
574 | mlog(0, "inode: ip_clusters=%u, i_size=%lld\n", | 578 | mlog(0, "inode: ip_clusters=%u, i_size=%lld\n", |
575 | OCFS2_I(inode)->ip_clusters, i_size_read(inode)); | 579 | OCFS2_I(inode)->ip_clusters, i_size_read(inode)); |
576 | 580 | ||
@@ -865,8 +869,8 @@ static int ocfs2_write_remove_suid(struct inode *inode) | |||
865 | struct ocfs2_super *osb = OCFS2_SB(inode->i_sb); | 869 | struct ocfs2_super *osb = OCFS2_SB(inode->i_sb); |
866 | struct ocfs2_dinode *di; | 870 | struct ocfs2_dinode *di; |
867 | 871 | ||
868 | mlog_entry("(Inode %"MLFu64", mode 0%o)\n", oi->ip_blkno, | 872 | mlog_entry("(Inode %llu, mode 0%o)\n", |
869 | inode->i_mode); | 873 | (unsigned long long)oi->ip_blkno, inode->i_mode); |
870 | 874 | ||
871 | handle = ocfs2_start_trans(osb, NULL, OCFS2_INODE_UPDATE_CREDITS); | 875 | handle = ocfs2_start_trans(osb, NULL, OCFS2_INODE_UPDATE_CREDITS); |
872 | if (handle == NULL) { | 876 | if (handle == NULL) { |