Sync some patchs from upstreaming about a segment fault for
testpmd app and a IMP reset trigger for hns3 pmd. Patchs are
as follow:
- ethdev: add API to check if queue is valid
- app/testpmd: fix segment fault with invalid queue ID
- net/hns3: fix IMP reset trigger
(cherry picked from commit 06e0b2741afcd87d686d24608ecb3c974ea83f6d)