btrfs: undo writable superblocke when sprouting fails
[linux/fpc-iii.git] / net / qrtr / qrtr.h
blob2b848718f8fefe5e13fd9e479298f2c78bca47f1
1 #ifndef __QRTR_H_
2 #define __QRTR_H_
4 #include <linux/types.h>
6 struct sk_buff;
8 /* endpoint node id auto assignment */
9 #define QRTR_EP_NID_AUTO (-1)
11 /**
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);
31 #endif