[dpdk-dev] [PATCH v2 5/7] net/mlx5: add port representor awareness
Adrien Mazarguil
adrien.mazarguil at 6wind.com
Wed Jun 27 15:32:03 CEST 2018
On Sat, Jun 16, 2018 at 08:37:14AM +0000, Xueming(Steven) Li wrote:
> Reviewed-by: Xueming Li <xuemingl at mellanox.com>
>
> One minor issue we should be able to ignore.
<snip>
> > +static int
> > +mlx5_cmp_ibv_name(const void *a, const void *b) {
> > + const char *name_a = (*(const struct ibv_device *const *)a)->name;
> > + const char *name_b = (*(const struct ibv_device *const *)b)->name;
> > + size_t i = 0;
> > +
> > + while (name_a[i] && name_a[i] == name_b[i])
> > + ++i;
> > + while (i && isdigit(name_a[i - 1]) && isdigit(name_b[i - 1]))
>
> name_a[i - 1] and name_b[i - 1] must be same here.
Indeed, I'll simplify it in v3, thanks.
--
Adrien Mazarguil
6WIND
More information about the dev
mailing list