From: Jakub Kicinski <kuba@kernel.org>
To: David Hunter <david.hunter.linux@gmail.com>
Cc: "David S . Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Paolo Abeni <pabeni@redhat.com>, Shuah Khan <shuah@kernel.org>,
netdev@vger.kernel.org, linux-kselftest@vger.kernel.org,
linux-kernel@vger.kernel.org,
Javier Carrasco <javier.carrasco.cruz@gmail.com>
Subject: Re: [PATCH 1/1 V2] Selftests: net: Improve missing modules error message
Date: Mon, 26 Aug 2024 08:50:10 -0700 [thread overview]
Message-ID: <20240826085010.27ff4377@kernel.org> (raw)
In-Reply-To: <20240823054833.144612-1-david.hunter.linux@gmail.com>
On Fri, 23 Aug 2024 01:48:30 -0400 David Hunter wrote:
> Subject: [PATCH 1/1 V2] Selftests: net: Improve missing modules error message
don't capitalize the prefix
> The error message descirbing the required modules is inaccurate.
spellcheck the commit message, please
> Currently, only "SKIP: Need act_mirred module" is printed when any of
> the modules are missing. As a result, users might only include that
> module; however, three modules are required.
> needed_mods="act_mirred cls_flower sch_ingress"
> +mods_missing=""
> +numb_mods_needed=0;
trailing semicolon
> +
> for mod in $needed_mods; do
> - modinfo $mod &>/dev/null || { echo "SKIP: Need act_mirred module"; exit $ksft_skip; }
> + modinfo $mod &>/dev/null ||
> + { mods_missing="$mods_missing$mod " ; numb_mods_needed=$(expr $numb_mods_needed + 1);}
this is getting too long, use a "&& continue" instead of ||
> done
>
> +if [[ $numb_mods_needed>0 ]]; then
no need to use [[]], -gt
> + echo "SKIP: $numb_mods_needed modules needed: $mods_missing" ; exit $ksft_skip;
why single line with semicolons, it can be two lines
> +fi
> +
> +
--
pw-bot: cr
next prev parent reply other threads:[~2024-08-26 15:50 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-23 5:48 [PATCH 1/1 V2] Selftests: net: Improve missing modules error message David Hunter
2024-08-26 15:50 ` Jakub Kicinski [this message]
2024-08-27 20:56 ` [PATCH 1/1 V3] selftests: net: improve " David Hunter
2024-08-27 21:06 ` Jakub Kicinski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240826085010.27ff4377@kernel.org \
--to=kuba@kernel.org \
--cc=davem@davemloft.net \
--cc=david.hunter.linux@gmail.com \
--cc=edumazet@google.com \
--cc=javier.carrasco.cruz@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=shuah@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).