From: Thierry Reding <thierry.reding@kernel.org>
To: Thierry Reding <thierry.reding@kernel.org>
Cc: Jon Hunter <jonathanh@nvidia.com>, linux-tegra@vger.kernel.org
Subject: [PATCH] soc/tegra: bpmp: Use ENODEV instead of ENOTSUPP
Date: Thu, 26 Mar 2026 12:28:31 +0100 [thread overview]
Message-ID: <20260326112831.2783853-1-thierry.reding@kernel.org> (raw)
From: Thierry Reding <treding@nvidia.com>
ENOTSUPP is not a SUSV4 error code and checkpatch will warn about it.
It is also not very descriptive in the context of BPMP, so use the
ENODEV error code instead. For the stub implementations this is a more
accurate description of what the failure is.
Signed-off-by: Thierry Reding <treding@nvidia.com>
---
include/soc/tegra/bpmp.h | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/include/soc/tegra/bpmp.h b/include/soc/tegra/bpmp.h
index 822851ef4bf8..a33582590a3b 100644
--- a/include/soc/tegra/bpmp.h
+++ b/include/soc/tegra/bpmp.h
@@ -144,7 +144,7 @@ bool tegra_bpmp_mrq_is_supported(struct tegra_bpmp *bpmp, unsigned int mrq);
#else
static inline struct tegra_bpmp *tegra_bpmp_get(struct device *dev)
{
- return ERR_PTR(-ENOTSUPP);
+ return ERR_PTR(-ENODEV);
}
static inline struct tegra_bpmp *tegra_bpmp_get_with_id(struct device *dev,
@@ -156,16 +156,19 @@ static inline struct tegra_bpmp *tegra_bpmp_get_with_id(struct device *dev,
static inline void tegra_bpmp_put(struct tegra_bpmp *bpmp)
{
}
+
static inline int tegra_bpmp_transfer_atomic(struct tegra_bpmp *bpmp,
struct tegra_bpmp_message *msg)
{
- return -ENOTSUPP;
+ return -ENODEV;
}
+
static inline int tegra_bpmp_transfer(struct tegra_bpmp *bpmp,
struct tegra_bpmp_message *msg)
{
- return -ENOTSUPP;
+ return -ENODEV;
}
+
static inline void tegra_bpmp_mrq_return(struct tegra_bpmp_channel *channel,
int code, const void *data,
size_t size)
@@ -177,8 +180,9 @@ static inline int tegra_bpmp_request_mrq(struct tegra_bpmp *bpmp,
tegra_bpmp_mrq_handler_t handler,
void *data)
{
- return -ENOTSUPP;
+ return -ENODEV;
}
+
static inline void tegra_bpmp_free_mrq(struct tegra_bpmp *bpmp,
unsigned int mrq, void *data)
{
--
2.52.0
reply other threads:[~2026-03-26 11:28 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20260326112831.2783853-1-thierry.reding@kernel.org \
--to=thierry.reding@kernel.org \
--cc=jonathanh@nvidia.com \
--cc=linux-tegra@vger.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