net/bnxt: ensure entry length is unsigned
authorJohn W. Linville <linville@tuxdriver.com>
Thu, 29 Sep 2016 17:39:34 +0000 (13:39 -0400)
committerBruce Richardson <bruce.richardson@intel.com>
Thu, 13 Oct 2016 13:30:59 +0000 (15:30 +0200)
commite8a197d2aa9a7375961a1e7356dfc5265a382158
tree286d7117214b8098dca14271b8431ecad37265a5
parent103bb1cc29614a3b4a901d5ef3eef47294b399dc
net/bnxt: ensure entry length is unsigned

Otherwise, the inherent cast when multiplying entry_length by max_vnics
in the call to rte_memzone_reserve could promote max_vnics to a signed
value, causing hilarity to ensue...

Coverity issue: 127557
Fixes: 9738793f28ec ("net/bnxt: add VNIC functions and structs")

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
drivers/net/bnxt/bnxt_vnic.c