aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/vote.c
diff options
context:
space:
mode:
authorMark Fasheh <mark.fasheh@oracle.com>2006-03-03 13:24:33 -0500
committerMark Fasheh <mark.fasheh@oracle.com>2006-03-24 17:58:28 -0500
commitb0697053f9e8de9cea3d510d9e290851ece9460b (patch)
treebcfa2ae33e4a5302ddbe94dec0eaf95013e79850 /fs/ocfs2/vote.c
parent29004858a76ba9e26393dd8a85e653f105a33753 (diff)
ocfs2: don't use MLF* in the file system
Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
Diffstat (limited to 'fs/ocfs2/vote.c')
-rw-r--r--fs/ocfs2/vote.c63
1 files changed, 34 insertions, 29 deletions
diff --git a/fs/ocfs2/vote.c b/fs/ocfs2/vote.c
index 021978e0576b..53049a204197 100644
--- a/fs/ocfs2/vote.c
+++ b/fs/ocfs2/vote.c
@@ -190,20 +190,21 @@ static int ocfs2_process_delete_request(struct inode *inode,
190 OCFS2_INVALID_SLOT && 190 OCFS2_INVALID_SLOT &&
191 OCFS2_I(inode)->ip_orphaned_slot != 191 OCFS2_I(inode)->ip_orphaned_slot !=
192 (*orphaned_slot), 192 (*orphaned_slot),
193 "Inode %"MLFu64": This node thinks it's " 193 "Inode %llu: This node thinks it's "
194 "orphaned in slot %d, messaged it's in %d\n", 194 "orphaned in slot %d, messaged it's in %d\n",
195 OCFS2_I(inode)->ip_blkno, 195 (unsigned long long)OCFS2_I(inode)->ip_blkno,
196 OCFS2_I(inode)->ip_orphaned_slot, 196 OCFS2_I(inode)->ip_orphaned_slot,
197 *orphaned_slot); 197 *orphaned_slot);
198 198
199 mlog(0, "Setting orphaned slot for inode %"MLFu64" to %d\n", 199 mlog(0, "Setting orphaned slot for inode %llu to %d\n",
200 OCFS2_I(inode)->ip_blkno, *orphaned_slot); 200 (unsigned long long)OCFS2_I(inode)->ip_blkno,
201 *orphaned_slot);
201 202
202 OCFS2_I(inode)->ip_orphaned_slot = *orphaned_slot; 203 OCFS2_I(inode)->ip_orphaned_slot = *orphaned_slot;
203 } else { 204 } else {
204 mlog(0, "Sending back orphaned slot %d for inode %"MLFu64"\n", 205 mlog(0, "Sending back orphaned slot %d for inode %llu\n",
205 OCFS2_I(inode)->ip_orphaned_slot, 206 OCFS2_I(inode)->ip_orphaned_slot,
206 OCFS2_I(inode)->ip_blkno); 207 (unsigned long long)OCFS2_I(inode)->ip_blkno);
207 208
208 *orphaned_slot = OCFS2_I(inode)->ip_orphaned_slot; 209 *orphaned_slot = OCFS2_I(inode)->ip_orphaned_slot;
209 } 210 }
@@ -226,8 +227,8 @@ static int ocfs2_process_delete_request(struct inode *inode,
226 } 227 }
227 228
228 if (filemap_fdatawrite(inode->i_mapping)) { 229 if (filemap_fdatawrite(inode->i_mapping)) {
229 mlog(ML_ERROR, "Could not sync inode %"MLFu64" for delete!\n", 230 mlog(ML_ERROR, "Could not sync inode %llu for delete!\n",
230 OCFS2_I(inode)->ip_blkno); 231 (unsigned long long)OCFS2_I(inode)->ip_blkno);
231 goto done; 232 goto done;
232 } 233 }
233 sync_mapping_buffers(inode->i_mapping); 234 sync_mapping_buffers(inode->i_mapping);
@@ -302,8 +303,8 @@ static void ocfs2_process_dentry_request(struct inode *inode,
302 struct list_head *p; 303 struct list_head *p;
303 struct ocfs2_inode_info *oi = OCFS2_I(inode); 304 struct ocfs2_inode_info *oi = OCFS2_I(inode);
304 305
305 mlog(0, "parent %"MLFu64", namelen = %u, name = %.*s\n", parent_blkno, 306 mlog(0, "parent %llu, namelen = %u, name = %.*s\n",
306 namelen, namelen, name); 307 (unsigned long long)parent_blkno, namelen, namelen, name);
307 308
308 spin_lock(&dcache_lock); 309 spin_lock(&dcache_lock);
309 310
@@ -370,9 +371,10 @@ static void ocfs2_process_vote(struct ocfs2_super *osb,
370 if (request == OCFS2_VOTE_REQ_DELETE) 371 if (request == OCFS2_VOTE_REQ_DELETE)
371 orphaned_slot = be32_to_cpu(msg->md1.v_orphaned_slot); 372 orphaned_slot = be32_to_cpu(msg->md1.v_orphaned_slot);
372 373
373 mlog(0, "processing vote: request = %u, blkno = %"MLFu64", " 374 mlog(0, "processing vote: request = %u, blkno = %llu, "
374 "generation = %u, node_num = %u, priv1 = %u\n", request, 375 "generation = %u, node_num = %u, priv1 = %u\n", request,
375 blkno, generation, node_num, be32_to_cpu(msg->md1.v_generic1)); 376 (unsigned long long)blkno, generation, node_num,
377 be32_to_cpu(msg->md1.v_generic1));
376 378
377 if (!ocfs2_is_valid_vote_request(request)) { 379 if (!ocfs2_is_valid_vote_request(request)) {
378 mlog(ML_ERROR, "Invalid vote request %d from node %u\n", 380 mlog(ML_ERROR, "Invalid vote request %d from node %u\n",
@@ -419,11 +421,12 @@ static void ocfs2_process_vote(struct ocfs2_super *osb,
419 * we had not found an inode in the first place. */ 421 * we had not found an inode in the first place. */
420 if (inode->i_generation != generation) { 422 if (inode->i_generation != generation) {
421 mlog(0, "generation passed %u != inode generation = %u, " 423 mlog(0, "generation passed %u != inode generation = %u, "
422 "ip_flags = %x, ip_blkno = %"MLFu64", msg %"MLFu64", " 424 "ip_flags = %x, ip_blkno = %llu, msg %llu, i_count = %u, "
423 "i_count = %u, message type = %u\n", 425 "message type = %u\n", generation, inode->i_generation,
424 generation, inode->i_generation, OCFS2_I(inode)->ip_flags, 426 OCFS2_I(inode)->ip_flags,
425 OCFS2_I(inode)->ip_blkno, blkno, 427 (unsigned long long)OCFS2_I(inode)->ip_blkno,
426 atomic_read(&inode->i_count), request); 428 (unsigned long long)blkno, atomic_read(&inode->i_count),
429 request);
427 iput(inode); 430 iput(inode);
428 inode = NULL; 431 inode = NULL;
429 goto respond; 432 goto respond;
@@ -830,8 +833,9 @@ static void ocfs2_delete_response_cb(void *priv,
830 833
831 orphaned_slot = be32_to_cpu(resp->r_orphaned_slot); 834 orphaned_slot = be32_to_cpu(resp->r_orphaned_slot);
832 node = be32_to_cpu(resp->r_hdr.h_node_num); 835 node = be32_to_cpu(resp->r_hdr.h_node_num);
833 mlog(0, "node %d tells us that inode %"MLFu64" is orphaned in slot " 836 mlog(0, "node %d tells us that inode %llu is orphaned in slot %d\n",
834 "%d\n", node, OCFS2_I(inode)->ip_blkno, orphaned_slot); 837 node, (unsigned long long)OCFS2_I(inode)->ip_blkno,
838 orphaned_slot);
835 839
836 /* The other node may not actually know which slot the inode 840 /* The other node may not actually know which slot the inode
837 * is orphaned in. */ 841 * is orphaned in. */
@@ -845,9 +849,9 @@ static void ocfs2_delete_response_cb(void *priv,
845 spin_lock(&OCFS2_I(inode)->ip_lock); 849 spin_lock(&OCFS2_I(inode)->ip_lock);
846 mlog_bug_on_msg(OCFS2_I(inode)->ip_orphaned_slot != orphaned_slot && 850 mlog_bug_on_msg(OCFS2_I(inode)->ip_orphaned_slot != orphaned_slot &&
847 OCFS2_I(inode)->ip_orphaned_slot 851 OCFS2_I(inode)->ip_orphaned_slot
848 != OCFS2_INVALID_SLOT, "Inode %"MLFu64": Node %d " 852 != OCFS2_INVALID_SLOT, "Inode %llu: Node %d says it's "
849 "says it's orphaned in slot %d, we think it's in %d\n", 853 "orphaned in slot %d, we think it's in %d\n",
850 OCFS2_I(inode)->ip_blkno, 854 (unsigned long long)OCFS2_I(inode)->ip_blkno,
851 be32_to_cpu(resp->r_hdr.h_node_num), 855 be32_to_cpu(resp->r_hdr.h_node_num),
852 orphaned_slot, OCFS2_I(inode)->ip_orphaned_slot); 856 orphaned_slot, OCFS2_I(inode)->ip_orphaned_slot);
853 857
@@ -869,8 +873,8 @@ int ocfs2_request_delete_vote(struct inode *inode)
869 delete_cb.rc_cb = ocfs2_delete_response_cb; 873 delete_cb.rc_cb = ocfs2_delete_response_cb;
870 delete_cb.rc_priv = inode; 874 delete_cb.rc_priv = inode;
871 875
872 mlog(0, "Inode %"MLFu64", we start thinking orphaned slot is %d\n", 876 mlog(0, "Inode %llu, we start thinking orphaned slot is %d\n",
873 OCFS2_I(inode)->ip_blkno, orphaned_slot); 877 (unsigned long long)OCFS2_I(inode)->ip_blkno, orphaned_slot);
874 878
875 status = -ENOMEM; 879 status = -ENOMEM;
876 request = ocfs2_new_vote_request(osb, OCFS2_I(inode)->ip_blkno, 880 request = ocfs2_new_vote_request(osb, OCFS2_I(inode)->ip_blkno,
@@ -895,8 +899,8 @@ static void ocfs2_setup_unlink_vote(struct ocfs2_vote_msg *request,
895 * d_delete against it. Parent directory block and full name 899 * d_delete against it. Parent directory block and full name
896 * should suffice. */ 900 * should suffice. */
897 901
898 mlog(0, "unlink/rename request: parent: %"MLFu64" name: %.*s\n", 902 mlog(0, "unlink/rename request: parent: %llu name: %.*s\n",
899 OCFS2_I(parent)->ip_blkno, dentry->d_name.len, 903 (unsigned long long)OCFS2_I(parent)->ip_blkno, dentry->d_name.len,
900 dentry->d_name.name); 904 dentry->d_name.name);
901 905
902 request->v_unlink_parent = cpu_to_be64(OCFS2_I(parent)->ip_blkno); 906 request->v_unlink_parent = cpu_to_be64(OCFS2_I(parent)->ip_blkno);
@@ -1082,7 +1086,8 @@ static int ocfs2_handle_response_message(struct o2net_msg *msg,
1082 mlog(0, "received response message:\n"); 1086 mlog(0, "received response message:\n");
1083 mlog(0, "h_response_id = %u\n", response_id); 1087 mlog(0, "h_response_id = %u\n", response_id);
1084 mlog(0, "h_request = %u\n", be32_to_cpu(resp->r_hdr.h_request)); 1088 mlog(0, "h_request = %u\n", be32_to_cpu(resp->r_hdr.h_request));
1085 mlog(0, "h_blkno = %"MLFu64"\n", be64_to_cpu(resp->r_hdr.h_blkno)); 1089 mlog(0, "h_blkno = %llu\n",
1090 (unsigned long long)be64_to_cpu(resp->r_hdr.h_blkno));
1086 mlog(0, "h_generation = %u\n", be32_to_cpu(resp->r_hdr.h_generation)); 1091 mlog(0, "h_generation = %u\n", be32_to_cpu(resp->r_hdr.h_generation));
1087 mlog(0, "h_node_num = %u\n", node_num); 1092 mlog(0, "h_node_num = %u\n", node_num);
1088 mlog(0, "r_response = %d\n", response_status); 1093 mlog(0, "r_response = %d\n", response_status);
@@ -1138,8 +1143,8 @@ static int ocfs2_handle_vote_message(struct o2net_msg *msg,
1138 mlog(0, "h_response_id = %u\n", 1143 mlog(0, "h_response_id = %u\n",
1139 be32_to_cpu(work->w_msg.v_hdr.h_response_id)); 1144 be32_to_cpu(work->w_msg.v_hdr.h_response_id));
1140 mlog(0, "h_request = %u\n", be32_to_cpu(work->w_msg.v_hdr.h_request)); 1145 mlog(0, "h_request = %u\n", be32_to_cpu(work->w_msg.v_hdr.h_request));
1141 mlog(0, "h_blkno = %"MLFu64"\n", 1146 mlog(0, "h_blkno = %llu\n",
1142 be64_to_cpu(work->w_msg.v_hdr.h_blkno)); 1147 (unsigned long long)be64_to_cpu(work->w_msg.v_hdr.h_blkno));
1143 mlog(0, "h_generation = %u\n", 1148 mlog(0, "h_generation = %u\n",
1144 be32_to_cpu(work->w_msg.v_hdr.h_generation)); 1149 be32_to_cpu(work->w_msg.v_hdr.h_generation));
1145 mlog(0, "h_node_num = %u\n", 1150 mlog(0, "h_node_num = %u\n",