gfs2: Use fs_* functions instead of pr_* function where we can
Before this patch, various errors and messages were reported using the pr_* functions: pr_err, pr_warn, pr_info, etc., but that does not tell you which gfs2 mount had the problem, which is often vital to debugging. This patch changes the calls from pr_* to fs_* in most of the messages so that the file system id is printed along with the message. Signed-off-by: Bob Peterson <rpeterso@redhat.com>
This commit is contained in:
@@ -494,7 +494,8 @@ retry:
|
||||
do_xmote(gl, gh, LM_ST_UNLOCKED);
|
||||
break;
|
||||
default: /* Everything else */
|
||||
pr_err("wanted %u got %u\n", gl->gl_target, state);
|
||||
fs_err(gl->gl_name.ln_sbd, "wanted %u got %u\n",
|
||||
gl->gl_target, state);
|
||||
GLOCK_BUG_ON(gl, 1);
|
||||
}
|
||||
spin_unlock(&gl->gl_lockref.lock);
|
||||
@@ -577,7 +578,7 @@ __acquires(&gl->gl_lockref.lock)
|
||||
gfs2_glock_queue_work(gl, 0);
|
||||
}
|
||||
else if (ret) {
|
||||
pr_err("lm_lock ret %d\n", ret);
|
||||
fs_err(sdp, "lm_lock ret %d\n", ret);
|
||||
GLOCK_BUG_ON(gl, !test_bit(SDF_SHUTDOWN,
|
||||
&sdp->sd_flags));
|
||||
}
|
||||
@@ -1064,13 +1065,13 @@ do_cancel:
|
||||
return;
|
||||
|
||||
trap_recursive:
|
||||
pr_err("original: %pSR\n", (void *)gh2->gh_ip);
|
||||
pr_err("pid: %d\n", pid_nr(gh2->gh_owner_pid));
|
||||
pr_err("lock type: %d req lock state : %d\n",
|
||||
fs_err(sdp, "original: %pSR\n", (void *)gh2->gh_ip);
|
||||
fs_err(sdp, "pid: %d\n", pid_nr(gh2->gh_owner_pid));
|
||||
fs_err(sdp, "lock type: %d req lock state : %d\n",
|
||||
gh2->gh_gl->gl_name.ln_type, gh2->gh_state);
|
||||
pr_err("new: %pSR\n", (void *)gh->gh_ip);
|
||||
pr_err("pid: %d\n", pid_nr(gh->gh_owner_pid));
|
||||
pr_err("lock type: %d req lock state : %d\n",
|
||||
fs_err(sdp, "new: %pSR\n", (void *)gh->gh_ip);
|
||||
fs_err(sdp, "pid: %d\n", pid_nr(gh->gh_owner_pid));
|
||||
fs_err(sdp, "lock type: %d req lock state : %d\n",
|
||||
gh->gh_gl->gl_name.ln_type, gh->gh_state);
|
||||
gfs2_dump_glock(NULL, gl);
|
||||
BUG();
|
||||
|
Reference in New Issue
Block a user