提交 192a734f 编写于 作者: E Eric Dumazet 提交者: Yang Yingliang

net: neigh: use long type to store jiffies delta

stable inclusion
from linux-4.19.99
commit d261a03d8cac78006f2f28c6f950429f1588fb07

--------------------------------

[ Upstream commit 9d027e3a ]

A difference of two unsigned long needs long storage.

Fixes: c7fb64db ("[NETLINK]: Neighbour table configuration and statistics via rtnetlink")
Signed-off-by: NEric Dumazet <edumazet@google.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
Signed-off-by: NSasha Levin <sashal@kernel.org>
Signed-off-by: NYang Yingliang <yangyingliang@huawei.com>
Signed-off-by: NLi Aichun <liaichun@huawei.com>
Reviewed-by: Nguodeqing <geffrey.guo@huawei.com>
Signed-off-by: NYang Yingliang <yangyingliang@huawei.com>
上级 e1208228
...@@ -1885,8 +1885,8 @@ static int neightbl_fill_info(struct sk_buff *skb, struct neigh_table *tbl, ...@@ -1885,8 +1885,8 @@ static int neightbl_fill_info(struct sk_buff *skb, struct neigh_table *tbl,
goto nla_put_failure; goto nla_put_failure;
{ {
unsigned long now = jiffies; unsigned long now = jiffies;
unsigned int flush_delta = now - tbl->last_flush; long flush_delta = now - tbl->last_flush;
unsigned int rand_delta = now - tbl->last_rand; long rand_delta = now - tbl->last_rand;
struct neigh_hash_table *nht; struct neigh_hash_table *nht;
struct ndt_config ndc = { struct ndt_config ndc = {
.ndtc_key_len = tbl->key_len, .ndtc_key_len = tbl->key_len,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册