RE: [PATCH v2 net-next 09/14] net: enetc: save the parsed information of PTP packet to skb->cb
From: Wei Fang
Date: Thu Jul 17 2025 - 08:20:44 EST
> > - old_sec_h = *(__be16 *)(data + offset2);
> > + old_sec_h = *(__be16 *)(data + tstamp_off);
> > inet_proto_csum_replace2(&uh->check, skb, old_sec_h,
> > new_sec_h, false);
> >
> > - old_sec_l = *(__be32 *)(data + offset2 + 2);
> > + old_sec_l = *(__be32 *)(data + tstamp_off + 2);
> > inet_proto_csum_replace4(&uh->check, skb, old_sec_l,
> > new_sec_l, false);
> >
> > - old_nsec = *(__be32 *)(data + offset2 + 6);
> > + old_nsec = *(__be32 *)(data + tstamp_off + 6);
> > inet_proto_csum_replace4(&uh->check, skb, old_nsec,
> > new_nsec, false);
> > }
> >
> > - *(__be16 *)(data + offset2) = new_sec_h;
> > - *(__be32 *)(data + offset2 + 2) = new_sec_l;
> > - *(__be32 *)(data + offset2 + 6) = new_nsec;
> > + *(__be16 *)(data + tstamp_off) = new_sec_h;
> > ++ *(__be32 *)(data + tstamp_off + 2) = new_sec_l;
> > ++ *(__be32 *)(data + tstamp_off + 6) = new_nsec;
>
> strange why there are two ++ here.
I do not know, I will fix it, thanks