> -----Original Message----- > From: Thomas Monjalon <tho...@monjalon.net> > Sent: Wednesday, April 7, 2021 12:23 AM > To: John Hurley <jhur...@nvidia.com>; Suanming Mou > <suanmi...@nvidia.com> > Cc: Ori Kam <or...@nvidia.com>; dev@dpdk.org; Slava Ovsiienko > <viachesl...@nvidia.com>; Matan Azrad <ma...@nvidia.com>; Raslan > Darawsheh <rasl...@nvidia.com> > Subject: Re: [dpdk-dev] [PATCH v3 4/4] regex/mlx5: prevent wrong calculation > of free sqs in umr mode > > 30/03/2021 03:39, Suanming Mou: > > From: John Hurley <jhur...@nvidia.com> > > > > A recent change adds support for scattered mbuf and UMR support for regex. > > Part of this commit makes the pi and ci counters of the regex_sq a > > quarter of the length in non umr mode, effectively moving them from 16 > > bits to 14. The new get_free method casts the difference in pi and ci > > to a 16 bit value when calculating the free send queues, accounting > > for any wrapping when pi has looped back to 0 but ci has not yet. > > However, the move to 14 bits while still casting to 16 can now lead to > > corrupted, large values returned. > > > > Modify the get_free function to take in the has_umr flag and, > > accordingly, account for wrapping on either 14 or 16 bit pi/ci difference. > > > > Fixes: d55c9f637263 ("regex/mlx5: add data path scattered mbuf > > process") > > It is fixing a patch in this series, right? > Why not squashing them?
Yes, this is a fix for this series. This fix was done by John when he tested the code, so I put it as an individual one. Should we update an new version to squash it? (And Thomas, the latest version of this series is v4, you comment in this old v3 version now :) ) > >