mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-09-21 20:22:13 +08:00
sit: use min
commit 284fda1eff
upstream.
Opportunity for min()
Generated by: scripts/coccinelle/misc/minmax.cocci
CC: Denis Efremov <efremov@linux.com>
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: kernel test robot <lkp@intel.com>
Reviewed-by: David Ahern <dsahern@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
dd0d4f8cd8
commit
c4829dc5ce
@ -316,7 +316,7 @@ static int ipip6_tunnel_get_prl(struct ip_tunnel *t,
|
||||
|
||||
rcu_read_lock();
|
||||
|
||||
ca = t->prl_count < cmax ? t->prl_count : cmax;
|
||||
ca = min(t->prl_count, cmax);
|
||||
|
||||
if (!kp) {
|
||||
/* We don't try hard to allocate much memory for
|
||||
|
Loading…
Reference in New Issue
Block a user