From: Thomas Monjalon <thomas@monjalon.net>
To: dev@dpdk.org
Cc: Maxime Coquelin <maxime.coquelin@redhat.com>
Subject: [PATCH 2/6] devtools: remove superfluous fallbacks in uAPI script
Date: Wed, 27 Aug 2025 10:21:45 +0200 [thread overview]
Message-ID: <20250827082413.1417226-3-thomas@monjalon.net> (raw)
In-Reply-To: <20250827082413.1417226-1-thomas@monjalon.net>
The option -e was set on the script shebang (first line),
so the script will stop if an error is not caught.
Hence the explicit return or exit commands in case of error
were superfluous and can be removed.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
---
devtools/linux-uapi.sh | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/devtools/linux-uapi.sh b/devtools/linux-uapi.sh
index 2000152607..dc2f8bb36e 100755
--- a/devtools/linux-uapi.sh
+++ b/devtools/linux-uapi.sh
@@ -49,7 +49,7 @@ update_headers()
echo "Updating to $version"
for filename in $(find $base_path -name "*.h" -type f); do
header=${filename#$base_path}
- download_header $header $filename || return 1
+ download_header $header $filename
done
return 0
@@ -63,13 +63,13 @@ import_header()
local path="$base_path$header"
- download_header $header $path || return 1
+ download_header $header $path
for include in $(sed -ne 's/^#include <\(.*\)>$/\1/p' $path); do
if [ ! -f "$base_path$include" ]; then
read -p "Import $include (y/n): " import && [ "$import" = 'y' ] || continue
echo "Importing $include for $path"
- import_header "$include" || return 1
+ import_header "$include"
fi
done
@@ -130,7 +130,7 @@ if [ -n "$version" ]; then
echo "Headers already up to date ($current_version >= $version)"
version=$current_version
else
- update_headers || exit 1
+ update_headers
fi
else
echo "Version not specified, using current version ($current_version)"
@@ -138,11 +138,11 @@ else
fi
if [ -n "$file" ]; then
- import_header $file || exit 1
+ import_header $file
fi
for filename in $(find $base_path -name "*.h" -type f); do
- fixup_includes $filename || exit 1
+ fixup_includes $filename
done
echo $version > $base_path/version
@@ -158,8 +158,8 @@ echo "Checking imported headers for version $version"
for filename in $(find $base_path -name "*.h" -type f); do
header=${filename#$base_path}
- download_header $header $tmpheader || exit 1
- fixup_includes $tmpheader || exit 1
+ download_header $header $tmpheader
+ fixup_includes $tmpheader
check_header $filename $tmpheader || errors=$((errors+1))
done
--
2.47.1
next prev parent reply other threads:[~2025-08-27 8:24 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-27 8:21 [PATCH 0/6] devtools: improve Linux " Thomas Monjalon
2025-08-27 8:21 ` [PATCH 1/6] devtools: remove superfluous curly braces in " Thomas Monjalon
2025-08-27 8:21 ` Thomas Monjalon [this message]
2025-08-27 8:21 ` [PATCH 3/6] devtools: move uAPI processing into functions Thomas Monjalon
2025-08-27 8:21 ` [PATCH 4/6] devtools: remove unused variables in uAPI script Thomas Monjalon
2025-08-27 8:21 ` [PATCH 5/6] devtools: make uAPI check exclusive to other options Thomas Monjalon
2025-08-27 8:21 ` [PATCH 6/6] devtools: add quiet mode in uAPI script Thomas Monjalon
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=20250827082413.1417226-3-thomas@monjalon.net \
--to=thomas@monjalon.net \
--cc=dev@dpdk.org \
--cc=maxime.coquelin@redhat.com \
/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).