[DTrace-devel] [PATCH 1/2] test: Fix tst.print.skb.r
Kris Van Hees
kris.van.hees at oracle.com
Fri Dec 22 18:01:31 UTC 2023
On Fri, Dec 22, 2023 at 04:05:56PM +0000, Alan Maguire via DTrace-devel wrote:
> On 22/12/2023 02:34, eugene.loh--- via DTrace-devel wrote:
> > From: Eugene Loh <eugene.loh at oracle.com>
>
> it might be worth picking another field to set to non-zero as the below
> fix won't work for upstream kernels which have the headers struct
> as a container for the network_header field; "unsigned char *head" or
> "refcount_t users" maybe?
This is one of the challenges of working with different kernel versions.
Some tests are a real pain when it comes to doing that.
> >
> > Signed-off-by: Eugene Loh <eugene.loh at oracle.com>
> > ---
> > test/unittest/print/tst.print.skb.r | 9 +--------
> > 1 file changed, 1 insertion(+), 8 deletions(-)
> >
> > diff --git a/test/unittest/print/tst.print.skb.r b/test/unittest/print/tst.print.skb.r
> > index f389bc4f..36559edd 100644
> > --- a/test/unittest/print/tst.print.skb.r
> > +++ b/test/unittest/print/tst.print.skb.r
> > @@ -1,14 +1,7 @@
> > {ptr} = *
> > (struct sk_buff) {
> > .len = (unsigned int)123,
> > - (struct) {
> > - (struct) {
> > - .network_header = (__u16)32,
> > - },
> > - .headers = (struct) {
> > - .network_header = (__u16)32,
> > - },
> > - },
> > + .network_header = (__u16)32,
> > .data = (unsigned char *){ptr},
> > }
> >
>
> _______________________________________________
> DTrace-devel mailing list
> DTrace-devel at oss.oracle.com
> https://oss.oracle.com/mailman/listinfo/dtrace-devel
More information about the DTrace-devel
mailing list