Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1733705 > unrolled thread
| Started by | Richard Cochran <rcochran@linutronix.de> |
|---|---|
| First post | 2017-09-18 09:50 +0200 |
| Last post | 2017-09-18 09:50 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH RFC V1 net-next 4/6] net: ipv4: udp: Hook into time based transmission. Richard Cochran <rcochran@linutronix.de> - 2017-09-18 09:50 +0200
| From | Richard Cochran <rcochran@linutronix.de> |
|---|---|
| Date | 2017-09-18 09:50 +0200 |
| Subject | [PATCH RFC V1 net-next 4/6] net: ipv4: udp: Hook into time based transmission. |
| Message-ID | <uqYYy-39L-9@gated-at.bofh.it> |
For udp packets, copy the desired future transmit time from the CMSG
cookie into the skb.
Signed-off-by: Richard Cochran <rcochran@linutronix.de>
---
net/ipv4/udp.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c
index ef29df8648e4..669f63495877 100644
--- a/net/ipv4/udp.c
+++ b/net/ipv4/udp.c
@@ -949,6 +949,7 @@ int udp_sendmsg(struct sock *sk, struct msghdr *msg, size_t len)
}
ipc.sockc.tsflags = sk->sk_tsflags;
+ ipc.sockc.transmit_time = 0;
ipc.addr = inet->inet_saddr;
ipc.oif = sk->sk_bound_dev_if;
@@ -1050,8 +1051,10 @@ int udp_sendmsg(struct sock *sk, struct msghdr *msg, size_t len)
sizeof(struct udphdr), &ipc, &rt,
msg->msg_flags);
err = PTR_ERR(skb);
- if (!IS_ERR_OR_NULL(skb))
+ if (!IS_ERR_OR_NULL(skb)) {
+ skb->transmit_time = ipc.sockc.transmit_time;
err = udp_send_skb(skb, fl4);
+ }
goto out;
}
--
2.11.0
Back to top | Article view | linux.kernel
csiph-web