Make sure VNET init and uninit functions are not used outside the defined rangeDefine and use functions to test specific VNET states during shutdown.
This makes the code more readable and easier to maintain.
MFC after: 1 week
Sponsored by: Mellanox Technologies