mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-06 10:00:17 +00:00
nvme-auth: update bi_directional flag
[ Upstream commit6ff1bd7846] 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:e88a7595b5("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> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
918a399501
commit
e11fba0240
@@ -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) {
|
||||
|
||||
Reference in New Issue
Block a user