Re: [PATCH] tcp provider: use __ip_queue_xmit() as it is non-static on 5.4
Eugene Loh <[email protected]>
| Newsgroups | dev.linux.lists.dtrace |
|---|---|
| Message-ID | <[email protected]> |
Reviewed-by: Eugene Loh <[email protected]> It tests fine. Thanks. Looking forward to the "state" fix! On 8/25/25 13:16, Alan Maguire wrote: > On older kernels - 5.4 to be precise - ip_queue_xmit() is a static > function, so it is better to instrument __ip_queue_xmit() as it > is extern so not prone to optimization on 5.4 and later kernels. > With this change, the following previously-failing-on-UEK6U3 tcp tests > pass (and continue to pass when tested on an upstream kernel): > > tst.ipv4localtcp.sh > tst.ipv4remotetcp.sh > tst.ipv6localtcp.sh > > More work is required to fix up the tcpstate tests for UEK6U3. > > Reported-by: Eugene Loh <[email protected]> > Signed-off-by: Alan Maguire <[email protected]> > --- > libdtrace/dt_prov_tcp.c | 7 +++++-- > 1 file changed, 5 insertions(+), 2 deletions(-) > > diff --git a/libdtrace/dt_prov_tcp.c b/libdtrace/dt_prov_tcp.c > index ebdcfbc9..a191efe1 100644 > --- a/libdtrace/dt_prov_tcp.c > +++ b/libdtrace/dt_prov_tcp.c > @@ -37,7 +37,10 @@ static probe_dep_t probes[] = { > { "connect-refused", > DTRACE_PROBESPEC_NAME, "fbt::tcp_reset:entry" }, > { "connect-request", > - DTRACE_PROBESPEC_NAME, "fbt::ip_queue_xmit:entry" }, > + /* ip_queue_xmit() is static for older kernels so use __ip_queue_xmit() > + * which is non-static for older and newer kernels. > + */ > + DTRACE_PROBESPEC_NAME, "fbt::__ip_queue_xmit:entry" }, > /* ip6_xmit has > 6 args so cannot fentry on aarch64; use rawfbt */ > { "connect-request", > DTRACE_PROBESPEC_NAME, "rawfbt::ip6_xmit:entry" }, > @@ -48,7 +51,7 @@ static probe_dep_t probes[] = { > { "receive", > DTRACE_PROBESPEC_NAME, "fbt::tcp_v4_send_reset:entry" }, > { "send", > - DTRACE_PROBESPEC_NAME, "fbt::ip_queue_xmit:entry" }, > + DTRACE_PROBESPEC_NAME, "fbt::__ip_queue_xmit:entry" }, > /* ip_send_unicast_reply has 10 args so cannot fentry; use rawfbt */ > { "send", > DTRACE_PROBESPEC_NAME, "rawfbt::ip_send_unicast_reply:entry" },