Re: [dpdk-dev] [PATCH] net/mlx5: fix location of assert function

2020-04-29 Thread Raslan Darawsheh
Hi, > -Original Message- > From: dev On Behalf Of Asaf Penso > Sent: Thursday, April 16, 2020 8:15 PM > To: dev@dpdk.org > Cc: Slava Ovsiienko ; Dekel Peled > ; sta...@dpdk.org > Subject: [dpdk-dev] [PATCH] net/mlx5: fix location of assert function > > The

[dpdk-dev] [PATCH] net/mlx5: fix location of assert function

2020-04-16 Thread Asaf Penso
The asserts makes sure that 'i' doesn't exceed the exepcted value. This to prevent an out of bound access to dbr_bitmap. The current location of the assert protects the assignment of dbr_bitmap, but not the access to it. Moved the assert to the correct place, to protect both cases. Also, used an