3acb3b5d83a63fb24c126220a3480c58d22c605a
[openwrt/staging/xback.git] /
1 From 0e5f9f0a7f0ef1947984cd82ade9dbc14ba2c80d Mon Sep 17 00:00:00 2001
2 From: Ioana Ciornei <ioana.ciornei@nxp.com>
3 Date: Wed, 25 Oct 2017 12:48:04 +0000
4 Subject: [PATCH 12/12] scripts: replace 'nproc' with cross-platform
5 implementation
6
7 Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
8 ---
9 scripts/ls-main | 2 +-
10 1 file changed, 1 insertion(+), 1 deletion(-)
11
12 diff --git a/scripts/ls-main b/scripts/ls-main
13 index 526c052..7d127f6 100755
14 --- a/scripts/ls-main
15 +++ b/scripts/ls-main
16 @@ -807,7 +807,7 @@ process_addni() {
17 # if no --num-queues is specified then set it to number of cores
18 num_queues_present=$(echo "$dpni_args" | grep -o "\-\-num-queues" || true)
19 if [[ -z "$num_queues_present" ]]; then
20 - dpni_args=$dpni_args" --num-queues="$(nproc)
21 + dpni_args=$dpni_args" --num-queues="$(grep -c ^processor /proc/cpuinfo)
22 fi
23
24 # Check if --no-link the endpoint have been provided otherwise display the usage
25 --
26 2.14.1
27