4 #include <linux/types.h>
8 /* endpoint node id auto assignment */
9 #define QRTR_EP_NID_AUTO (-1)
12 * struct qrtr_endpoint - endpoint handle
13 * @xmit: Callback for outgoing packets
15 * The socket buffer passed to the xmit function becomes owned by the endpoint
16 * driver. As such, when the driver is done with the buffer, it should
17 * call kfree_skb() on failure, or consume_skb() on success.
19 struct qrtr_endpoint
{
20 int (*xmit
)(struct qrtr_endpoint
*ep
, struct sk_buff
*skb
);
21 /* private: not for endpoint use */
22 struct qrtr_node
*node
;
25 int qrtr_endpoint_register(struct qrtr_endpoint
*ep
, unsigned int nid
);
27 void qrtr_endpoint_unregister(struct qrtr_endpoint
*ep
);
29 int qrtr_endpoint_post(struct qrtr_endpoint
*ep
, const void *data
, size_t len
);