net: hns: fix unsigned comparison to less than zero
authorColin Ian King <colin.king@canonical.com>
Fri, 5 Apr 2019 13:59:16 +0000 (14:59 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 10 Jul 2019 07:53:46 +0000 (09:53 +0200)
commite6c288f7307e2bdaad54de00c3733b807539c753
treecbb358011b136c2bcc06c7cd47c879a1241f379d
parent4f24801ef50b05125371c55048695a9430b8f1a2
net: hns: fix unsigned comparison to less than zero

[ Upstream commit ea401685a20b5d631957f024bda86e1f6118eb20 ]

Currently mskid is unsigned and hence comparisons with negative
error return values are always false. Fix this by making mskid an
int.

Fixes: f058e46855dc ("net: hns: fix ICMP6 neighbor solicitation messages discard problem")
Addresses-Coverity: ("Operands don't affect result")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Reviewed-by: Mukesh Ojha <mojha@codeaurora.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c