Page MenuHomeFreeBSD

D36868.diff
No OneTemporary

D36868.diff

diff --git a/sys/net/bpf.c b/sys/net/bpf.c
--- a/sys/net/bpf.c
+++ b/sys/net/bpf.c
@@ -2265,6 +2265,7 @@
static int
bpf_gettime(struct bintime *bt, int tstype, struct mbuf *m)
{
+ struct timespec ts;
struct m_tag *tag;
int quality;
@@ -2273,6 +2274,11 @@
return (quality);
if (m != NULL) {
+ if ((m->m_flags & (M_PKTHDR | M_TSTMP)) == (M_PKTHDR | M_TSTMP)) {
+ mbuf_tstmp2timespec(m, &ts);
+ timespec2bintime(&ts, bt);
+ return (BPF_TSTAMP_EXTERN);
+ }
tag = m_tag_locate(m, MTAG_BPF, MTAG_BPF_TIMESTAMP, NULL);
if (tag != NULL) {
*bt = *(struct bintime *)(tag + 1);

File Metadata

Mime Type
text/plain
Expires
Thu, Oct 23, 4:22 AM (1 h, 2 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
24037852
Default Alt Text
D36868.diff (602 B)

Event Timeline