common/cnxk: use for loop in shaper profiles cleanup
authorGowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Fri, 21 Jan 2022 12:04:16 +0000 (17:34 +0530)
committerJerin Jacob <jerinj@marvell.com>
Sun, 23 Jan 2022 07:19:18 +0000 (08:19 +0100)
commit6a78d41e0765fe9107d61d609b1a4b9cf158acbd
tree4b41d3c67ec5e0e13a4cb19d3905d05b3d8c0c7e
parent132dac7536e9bb2be9d9edabc1752dca7b25279a
common/cnxk: use for loop in shaper profiles cleanup

In shaper profiles cleanup, Klockwork static analyzer tool reports
infinite loop although existing loop condition is alright.
False positive may be due to tqh_first not checked in loop,
hence switching to FOREACH_SAFE to make Klockwork happy.

Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Signed-off-by: Shijith Thotton <sthotton@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
drivers/common/cnxk/roc_nix_tm.c
drivers/common/cnxk/roc_platform.h