[dpdk-stable] [dpdk-dev] [PATCH 2/2] net/bonding: fix oob access in "other" aggregator modes

David Marchand david.marchand at redhat.com
Sun Mar 24 19:01:28 CET 2019


On Sun, Mar 24, 2019 at 6:24 PM Chas Williams <3chas3 at gmail.com> wrote:

> On 3/24/19 1:11 PM, David Marchand wrote:
> > On Sun, Mar 24, 2019 at 2:35 PM Chas Williams <3chas3 at gmail.com
> > <mailto:3chas3 at gmail.com>> wrote:
> >
> >     Have you ever experienced this problem in practice? I ask because I
> am
> >     considering some fixes that would limit the number of slaves to a
> more
> >     reasonable number (and reduce the over stack usage of the bonding
> >     driver
> >     in general).
> >
> >
> > Not too hard to reproduce, the problem is not the number of slaves.
> > With a default RTE_MAX_ETHPORTS at 32, any slave whose portid >= 8 would
> > trigger an oob access.
> Err... Well I have a lot of questions then about this whole thing.  What
> is max_index() doing?
>
>                  mode_count_id = max_index(agg_count, slaves_count);
>
> It's indexing up to slaves_count, which is likely to be somewhere around
> 2. agg_count() is indexed by the port id. It's likely agg_count was
> intended to be indexed by the slave index and not the port id.
>

Good point, it is likely that this whole code is not working at all...
I did not go far enough to test/verify this part functionally.



-- 
David Marchand


More information about the stable mailing list