]> git.baikalelectronics.ru Git - kernel.git/commit
net: hns3: clean up a type mismatch warning
authorGuojia Liao <liaoguojia@huawei.com>
Mon, 30 Aug 2021 13:51:07 +0000 (21:51 +0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 31 Aug 2021 11:36:42 +0000 (12:36 +0100)
commite79c0e324b011b0288cd411a5b53870a7730f163
treeed82568cc131a52b26deeed6bdea846f049c4748
parentdc9b5ce03124cf86bac3bd714369a8387d6e2012
net: hns3: clean up a type mismatch warning

abs() returns signed long, which could not convert the type
as unsigned, and it may cause a mismatch type warning from
static tools. To fix it, this patch uses an variable to save
the abs()'s result and does a explicit conversion.

Signed-off-by: Guojia Liao <liaoguojia@huawei.com>
Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_mbx.c