Merge tag 'docs-5.13-2' of git://git.lwn.net/linux
[linux-2.6-microblaze.git] / drivers / rpmsg / qcom_glink_native.c
index 27a0516..05533c7 100644 (file)
@@ -857,6 +857,7 @@ static int qcom_glink_rx_data(struct qcom_glink *glink, size_t avail)
                        dev_err(glink->dev,
                                "no intent found for channel %s intent %d",
                                channel->name, liid);
+                       ret = -ENOENT;
                        goto advance_rx;
                }
        }
@@ -1332,6 +1333,20 @@ static int qcom_glink_trysend(struct rpmsg_endpoint *ept, void *data, int len)
        return __qcom_glink_send(channel, data, len, false);
 }
 
+static int qcom_glink_sendto(struct rpmsg_endpoint *ept, void *data, int len, u32 dst)
+{
+       struct glink_channel *channel = to_glink_channel(ept);
+
+       return __qcom_glink_send(channel, data, len, true);
+}
+
+static int qcom_glink_trysendto(struct rpmsg_endpoint *ept, void *data, int len, u32 dst)
+{
+       struct glink_channel *channel = to_glink_channel(ept);
+
+       return __qcom_glink_send(channel, data, len, false);
+}
+
 /*
  * Finds the device_node for the glink child interested in this channel.
  */
@@ -1364,7 +1379,9 @@ static const struct rpmsg_device_ops glink_device_ops = {
 static const struct rpmsg_endpoint_ops glink_endpoint_ops = {
        .destroy_ept = qcom_glink_destroy_ept,
        .send = qcom_glink_send,
+       .sendto = qcom_glink_sendto,
        .trysend = qcom_glink_trysend,
+       .trysendto = qcom_glink_trysendto,
 };
 
 static void qcom_glink_rpdev_release(struct device *dev)