0001
0002
0003
0004
0005
0006
0007
0008 #ifndef __NFC_LLC_H_
0009 #define __NFC_LLC_H_
0010
0011 #include <net/nfc/hci.h>
0012 #include <linux/skbuff.h>
0013
0014 #define LLC_NOP_NAME "nop"
0015 #define LLC_SHDLC_NAME "shdlc"
0016
0017 typedef void (*rcv_to_hci_t) (struct nfc_hci_dev *hdev, struct sk_buff *skb);
0018 typedef int (*xmit_to_drv_t) (struct nfc_hci_dev *hdev, struct sk_buff *skb);
0019 typedef void (*llc_failure_t) (struct nfc_hci_dev *hdev, int err);
0020
0021 struct nfc_llc;
0022
0023 struct nfc_llc *nfc_llc_allocate(const char *name, struct nfc_hci_dev *hdev,
0024 xmit_to_drv_t xmit_to_drv,
0025 rcv_to_hci_t rcv_to_hci, int tx_headroom,
0026 int tx_tailroom, llc_failure_t llc_failure);
0027 void nfc_llc_free(struct nfc_llc *llc);
0028
0029 int nfc_llc_start(struct nfc_llc *llc);
0030 int nfc_llc_stop(struct nfc_llc *llc);
0031 void nfc_llc_rcv_from_drv(struct nfc_llc *llc, struct sk_buff *skb);
0032 int nfc_llc_xmit_from_hci(struct nfc_llc *llc, struct sk_buff *skb);
0033
0034 int nfc_llc_init(void);
0035 void nfc_llc_exit(void);
0036
0037 #endif