Skip to content

Commit

Permalink
rpmsg: remove the address check in rpmsg_send/rpmsg_trysend
Browse files Browse the repository at this point in the history
since rpmsg_send_offchannel_raw already do the same validation

Signed-off-by: Xiang Xiao <[email protected]>
  • Loading branch information
xiaoxiang781216 committed May 5, 2020
1 parent 1812f55 commit c310169
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions lib/include/openamp/rpmsg.h
Original file line number Diff line number Diff line change
Expand Up @@ -146,8 +146,6 @@ int rpmsg_send_offchannel_raw(struct rpmsg_endpoint *ept, uint32_t src,
static inline int rpmsg_send(struct rpmsg_endpoint *ept, const void *data,
int len)
{
if (ept->dest_addr == RPMSG_ADDR_ANY)
return RPMSG_ERR_ADDR;
return rpmsg_send_offchannel_raw(ept, ept->addr, ept->dest_addr, data,
len, true);
}
Expand Down Expand Up @@ -216,8 +214,6 @@ static inline int rpmsg_send_offchannel(struct rpmsg_endpoint *ept,
static inline int rpmsg_trysend(struct rpmsg_endpoint *ept, const void *data,
int len)
{
if (ept->dest_addr == RPMSG_ADDR_ANY)
return RPMSG_ERR_ADDR;
return rpmsg_send_offchannel_raw(ept, ept->addr, ept->dest_addr, data,
len, false);
}
Expand Down

0 comments on commit c310169

Please sign in to comment.