From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jesus Sanchez-Palencia Subject: [RFC v2 net-next 02/10] net: ipv4: raw: Hook into time based transmission. Date: Wed, 17 Jan 2018 15:06:13 -0800 Message-ID: <20180117230621.26074-3-jesus.sanchez-palencia@intel.com> References: <20180117230621.26074-1-jesus.sanchez-palencia@intel.com> Cc: jhs@mojatatu.com, xiyou.wangcong@gmail.com, jiri@resnulli.us, vinicius.gomes@intel.com, richardcochran@gmail.com, intel-wired-lan@lists.osuosl.org, anna-maria@linutronix.de, henrik@austad.us, tglx@linutronix.de, john.stultz@linaro.org, andre.guedes@intel.com, ivan.briano@intel.com, levi.pearson@harman.com, Richard Cochran , Jesus Sanchez-Palencia To: netdev@vger.kernel.org Return-path: Received: from mga06.intel.com ([134.134.136.31]:63122 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754041AbeAQXHm (ORCPT ); Wed, 17 Jan 2018 18:07:42 -0500 In-Reply-To: <20180117230621.26074-1-jesus.sanchez-palencia@intel.com> Sender: netdev-owner@vger.kernel.org List-ID: From: Richard Cochran For raw packets, copy the desired future transmit time from the CMSG cookie into the skb. Signed-off-by: Richard Cochran Signed-off-by: Jesus Sanchez-Palencia --- net/ipv4/raw.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/net/ipv4/raw.c b/net/ipv4/raw.c index 136544b36a46..e37ea8ab6a78 100644 --- a/net/ipv4/raw.c +++ b/net/ipv4/raw.c @@ -381,6 +381,7 @@ static int raw_send_hdrinc(struct sock *sk, struct flowi4 *fl4, skb->priority = sk->sk_priority; skb->mark = sk->sk_mark; + skb->tstamp = sockc->transmit_time; skb_dst_set(skb, &rt->dst); *rtp = NULL; @@ -562,6 +563,7 @@ static int raw_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.opt = NULL; ipc.tx_flags = 0; -- 2.15.1