]> git.karo-electronics.de Git - karo-tx-linux.git/commit
cifs: cork the socket before a send and uncork it afterward
authorJeff Layton <jlayton@redhat.com>
Tue, 18 Sep 2012 23:20:35 +0000 (16:20 -0700)
committerJeff Layton <jlayton@redhat.com>
Tue, 18 Sep 2012 23:20:35 +0000 (16:20 -0700)
commitca979525615ccd8c9115b0ac831a77db7e7c53ff
treede905eb7b47d336f3b4afd81476e8bd94bed4061
parent18fe06ea131d72a2d22ed7929ebed2b88a9f2ff4
cifs: cork the socket before a send and uncork it afterward

We want to send SMBs as "atomically" as possible. Prior to sending any
data on the socket, cork it to make sure that no non-full frames go
out. Afterward, uncork it to make sure all of the data gets pushed out
to the wire.

Note that this more or less renders the socket=TCP_NODELAY mount option
obsolete. When TCP_CORK and TCP_NODELAY are used on the same socket,
TCP_NODELAY is essentially ignored.

Acked-by: Pavel Shilovsky <pshilovsky@samba.org>
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <smfrench@gmail.com>
fs/cifs/connect.c
fs/cifs/transport.c