repo.or.cz
/
linux
/
fpc-iii.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
staging: rtl8192u: remove redundant assignment to pointer crypt
[linux/fpc-iii.git]
/
tools
/
testing
/
selftests
/
drivers
/
net
/
mlxsw
/
spectrum
/
router_scale.sh
blob
21c4697d5bab310ecb86fbbb7a7408739c1022e9
1
# SPDX-License-Identifier: GPL-2.0
2
source
..
/
router_scale.sh
3
4
router_get_target
()
5
{
6
local
should_fail
=
$1
7
local
target
8
9
target
=
$
(
devlink_resource_size_get kvd hash_single
)
10
11
if
[[
$should_fail
-eq
0
]];
then
12
target
=
$
((
target
*
85
/
100
))
13
else
14
target
=
$
((
target
+
1
))
15
fi
16
17
echo
$target
18
}