projects
/
linux-2.6-microblaze.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
Merge branch 'mhi-net-immutable' of https://git.kernel.org/pub/scm/linux/kernel/git...
[linux-2.6-microblaze.git]
/
tools
/
testing
/
selftests
/
drivers
/
net
/
mlxsw
/
spectrum-2
/
port_scale.sh
1
# SPDX-License-Identifier: GPL-2.0
2
source ../port_scale.sh
3
4
port_get_target()
5
{
6
local should_fail=$1
7
local target
8
9
target=$(devlink_resource_size_get physical_ports)
10
11
if ((! should_fail)); then
12
echo $target
13
else
14
echo $((target + 1))
15
fi
16
}