summaryrefslogtreecommitdiffstats
path: root/net/ceph
diff options
context:
space:
mode:
authorIlya Dryomov <idryomov@gmail.com>2018-10-13 11:36:52 +0200
committerIlya Dryomov <idryomov@gmail.com>2018-10-22 10:28:21 +0200
commit41a264e1b30ccde9ac83a314559ddacb78a85e91 (patch)
tree91bdc6cfed36278bb9cb667793b5b7df62f62ef9 /net/ceph
parent668028844174aa7069da1f8ea89a5dbc93e86216 (diff)
downloadlinux-41a264e1b30ccde9ac83a314559ddacb78a85e91.tar.bz2
libceph: no need to call osd_req_opcode_valid() in osd_req_encode_op()
Any uninitialized or unknown ops will be caught by the default clause anyway. Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'net/ceph')
-rw-r--r--net/ceph/osd_client.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/net/ceph/osd_client.c b/net/ceph/osd_client.c
index ad00495dbd39..f403a483d51d 100644
--- a/net/ceph/osd_client.c
+++ b/net/ceph/osd_client.c
@@ -903,12 +903,6 @@ static void ceph_osdc_msg_data_add(struct ceph_msg *msg,
static u32 osd_req_encode_op(struct ceph_osd_op *dst,
const struct ceph_osd_req_op *src)
{
- if (WARN_ON(!osd_req_opcode_valid(src->op))) {
- pr_err("unrecognized osd opcode %d\n", src->op);
-
- return 0;
- }
-
switch (src->op) {
case CEPH_OSD_OP_STAT:
break;