[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20210712123912.10672-1-arnaud.pouliquen@foss.st.com>
Date: Mon, 12 Jul 2021 14:39:12 +0200
From: Arnaud Pouliquen <arnaud.pouliquen@...s.st.com>
To: Bjorn Andersson <bjorn.andersson@...aro.org>,
Ohad Ben-Cohen <ohad@...ery.com>,
Mathieu Poirier <mathieu.poirier@...aro.org>
CC: <linux-remoteproc@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
<linux-stm32@...md-mailman.stormreply.com>,
<arnaud.pouliquen@...s.st.com>
Subject: [PATCH v2] rpmsg: Fix rpmsg_create_ept return when RPMSG config is not defined
This is a minor fix.
According to the description of the rpmsg_create_ept in rpmsg_core.c
the function should return NULL on error.
Signed-off-by: Arnaud Pouliquen <arnaud.pouliquen@...s.st.com>
Reviewed-by: Mathieu Poirier <mathieu.poirier@...aro.org>
---
update from V1:
- add Reviewed-by: Mathieu Poirier <mathieu.poirier@...aro.org>
- rebased on kernel V.14-rc1.
---
include/linux/rpmsg.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/rpmsg.h b/include/linux/rpmsg.h
index d97dcd049f18..a8dcf8a9ae88 100644
--- a/include/linux/rpmsg.h
+++ b/include/linux/rpmsg.h
@@ -231,7 +231,7 @@ static inline struct rpmsg_endpoint *rpmsg_create_ept(struct rpmsg_device *rpdev
/* This shouldn't be possible */
WARN_ON(1);
- return ERR_PTR(-ENXIO);
+ return NULL;
}
static inline int rpmsg_send(struct rpmsg_endpoint *ept, void *data, int len)
--
2.17.1
Powered by blists - more mailing lists