summaryrefslogtreecommitdiffstats
path: root/xlators/protocol/client/src/client-common.c
diff options
context:
space:
mode:
authoryatip <ypadia@redhat.com>2020-02-03 17:36:00 +0530
committerAmar Tumballi <amar@kadalu.io>2020-03-03 11:56:44 +0000
commit48245df36c5dec40779355a36d7bb7689f9efe6d (patch)
tree1eeda3ac005002343d1e201849ed6e75ee03afb4 /xlators/protocol/client/src/client-common.c
parent1291667e26516d02e548207ba3df84c456a36b35 (diff)
protocol/client: structure logging
convert gf_msg() to gf_smsg() Updates: #657 Change-Id: I76a09cfd283bb4ec5c4358536da66547aaf0de31 Signed-off-by: yatip <ypadia@redhat.com>
Diffstat (limited to 'xlators/protocol/client/src/client-common.c')
-rw-r--r--xlators/protocol/client/src/client-common.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/xlators/protocol/client/src/client-common.c b/xlators/protocol/client/src/client-common.c
index 64db98d..db56b2d 100644
--- a/xlators/protocol/client/src/client-common.c
+++ b/xlators/protocol/client/src/client-common.c
@@ -714,8 +714,8 @@ client_pre_lk(xlator_t *this, gfs3_lk_req *req, int32_t cmd,
ret = client_cmd_to_gf_cmd(cmd, &gf_cmd);
if (ret) {
op_errno = EINVAL;
- gf_msg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_INVALID_ENTRY,
- "Unknown cmd (%d)!", gf_cmd);
+ gf_smsg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_UNKNOWN_CMD,
+ "gf_cmd=%d", gf_cmd, NULL);
goto out;
}
@@ -827,8 +827,8 @@ client_pre_inodelk(xlator_t *this, gfs3_inodelk_req *req, loc_t *loc, int cmd,
else if (cmd == F_SETLKW || cmd == F_SETLKW64)
gf_cmd = GF_LK_SETLKW;
else {
- gf_msg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_INVALID_ENTRY,
- "Unknown cmd (%d)!", gf_cmd);
+ gf_smsg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_UNKNOWN_CMD,
+ "gf_cmd=%d", gf_cmd, NULL);
op_errno = EINVAL;
goto out;
}
@@ -877,8 +877,8 @@ client_pre_finodelk(xlator_t *this, gfs3_finodelk_req *req, fd_t *fd, int cmd,
else if (cmd == F_SETLKW || cmd == F_SETLKW64)
gf_cmd = GF_LK_SETLKW;
else {
- gf_msg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_INVALID_ENTRY,
- "Unknown cmd (%d)!", gf_cmd);
+ gf_smsg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_UNKNOWN_CMD,
+ "gf_cmd=%d", gf_cmd, NULL);
goto out;
}
@@ -2895,8 +2895,8 @@ client_pre_lk_v2(xlator_t *this, gfx_lk_req *req, int32_t cmd,
ret = client_cmd_to_gf_cmd(cmd, &gf_cmd);
if (ret) {
op_errno = EINVAL;
- gf_msg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_INVALID_ENTRY,
- "Unknown cmd (%d)!", gf_cmd);
+ gf_smsg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_UNKNOWN_CMD,
+ "gf_cmd=%d", gf_cmd, NULL);
goto out;
}
@@ -3005,8 +3005,8 @@ client_pre_inodelk_v2(xlator_t *this, gfx_inodelk_req *req, loc_t *loc, int cmd,
else if (cmd == F_SETLKW || cmd == F_SETLKW64)
gf_cmd = GF_LK_SETLKW;
else {
- gf_msg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_INVALID_ENTRY,
- "Unknown cmd (%d)!", gf_cmd);
+ gf_smsg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_UNKNOWN_CMD,
+ "gf_cmd=%d", gf_cmd, NULL);
op_errno = EINVAL;
goto out;
}
@@ -3055,8 +3055,8 @@ client_pre_finodelk_v2(xlator_t *this, gfx_finodelk_req *req, fd_t *fd, int cmd,
else if (cmd == F_SETLKW || cmd == F_SETLKW64)
gf_cmd = GF_LK_SETLKW;
else {
- gf_msg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_INVALID_ENTRY,
- "Unknown cmd (%d)!", gf_cmd);
+ gf_smsg(this->name, GF_LOG_WARNING, EINVAL, PC_MSG_UNKNOWN_CMD,
+ "gf_cmd=%d", gf_cmd, NULL);
goto out;
}