Skip to content
Commit 98fd5c72 authored by Sagi Grimberg's avatar Sagi Grimberg Committed by Keith Busch
Browse files

nvmet-tcp: set MSG_MORE only if we actually have more to send



When we send PDU data, we want to optimize the tcp stack
operation if we have more data to send. So when we set MSG_MORE
when:
- We have more fragments coming in the batch, or
- We have a more data to send in this PDU
- We don't have a data digest trailer
- We optimize with the SUCCESS flag and omit the NVMe completion
  (used if sq_head pointer update is disabled)

This addresses a regression in QD=1 with SUCCESS flag optimization
as we unconditionally set MSG_MORE when we didn't actually have
more data to send.

Fixes: 70583295 ("nvmet-tcp: implement C2HData SUCCESS optimization")
Reported-by: default avatarMark Wunderlich <mark.wunderlich@intel.com>
Tested-by: default avatarMark Wunderlich <mark.wunderlich@intel.com>
Signed-off-by: default avatarSagi Grimberg <sagi@grimberg.me>
Signed-off-by: default avatarKeith Busch <kbusch@kernel.org>
parent 9134ae2a
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment