Whamcloud - gitweb
LU-16215 kfilnd: Use immediate for routed GETs 87/48787/3
authorChris Horn <chris.horn@hpe.com>
Mon, 3 Oct 2022 20:46:55 +0000 (14:46 -0600)
committerOleg Drokin <green@whamcloud.com>
Tue, 8 Nov 2022 08:52:40 +0000 (08:52 +0000)
struct lnet_msg::msg_md is NULL on routed GETs (or GETs being sent
to a router). As such we need to use immediate sends for these.

HPE-bug-id: LUS-11268
Test-Parameters: trivial
Signed-off-by: Chris Horn <chris.horn@hpe.com>
Change-Id: I69db5ec36a04b2a2a78d3e1a1b506eefbe8c6484
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/48787
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Ron Gredvig <ron.gredvig@hpe.com>
Reviewed-by: Ian Ziemba <ian.ziemba@hpe.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/klnds/kfilnd/kfilnd.c

index 5213a65..4ad1a1f 100644 (file)
@@ -107,6 +107,11 @@ static int kfilnd_send(struct lnet_ni *ni, void *private, struct lnet_msg *msg)
                break;
 
        case LNET_MSG_GET:
+               if (msg->msg_routing || msg->msg_target_is_router) {
+                       lnd_msg_type = KFILND_MSG_IMMEDIATE;
+                       break;
+               }
+
                nob = offsetof(struct kfilnd_msg,
                               proto.immed.payload[msg->msg_md->md_length]);
                if (nob <= KFILND_IMMEDIATE_MSG_SIZE) {