diff options
author | Mark Fasheh <mark.fasheh@oracle.com> | 2006-03-03 13:24:33 -0500 |
---|---|---|
committer | Mark Fasheh <mark.fasheh@oracle.com> | 2006-03-24 17:58:28 -0500 |
commit | b0697053f9e8de9cea3d510d9e290851ece9460b (patch) | |
tree | bcfa2ae33e4a5302ddbe94dec0eaf95013e79850 /fs/ocfs2/dlmglue.c | |
parent | 29004858a76ba9e26393dd8a85e653f105a33753 (diff) |
ocfs2: don't use MLF* in the file system
Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
Diffstat (limited to 'fs/ocfs2/dlmglue.c')
-rw-r--r-- | fs/ocfs2/dlmglue.c | 101 |
1 files changed, 52 insertions, 49 deletions
diff --git a/fs/ocfs2/dlmglue.c b/fs/ocfs2/dlmglue.c index e971ec2f8407..84f153aca692 100644 --- a/fs/ocfs2/dlmglue.c +++ b/fs/ocfs2/dlmglue.c | |||
@@ -231,9 +231,9 @@ static void ocfs2_build_lock_name(enum ocfs2_lock_type type, | |||
231 | 231 | ||
232 | BUG_ON(type >= OCFS2_NUM_LOCK_TYPES); | 232 | BUG_ON(type >= OCFS2_NUM_LOCK_TYPES); |
233 | 233 | ||
234 | len = snprintf(name, OCFS2_LOCK_ID_MAX_LEN, "%c%s%016"MLFx64"%08x", | 234 | len = snprintf(name, OCFS2_LOCK_ID_MAX_LEN, "%c%s%016llx%08x", |
235 | ocfs2_lock_type_char(type), OCFS2_LOCK_ID_PAD, blkno, | 235 | ocfs2_lock_type_char(type), OCFS2_LOCK_ID_PAD, |
236 | generation); | 236 | (long long)blkno, generation); |
237 | 237 | ||
238 | BUG_ON(len != (OCFS2_LOCK_ID_MAX_LEN - 1)); | 238 | BUG_ON(len != (OCFS2_LOCK_ID_MAX_LEN - 1)); |
239 | 239 | ||
@@ -533,8 +533,8 @@ static void ocfs2_inode_ast_func(void *opaque) | |||
533 | 533 | ||
534 | inode = ocfs2_lock_res_inode(lockres); | 534 | inode = ocfs2_lock_res_inode(lockres); |
535 | 535 | ||
536 | mlog(0, "AST fired for inode %"MLFu64", l_action = %u, type = %s\n", | 536 | mlog(0, "AST fired for inode %llu, l_action = %u, type = %s\n", |
537 | OCFS2_I(inode)->ip_blkno, lockres->l_action, | 537 | (unsigned long long)OCFS2_I(inode)->ip_blkno, lockres->l_action, |
538 | ocfs2_lock_type_string(lockres->l_type)); | 538 | ocfs2_lock_type_string(lockres->l_type)); |
539 | 539 | ||
540 | BUG_ON(!ocfs2_is_inode_lock(lockres)); | 540 | BUG_ON(!ocfs2_is_inode_lock(lockres)); |
@@ -544,8 +544,8 @@ static void ocfs2_inode_ast_func(void *opaque) | |||
544 | lksb = &(lockres->l_lksb); | 544 | lksb = &(lockres->l_lksb); |
545 | if (lksb->status != DLM_NORMAL) { | 545 | if (lksb->status != DLM_NORMAL) { |
546 | mlog(ML_ERROR, "ocfs2_inode_ast_func: lksb status value of %u " | 546 | mlog(ML_ERROR, "ocfs2_inode_ast_func: lksb status value of %u " |
547 | "on inode %"MLFu64"\n", lksb->status, | 547 | "on inode %llu\n", lksb->status, |
548 | OCFS2_I(inode)->ip_blkno); | 548 | (unsigned long long)OCFS2_I(inode)->ip_blkno); |
549 | spin_unlock_irqrestore(&lockres->l_lock, flags); | 549 | spin_unlock_irqrestore(&lockres->l_lock, flags); |
550 | mlog_exit_void(); | 550 | mlog_exit_void(); |
551 | return; | 551 | return; |
@@ -646,10 +646,9 @@ static void ocfs2_inode_bast_func(void *opaque, int level) | |||
646 | inode = ocfs2_lock_res_inode(lockres); | 646 | inode = ocfs2_lock_res_inode(lockres); |
647 | osb = OCFS2_SB(inode->i_sb); | 647 | osb = OCFS2_SB(inode->i_sb); |
648 | 648 | ||
649 | mlog(0, "BAST fired for inode %"MLFu64", blocking = %d, level = %d " | 649 | mlog(0, "BAST fired for inode %llu, blocking %d, level %d type %s\n", |
650 | "type = %s\n", OCFS2_I(inode)->ip_blkno, level, | 650 | (unsigned long long)OCFS2_I(inode)->ip_blkno, level, |
651 | lockres->l_level, | 651 | lockres->l_level, ocfs2_lock_type_string(lockres->l_type)); |
652 | ocfs2_lock_type_string(lockres->l_type)); | ||
653 | 652 | ||
654 | ocfs2_generic_bast_func(osb, lockres, level); | 653 | ocfs2_generic_bast_func(osb, lockres, level); |
655 | 654 | ||
@@ -1104,7 +1103,7 @@ int ocfs2_create_new_inode_locks(struct inode *inode) | |||
1104 | 1103 | ||
1105 | mlog_entry_void(); | 1104 | mlog_entry_void(); |
1106 | 1105 | ||
1107 | mlog(0, "Inode %"MLFu64"\n", OCFS2_I(inode)->ip_blkno); | 1106 | mlog(0, "Inode %llu\n", (unsigned long long)OCFS2_I(inode)->ip_blkno); |
1108 | 1107 | ||
1109 | /* NOTE: That we don't increment any of the holder counts, nor | 1108 | /* NOTE: That we don't increment any of the holder counts, nor |
1110 | * do we add anything to a journal handle. Since this is | 1109 | * do we add anything to a journal handle. Since this is |
@@ -1149,8 +1148,8 @@ int ocfs2_rw_lock(struct inode *inode, int write) | |||
1149 | 1148 | ||
1150 | mlog_entry_void(); | 1149 | mlog_entry_void(); |
1151 | 1150 | ||
1152 | mlog(0, "inode %"MLFu64" take %s RW lock\n", | 1151 | mlog(0, "inode %llu take %s RW lock\n", |
1153 | OCFS2_I(inode)->ip_blkno, | 1152 | (unsigned long long)OCFS2_I(inode)->ip_blkno, |
1154 | write ? "EXMODE" : "PRMODE"); | 1153 | write ? "EXMODE" : "PRMODE"); |
1155 | 1154 | ||
1156 | lockres = &OCFS2_I(inode)->ip_rw_lockres; | 1155 | lockres = &OCFS2_I(inode)->ip_rw_lockres; |
@@ -1173,8 +1172,8 @@ void ocfs2_rw_unlock(struct inode *inode, int write) | |||
1173 | 1172 | ||
1174 | mlog_entry_void(); | 1173 | mlog_entry_void(); |
1175 | 1174 | ||
1176 | mlog(0, "inode %"MLFu64" drop %s RW lock\n", | 1175 | mlog(0, "inode %llu drop %s RW lock\n", |
1177 | OCFS2_I(inode)->ip_blkno, | 1176 | (unsigned long long)OCFS2_I(inode)->ip_blkno, |
1178 | write ? "EXMODE" : "PRMODE"); | 1177 | write ? "EXMODE" : "PRMODE"); |
1179 | 1178 | ||
1180 | ocfs2_cluster_unlock(OCFS2_SB(inode->i_sb), lockres, level); | 1179 | ocfs2_cluster_unlock(OCFS2_SB(inode->i_sb), lockres, level); |
@@ -1193,8 +1192,8 @@ int ocfs2_data_lock_full(struct inode *inode, | |||
1193 | 1192 | ||
1194 | mlog_entry_void(); | 1193 | mlog_entry_void(); |
1195 | 1194 | ||
1196 | mlog(0, "inode %"MLFu64" take %s DATA lock\n", | 1195 | mlog(0, "inode %llu take %s DATA lock\n", |
1197 | OCFS2_I(inode)->ip_blkno, | 1196 | (unsigned long long)OCFS2_I(inode)->ip_blkno, |
1198 | write ? "EXMODE" : "PRMODE"); | 1197 | write ? "EXMODE" : "PRMODE"); |
1199 | 1198 | ||
1200 | /* We'll allow faking a readonly data lock for | 1199 | /* We'll allow faking a readonly data lock for |
@@ -1278,8 +1277,8 @@ void ocfs2_data_unlock(struct inode *inode, | |||
1278 | 1277 | ||
1279 | mlog_entry_void(); | 1278 | mlog_entry_void(); |
1280 | 1279 | ||
1281 | mlog(0, "inode %"MLFu64" drop %s DATA lock\n", | 1280 | mlog(0, "inode %llu drop %s DATA lock\n", |
1282 | OCFS2_I(inode)->ip_blkno, | 1281 | (unsigned long long)OCFS2_I(inode)->ip_blkno, |
1283 | write ? "EXMODE" : "PRMODE"); | 1282 | write ? "EXMODE" : "PRMODE"); |
1284 | 1283 | ||
1285 | if (!ocfs2_is_hard_readonly(OCFS2_SB(inode->i_sb))) | 1284 | if (!ocfs2_is_hard_readonly(OCFS2_SB(inode->i_sb))) |
@@ -1462,9 +1461,9 @@ static int ocfs2_meta_lock_update(struct inode *inode, | |||
1462 | 1461 | ||
1463 | spin_lock(&oi->ip_lock); | 1462 | spin_lock(&oi->ip_lock); |
1464 | if (oi->ip_flags & OCFS2_INODE_DELETED) { | 1463 | if (oi->ip_flags & OCFS2_INODE_DELETED) { |
1465 | mlog(0, "Orphaned inode %"MLFu64" was deleted while we " | 1464 | mlog(0, "Orphaned inode %llu was deleted while we " |
1466 | "were waiting on a lock. ip_flags = 0x%x\n", | 1465 | "were waiting on a lock. ip_flags = 0x%x\n", |
1467 | oi->ip_blkno, oi->ip_flags); | 1466 | (unsigned long long)oi->ip_blkno, oi->ip_flags); |
1468 | spin_unlock(&oi->ip_lock); | 1467 | spin_unlock(&oi->ip_lock); |
1469 | status = -ENOENT; | 1468 | status = -ENOENT; |
1470 | goto bail; | 1469 | goto bail; |
@@ -1485,8 +1484,8 @@ static int ocfs2_meta_lock_update(struct inode *inode, | |||
1485 | ocfs2_extent_map_trunc(inode, 0); | 1484 | ocfs2_extent_map_trunc(inode, 0); |
1486 | 1485 | ||
1487 | if (ocfs2_meta_lvb_is_trustable(lockres)) { | 1486 | if (ocfs2_meta_lvb_is_trustable(lockres)) { |
1488 | mlog(0, "Trusting LVB on inode %"MLFu64"\n", | 1487 | mlog(0, "Trusting LVB on inode %llu\n", |
1489 | oi->ip_blkno); | 1488 | (unsigned long long)oi->ip_blkno); |
1490 | ocfs2_refresh_inode_from_lvb(inode); | 1489 | ocfs2_refresh_inode_from_lvb(inode); |
1491 | } else { | 1490 | } else { |
1492 | /* Boo, we have to go to disk. */ | 1491 | /* Boo, we have to go to disk. */ |
@@ -1514,15 +1513,16 @@ static int ocfs2_meta_lock_update(struct inode *inode, | |||
1514 | } | 1513 | } |
1515 | mlog_bug_on_msg(inode->i_generation != | 1514 | mlog_bug_on_msg(inode->i_generation != |
1516 | le32_to_cpu(fe->i_generation), | 1515 | le32_to_cpu(fe->i_generation), |
1517 | "Invalid dinode %"MLFu64" disk generation: %u " | 1516 | "Invalid dinode %llu disk generation: %u " |
1518 | "inode->i_generation: %u\n", | 1517 | "inode->i_generation: %u\n", |
1519 | oi->ip_blkno, le32_to_cpu(fe->i_generation), | 1518 | (unsigned long long)oi->ip_blkno, |
1519 | le32_to_cpu(fe->i_generation), | ||
1520 | inode->i_generation); | 1520 | inode->i_generation); |
1521 | mlog_bug_on_msg(le64_to_cpu(fe->i_dtime) || | 1521 | mlog_bug_on_msg(le64_to_cpu(fe->i_dtime) || |
1522 | !(fe->i_flags & cpu_to_le32(OCFS2_VALID_FL)), | 1522 | !(fe->i_flags & cpu_to_le32(OCFS2_VALID_FL)), |
1523 | "Stale dinode %"MLFu64" dtime: %"MLFu64" " | 1523 | "Stale dinode %llu dtime: %llu flags: 0x%x\n", |
1524 | "flags: 0x%x\n", oi->ip_blkno, | 1524 | (unsigned long long)oi->ip_blkno, |
1525 | le64_to_cpu(fe->i_dtime), | 1525 | (unsigned long long)le64_to_cpu(fe->i_dtime), |
1526 | le32_to_cpu(fe->i_flags)); | 1526 | le32_to_cpu(fe->i_flags)); |
1527 | 1527 | ||
1528 | ocfs2_refresh_inode(inode, fe); | 1528 | ocfs2_refresh_inode(inode, fe); |
@@ -1581,8 +1581,8 @@ int ocfs2_meta_lock_full(struct inode *inode, | |||
1581 | 1581 | ||
1582 | mlog_entry_void(); | 1582 | mlog_entry_void(); |
1583 | 1583 | ||
1584 | mlog(0, "inode %"MLFu64", take %s META lock\n", | 1584 | mlog(0, "inode %llu, take %s META lock\n", |
1585 | OCFS2_I(inode)->ip_blkno, | 1585 | (unsigned long long)OCFS2_I(inode)->ip_blkno, |
1586 | ex ? "EXMODE" : "PRMODE"); | 1586 | ex ? "EXMODE" : "PRMODE"); |
1587 | 1587 | ||
1588 | status = 0; | 1588 | status = 0; |
@@ -1716,8 +1716,8 @@ void ocfs2_meta_unlock(struct inode *inode, | |||
1716 | 1716 | ||
1717 | mlog_entry_void(); | 1717 | mlog_entry_void(); |
1718 | 1718 | ||
1719 | mlog(0, "inode %"MLFu64" drop %s META lock\n", | 1719 | mlog(0, "inode %llu drop %s META lock\n", |
1720 | OCFS2_I(inode)->ip_blkno, | 1720 | (unsigned long long)OCFS2_I(inode)->ip_blkno, |
1721 | ex ? "EXMODE" : "PRMODE"); | 1721 | ex ? "EXMODE" : "PRMODE"); |
1722 | 1722 | ||
1723 | if (!ocfs2_is_hard_readonly(OCFS2_SB(inode->i_sb))) | 1723 | if (!ocfs2_is_hard_readonly(OCFS2_SB(inode->i_sb))) |
@@ -2686,8 +2686,8 @@ static void ocfs2_data_convert_worker(struct ocfs2_lock_res *lockres, | |||
2686 | mapping = inode->i_mapping; | 2686 | mapping = inode->i_mapping; |
2687 | 2687 | ||
2688 | if (filemap_fdatawrite(mapping)) { | 2688 | if (filemap_fdatawrite(mapping)) { |
2689 | mlog(ML_ERROR, "Could not sync inode %"MLFu64" for downconvert!", | 2689 | mlog(ML_ERROR, "Could not sync inode %llu for downconvert!", |
2690 | OCFS2_I(inode)->ip_blkno); | 2690 | (unsigned long long)OCFS2_I(inode)->ip_blkno); |
2691 | } | 2691 | } |
2692 | sync_mapping_buffers(mapping); | 2692 | sync_mapping_buffers(mapping); |
2693 | if (blocking == LKM_EXMODE) { | 2693 | if (blocking == LKM_EXMODE) { |
@@ -2717,7 +2717,8 @@ int ocfs2_unblock_data(struct ocfs2_lock_res *lockres, | |||
2717 | inode = ocfs2_lock_res_inode(lockres); | 2717 | inode = ocfs2_lock_res_inode(lockres); |
2718 | osb = OCFS2_SB(inode->i_sb); | 2718 | osb = OCFS2_SB(inode->i_sb); |
2719 | 2719 | ||
2720 | mlog(0, "unblock inode %"MLFu64"\n", OCFS2_I(inode)->ip_blkno); | 2720 | mlog(0, "unblock inode %llu\n", |
2721 | (unsigned long long)OCFS2_I(inode)->ip_blkno); | ||
2721 | 2722 | ||
2722 | status = ocfs2_generic_unblock_lock(osb, | 2723 | status = ocfs2_generic_unblock_lock(osb, |
2723 | lockres, | 2724 | lockres, |
@@ -2726,8 +2727,8 @@ int ocfs2_unblock_data(struct ocfs2_lock_res *lockres, | |||
2726 | if (status < 0) | 2727 | if (status < 0) |
2727 | mlog_errno(status); | 2728 | mlog_errno(status); |
2728 | 2729 | ||
2729 | mlog(0, "inode %"MLFu64", requeue = %d\n", | 2730 | mlog(0, "inode %llu, requeue = %d\n", |
2730 | OCFS2_I(inode)->ip_blkno, *requeue); | 2731 | (unsigned long long)OCFS2_I(inode)->ip_blkno, *requeue); |
2731 | 2732 | ||
2732 | mlog_exit(status); | 2733 | mlog_exit(status); |
2733 | return status; | 2734 | return status; |
@@ -2767,14 +2768,15 @@ int ocfs2_unblock_meta(struct ocfs2_lock_res *lockres, | |||
2767 | 2768 | ||
2768 | inode = ocfs2_lock_res_inode(lockres); | 2769 | inode = ocfs2_lock_res_inode(lockres); |
2769 | 2770 | ||
2770 | mlog(0, "unblock inode %"MLFu64"\n", OCFS2_I(inode)->ip_blkno); | 2771 | mlog(0, "unblock inode %llu\n", |
2772 | (unsigned long long)OCFS2_I(inode)->ip_blkno); | ||
2771 | 2773 | ||
2772 | status = ocfs2_do_unblock_meta(inode, requeue); | 2774 | status = ocfs2_do_unblock_meta(inode, requeue); |
2773 | if (status < 0) | 2775 | if (status < 0) |
2774 | mlog_errno(status); | 2776 | mlog_errno(status); |
2775 | 2777 | ||
2776 | mlog(0, "inode %"MLFu64", requeue = %d\n", | 2778 | mlog(0, "inode %llu, requeue = %d\n", |
2777 | OCFS2_I(inode)->ip_blkno, *requeue); | 2779 | (unsigned long long)OCFS2_I(inode)->ip_blkno, *requeue); |
2778 | 2780 | ||
2779 | mlog_exit(status); | 2781 | mlog_exit(status); |
2780 | return status; | 2782 | return status; |
@@ -2893,12 +2895,13 @@ void ocfs2_dump_meta_lvb_info(u64 level, | |||
2893 | lockres->l_name, function, line); | 2895 | lockres->l_name, function, line); |
2894 | mlog(level, "version: %u, clusters: %u\n", | 2896 | mlog(level, "version: %u, clusters: %u\n", |
2895 | be32_to_cpu(lvb->lvb_version), be32_to_cpu(lvb->lvb_iclusters)); | 2897 | be32_to_cpu(lvb->lvb_version), be32_to_cpu(lvb->lvb_iclusters)); |
2896 | mlog(level, "size: %"MLFu64", uid %u, gid %u, mode 0x%x\n", | 2898 | mlog(level, "size: %llu, uid %u, gid %u, mode 0x%x\n", |
2897 | be64_to_cpu(lvb->lvb_isize), be32_to_cpu(lvb->lvb_iuid), | 2899 | (unsigned long long)be64_to_cpu(lvb->lvb_isize), |
2898 | be32_to_cpu(lvb->lvb_igid), be16_to_cpu(lvb->lvb_imode)); | 2900 | be32_to_cpu(lvb->lvb_iuid), be32_to_cpu(lvb->lvb_igid), |
2899 | mlog(level, "nlink %u, atime_packed 0x%"MLFx64", " | 2901 | be16_to_cpu(lvb->lvb_imode)); |
2900 | "ctime_packed 0x%"MLFx64", mtime_packed 0x%"MLFx64"\n", | 2902 | mlog(level, "nlink %u, atime_packed 0x%llx, ctime_packed 0x%llx, " |
2901 | be16_to_cpu(lvb->lvb_inlink), be64_to_cpu(lvb->lvb_iatime_packed), | 2903 | "mtime_packed 0x%llx\n", be16_to_cpu(lvb->lvb_inlink), |
2902 | be64_to_cpu(lvb->lvb_ictime_packed), | 2904 | (long long)be64_to_cpu(lvb->lvb_iatime_packed), |
2903 | be64_to_cpu(lvb->lvb_imtime_packed)); | 2905 | (long long)be64_to_cpu(lvb->lvb_ictime_packed), |
2906 | (long long)be64_to_cpu(lvb->lvb_imtime_packed)); | ||
2904 | } | 2907 | } |