========== shellcheck - FAILED ====== Checking before the patch ====== ====== Checking the tree with the patch ====== tools/testing/selftests/drivers/net/netdevsim/ethtool-rss.sh is a new file, but not shellcheck compliant New errors added --- /tmp/tmp.tl0Oy0nHt2 2026-03-03 13:56:29.806655145 -0500 +++ /tmp/tmp.mQIQwdy7d2 2026-03-03 13:56:29.969314345 -0500 @@ -0,0 +1,330 @@ + +In ethtool-rss.sh line 8: +source ethtool-common.sh + ^---------------^ SC1094 (warning): Parsing of sourced file failed. Ignoring it. + + +In ethtool-rss.sh line 16: +s=$(ethtool --json -x $NSIM_NETDEV | jq '.[0]["rss-indirection-table"] | length') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +s=$(ethtool --json -x "$NSIM_NETDEV" | jq '.[0]["rss-indirection-table"] | length') + + +In ethtool-rss.sh line 19: +ethtool -L $NSIM_NETDEV combined 2 + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -L "$NSIM_NETDEV" combined 2 + + +In ethtool-rss.sh line 20: +s=$(ethtool --json -x $NSIM_NETDEV | jq '.[0]["rss-indirection-table"] | length') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +s=$(ethtool --json -x "$NSIM_NETDEV" | jq '.[0]["rss-indirection-table"] | length') + + +In ethtool-rss.sh line 23: +ethtool -L $NSIM_NETDEV combined 8 + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -L "$NSIM_NETDEV" combined 8 + + +In ethtool-rss.sh line 26: +ethtool -X $NSIM_NETDEV equal 2 + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -X "$NSIM_NETDEV" equal 2 + + +In ethtool-rss.sh line 27: +s=$(ethtool --json -x $NSIM_NETDEV | jq '[.[0]["rss-indirection-table"][]] | max') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +s=$(ethtool --json -x "$NSIM_NETDEV" | jq '[.[0]["rss-indirection-table"][]] | max') + + +In ethtool-rss.sh line 30: +ethtool -L $NSIM_NETDEV combined 2 + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -L "$NSIM_NETDEV" combined 2 + + +In ethtool-rss.sh line 31: +s=$(ethtool --json -x $NSIM_NETDEV | jq '.[0]["rss-indirection-table"] | length') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +s=$(ethtool --json -x "$NSIM_NETDEV" | jq '.[0]["rss-indirection-table"] | length') + + +In ethtool-rss.sh line 33: +s=$(ethtool --json -x $NSIM_NETDEV | jq '[.[0]["rss-indirection-table"][]] | max') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +s=$(ethtool --json -x "$NSIM_NETDEV" | jq '[.[0]["rss-indirection-table"][]] | max') + + +In ethtool-rss.sh line 37: +ethtool -L $NSIM_NETDEV combined 8 + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -L "$NSIM_NETDEV" combined 8 + + +In ethtool-rss.sh line 38: +s=$(ethtool --json -x $NSIM_NETDEV | jq '.[0]["rss-indirection-table"] | length') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +s=$(ethtool --json -x "$NSIM_NETDEV" | jq '.[0]["rss-indirection-table"] | length') + + +In ethtool-rss.sh line 40: +s=$(ethtool --json -x $NSIM_NETDEV | jq '[.[0]["rss-indirection-table"][]] | max') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +s=$(ethtool --json -x "$NSIM_NETDEV" | jq '[.[0]["rss-indirection-table"][]] | max') + + +In ethtool-rss.sh line 43: +ethtool -X $NSIM_NETDEV default + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -X "$NSIM_NETDEV" default + + +In ethtool-rss.sh line 46: +ethtool -X $NSIM_NETDEV equal 8 + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -X "$NSIM_NETDEV" equal 8 + + +In ethtool-rss.sh line 48: +ethtool -L $NSIM_NETDEV combined 2 2>/dev/null + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -L "$NSIM_NETDEV" combined 2 2>/dev/null + + +In ethtool-rss.sh line 49: +if [ $? -ne 0 ]; then + ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. + + +In ethtool-rss.sh line 56: +ethtool -X $NSIM_NETDEV default + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -X "$NSIM_NETDEV" default + + +In ethtool-rss.sh line 59: +ctx_id=$(ethtool -X $NSIM_NETDEV context new equal 2 2>/dev/null | awk '{print $NF}') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ctx_id=$(ethtool -X "$NSIM_NETDEV" context new equal 2 2>/dev/null | awk '{print $NF}') + + +In ethtool-rss.sh line 63: + s=$(ethtool --json -x $NSIM_NETDEV context $ctx_id | jq '.[0]["rss-indirection-table"] | length') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: + s=$(ethtool --json -x "$NSIM_NETDEV" context "$ctx_id" | jq '.[0]["rss-indirection-table"] | length') + + +In ethtool-rss.sh line 66: + ethtool -L $NSIM_NETDEV combined 2 + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: + ethtool -L "$NSIM_NETDEV" combined 2 + + +In ethtool-rss.sh line 67: + s=$(ethtool --json -x $NSIM_NETDEV context $ctx_id | jq '.[0]["rss-indirection-table"] | length') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: + s=$(ethtool --json -x "$NSIM_NETDEV" context "$ctx_id" | jq '.[0]["rss-indirection-table"] | length') + + +In ethtool-rss.sh line 69: + s=$(ethtool --json -x $NSIM_NETDEV context $ctx_id | jq '[.[0]["rss-indirection-table"][]] | max') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: + s=$(ethtool --json -x "$NSIM_NETDEV" context "$ctx_id" | jq '[.[0]["rss-indirection-table"][]] | max') + + +In ethtool-rss.sh line 73: + ethtool -L $NSIM_NETDEV combined 8 + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: + ethtool -L "$NSIM_NETDEV" combined 8 + + +In ethtool-rss.sh line 74: + s=$(ethtool --json -x $NSIM_NETDEV context $ctx_id | jq '.[0]["rss-indirection-table"] | length') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: + s=$(ethtool --json -x "$NSIM_NETDEV" context "$ctx_id" | jq '.[0]["rss-indirection-table"] | length') + + +In ethtool-rss.sh line 76: + s=$(ethtool --json -x $NSIM_NETDEV context $ctx_id | jq '[.[0]["rss-indirection-table"][]] | max') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: + s=$(ethtool --json -x "$NSIM_NETDEV" context "$ctx_id" | jq '[.[0]["rss-indirection-table"][]] | max') + + +In ethtool-rss.sh line 79: + ethtool -X $NSIM_NETDEV context $ctx_id delete + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: + ethtool -X "$NSIM_NETDEV" context "$ctx_id" delete + + +In ethtool-rss.sh line 83: +ctx_id=$(ethtool -X $NSIM_NETDEV context new equal 8 2>/dev/null | awk '{print $NF}') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ctx_id=$(ethtool -X "$NSIM_NETDEV" context new equal 8 2>/dev/null | awk '{print $NF}') + + +In ethtool-rss.sh line 87: + ethtool -L $NSIM_NETDEV combined 2 2>/dev/null + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: + ethtool -L "$NSIM_NETDEV" combined 2 2>/dev/null + + +In ethtool-rss.sh line 88: + if [ $? -ne 0 ]; then + ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. + + +In ethtool-rss.sh line 95: + ethtool -X $NSIM_NETDEV context $ctx_id delete + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: + ethtool -X "$NSIM_NETDEV" context "$ctx_id" delete + + +In ethtool-rss.sh line 99: +ethtool -X $NSIM_NETDEV equal 8 + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -X "$NSIM_NETDEV" equal 8 + + +In ethtool-rss.sh line 100: +s_before=$(ethtool --json -x $NSIM_NETDEV | jq '.[0]["rss-indirection-table"]') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +s_before=$(ethtool --json -x "$NSIM_NETDEV" | jq '.[0]["rss-indirection-table"]') + + +In ethtool-rss.sh line 102: +ethtool -L $NSIM_NETDEV combined 2 2>/dev/null + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -L "$NSIM_NETDEV" combined 2 2>/dev/null + + +In ethtool-rss.sh line 103: +s_after=$(ethtool --json -x $NSIM_NETDEV | jq '.[0]["rss-indirection-table"]') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +s_after=$(ethtool --json -x "$NSIM_NETDEV" | jq '.[0]["rss-indirection-table"]') + + +In ethtool-rss.sh line 106: +ethtool -X $NSIM_NETDEV default + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -X "$NSIM_NETDEV" default + + +In ethtool-rss.sh line 109: +ethtool -X $NSIM_NETDEV equal 8 + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -X "$NSIM_NETDEV" equal 8 + + +In ethtool-rss.sh line 110: +ethtool -L $NSIM_NETDEV combined 2 2>/dev/null + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -L "$NSIM_NETDEV" combined 2 2>/dev/null + + +In ethtool-rss.sh line 111: +s=$(ethtool --json -l $NSIM_NETDEV | jq '.[0]["combined-count"]') + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +s=$(ethtool --json -l "$NSIM_NETDEV" | jq '.[0]["combined-count"]') + + +In ethtool-rss.sh line 114: +ethtool -X $NSIM_NETDEV default + ^----------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +ethtool -X "$NSIM_NETDEV" default + + +In ethtool-rss.sh line 117: +if [ $num_errors -eq 0 ]; then + ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. + +Did you mean: +if [ "$num_errors" -eq 0 ]; then + +For more information: + https://www.shellcheck.net/wiki/SC1094 -- Parsing of sourced file failed. I... + https://www.shellcheck.net/wiki/SC2086 -- Double quote to prevent globbing ... + https://www.shellcheck.net/wiki/SC2181 -- Check exit code directly with e.g...