FreeBSD Bugzilla – Attachment 226457 Details for
Bug 254695
Hyper-V + TCP_BBR: Kernel Panic: Assertion in_epoch(net_epoch_preempt) failed at netinet/tcp_lro.c:1180
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for testing
epoch.patch (text/plain), 2.05 KB, created by
Michael Tuexen
on 2021-07-14 12:30:55 UTC
(
hide
)
Description:
Patch for testing
Filename:
MIME Type:
Creator:
Michael Tuexen
Created:
2021-07-14 12:30:55 UTC
Size:
2.05 KB
patch
obsolete
>diff --git a/sys/netinet/tcp_lro.c b/sys/netinet/tcp_lro.c >index 23e64b29b29..d8a40d6119b 100644 >--- a/sys/netinet/tcp_lro.c >+++ b/sys/netinet/tcp_lro.c >@@ -1236,10 +1236,11 @@ tcp_lro_ack_valid(struct mbuf *m, struct tcphdr *th, uint32_t **ppts, bool *othe > static int > tcp_lro_flush_tcphpts(struct lro_ctrl *lc, struct lro_entry *le) > { >+ struct epoch_tracker et; > struct inpcb *inp; > struct tcpcb *tp; > struct mbuf **pp, *cmp, *mv_to; >- bool bpf_req, should_wake; >+ bool bpf_req, should_wake, needs_epoch; > > /* Check if packet doesn't belongs to our network interface. */ > if ((tcplro_stacks_wanting_mbufq == 0) || >@@ -1264,11 +1265,17 @@ tcp_lro_flush_tcphpts(struct lro_ctrl *lc, struct lro_entry *le) > IN6_IS_ADDR_UNSPECIFIED(&le->inner.data.s_addr.v6))) > return (TCP_LRO_CANNOT); > #endif >+ needs_epoch = !(lc->ifp->if_flags & IFF_KNOWSEPOCH); >+ if (needs_epoch) >+ NET_EPOCH_ENTER(et); > /* Lookup inp, if any. */ > inp = tcp_lro_lookup(lc->ifp, > (le->inner.data.lro_type == LRO_TYPE_NONE) ? &le->outer : &le->inner); >- if (inp == NULL) >+ if (inp == NULL) { >+ if (needs_epoch) >+ NET_EPOCH_EXIT(et); > return (TCP_LRO_CANNOT); >+ } > > counter_u64_add(tcp_inp_lro_locks_taken, 1); > >@@ -1280,6 +1287,8 @@ tcp_lro_flush_tcphpts(struct lro_ctrl *lc, struct lro_entry *le) > (inp->inp_flags & (INP_DROPPED | INP_TIMEWAIT)) || > (inp->inp_flags2 & INP_FREED)) { > INP_WUNLOCK(inp); >+ if (needs_epoch) >+ NET_EPOCH_EXIT(et); > return (TCP_LRO_CANNOT); > } > if ((inp->inp_irq_cpu_set == 0) && (lc->lro_cpu_is_set == 1)) { >@@ -1289,6 +1298,8 @@ tcp_lro_flush_tcphpts(struct lro_ctrl *lc, struct lro_entry *le) > /* Check if the transport doesn't support the needed optimizations. */ > if ((inp->inp_flags2 & (INP_SUPPORTS_MBUFQ | INP_MBUF_ACKCMP)) == 0) { > INP_WUNLOCK(inp); >+ if (needs_epoch) >+ NET_EPOCH_EXIT(et); > return (TCP_LRO_CANNOT); > } > >@@ -1333,6 +1344,8 @@ tcp_lro_flush_tcphpts(struct lro_ctrl *lc, struct lro_entry *le) > } > if (inp != NULL) > INP_WUNLOCK(inp); >+ if (needs_epoch) >+ NET_EPOCH_EXIT(et); > return (0); /* Success. */ > } > #endif
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 254695
:
223748
|
226456
| 226457