diff options
author | Martin George <martinus.gpy@gmail.com> | 2025-09-15 17:19:21 +0530 |
---|---|---|
committer | Keith Busch <kbusch@kernel.org> | 2025-09-15 08:26:30 -0700 |
commit | 6ff1bd7846680dfdaafc68d7fcd0ab7e3bcbc4a0 (patch) | |
tree | 91245c865ecd566f9f1659be65bd6e74acdc4d88 | |
parent | 34585dc649fb255b40075dab56af063c1bfc9933 (diff) |
nvme-auth: update bi_directional flag
While setting chap->s2 to zero as part of secure channel
concatenation, the host missed out to disable the bi_directional
flag to indicate that controller authentication is not requested.
Fix the same.
Fixes: e88a7595b57f ("nvme-tcp: request secure channel concatenation")
Signed-off-by: Martin George <marting@netapp.com>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Keith Busch <kbusch@kernel.org>
-rw-r--r-- | drivers/nvme/host/auth.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/nvme/host/auth.c b/drivers/nvme/host/auth.c index 201fc8809a62..012fcfc79a73 100644 --- a/drivers/nvme/host/auth.c +++ b/drivers/nvme/host/auth.c @@ -331,9 +331,10 @@ static int nvme_auth_set_dhchap_reply_data(struct nvme_ctrl *ctrl, } else { memset(chap->c2, 0, chap->hash_len); } - if (ctrl->opts->concat) + if (ctrl->opts->concat) { chap->s2 = 0; - else + chap->bi_directional = false; + } else chap->s2 = nvme_auth_get_seqnum(); data->seqnum = cpu_to_le32(chap->s2); if (chap->host_key_len) { |