Skip to contentSkip to conversation

tcp: remove SG-related comment in tcp_sendmsg()

PATCH Superseded Julian Wiedmann 3 participants 4 messages Jul 6, 2018 – Jul 9, 2018

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tcp: remove SG-related comment in tcp_sendmsg()

Since commit 74d4a8f8d378 ("tcp: remove sk_can_gso() use"), the code doesn't care whether the interface supports SG.

---
 net/ipv4/tcp.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
net/ipv4/tcp.c +1 -3
index bf461fa77ed6..516e89b57603 100644
@@ -1275,9 +1275,7 @@ int tcp_sendmsg_locked(struct sock *sk, struct msghdr *msg, size_t size)
 			int linear;
 
 new_segment:
-			/* Allocate new segment. If the interface is SG,
-			 * allocate skb fitting to single page.
-			 */
+			/* Allocate new segment. */
 			if (!sk_stream_memory_free(sk))
 				goto wait_for_sndbuf;
 
Signature · 1 line
2.16.4
#1 lore raw
Quoted 13 lines · Julian Wiedmann

Since commit 74d4a8f8d378 ("tcp: remove sk_can_gso() use"), the code doesn't care whether the interface supports SG.

---
 net/ipv4/tcp.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
net/ipv4/tcp.c +0 -0
index bf461fa77ed6..516e89b57603 100644

net/ipv4/tcp.c int tcp_sendmsg_locked(struct sock *sk, struct msghdr *msg, size_t size) · line 1278

Quoted 7 lines
net/ipv4/tcp.c +1 -3
@@ -1275,9 +1275,7 @@ int tcp_sendmsg_locked(struct sock *sk, struct msghdr *msg, size_t size)
 			int linear;
 
 new_segment:
-			/* Allocate new segment. If the interface is SG,
-			 * allocate skb fitting to single page.
-			 */
+			/* Allocate new segment. */

Hi Julian

Please remove the comment completely then, it is really just redundant after this label.

Thanks.

#2 lore raw

PATCH v2 1/1 tcp: remove SG-related comment in tcp_sendmsg()

Since commit 74d4a8f8d378 ("tcp: remove sk_can_gso() use"), the code doesn't care whether the interface supports SG.

---
v2: remove the whole comment (Eric)

 net/ipv4/tcp.c | 3 ---
 1 file changed, 3 deletions(-)
net/ipv4/tcp.c +0 -3
index bf461fa77ed6..6ce14f8e3562 100644
@@ -1275,9 +1275,6 @@ int tcp_sendmsg_locked(struct sock *sk, struct msghdr *msg, size_t size)
 			int linear;
 
 new_segment:
-			/* Allocate new segment. If the interface is SG,
-			 * allocate skb fitting to single page.
-			 */
 			if (!sk_stream_memory_free(sk))
 				goto wait_for_sndbuf;
 
Signature · 1 line
2.16.4