aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/errqueue.h
diff options
context:
space:
mode:
authorSoheil Hassas Yeganeh <soheil@google.com>2017-03-18 17:03:00 -0400
committerDavid S. Miller <davem@davemloft.net>2017-03-21 18:44:17 -0700
commit4ef1b2869447411ad3ef91ad7d4891a83c1a509a (patch)
treeb9dc299784a3231231e21cf46df312b6b1c40c9d /include/linux/errqueue.h
parenttcp: fix SCM_TIMESTAMPING_OPT_STATS for normal skbs (diff)
downloadlinux-dev-4ef1b2869447411ad3ef91ad7d4891a83c1a509a.tar.xz
linux-dev-4ef1b2869447411ad3ef91ad7d4891a83c1a509a.zip
tcp: mark skbs with SCM_TIMESTAMPING_OPT_STATS
SOF_TIMESTAMPING_OPT_STATS can be enabled and disabled while packets are collected on the error queue. So, checking SOF_TIMESTAMPING_OPT_STATS in sk->sk_tsflags is not enough to safely assume that the skb contains OPT_STATS data. Add a bit in sock_exterr_skb to indicate whether the skb contains opt_stats data. Fixes: 1c885808e456 ("tcp: SOF_TIMESTAMPING_OPT_STATS option for SO_TIMESTAMPING") Reported-by: JongHwan Kim <zzoru007@gmail.com> Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/errqueue.h')
-rw-r--r--include/linux/errqueue.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/errqueue.h b/include/linux/errqueue.h
index 9ca23fcfb5d7..6fdfc884fdeb 100644
--- a/include/linux/errqueue.h
+++ b/include/linux/errqueue.h
@@ -20,6 +20,8 @@ struct sock_exterr_skb {
struct sock_extended_err ee;
u16 addr_offset;
__be16 port;
+ u8 opt_stats:1,
+ unused:7;
};
#endif