2 * Link Layer Control manager
4 * Copyright (C) 2012 Intel Corporation. All rights reserved.
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms and conditions of the GNU General Public License,
8 * version 2, as published by the Free Software Foundation.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the
17 * Free Software Foundation, Inc.,
18 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21 #ifndef __LOCAL_LLC_H_
22 #define __LOCAL_LLC_H_
24 #include <net/nfc/hci.h>
25 #include <net/nfc/llc.h>
26 #include <linux/skbuff.h>
29 void *(*init
) (struct nfc_hci_dev
*hdev
, xmit_to_drv_t xmit_to_drv
,
30 rcv_to_hci_t rcv_to_hci
, int tx_headroom
,
31 int tx_tailroom
, int *rx_headroom
, int *rx_tailroom
,
32 llc_failure_t llc_failure
);
33 void (*deinit
) (struct nfc_llc
*llc
);
34 int (*start
) (struct nfc_llc
*llc
);
35 int (*stop
) (struct nfc_llc
*llc
);
36 void (*rcv_from_drv
) (struct nfc_llc
*llc
, struct sk_buff
*skb
);
37 int (*xmit_from_hci
) (struct nfc_llc
*llc
, struct sk_buff
*skb
);
40 struct nfc_llc_engine
{
42 struct nfc_llc_ops
*ops
;
43 struct list_head entry
;
48 struct nfc_llc_ops
*ops
;
53 void *nfc_llc_get_data(struct nfc_llc
*llc
);
55 int nfc_llc_register(const char *name
, struct nfc_llc_ops
*ops
);
56 void nfc_llc_unregister(const char *name
);
58 int nfc_llc_nop_register(void);
60 #if defined(CONFIG_NFC_SHDLC)
61 int nfc_llc_shdlc_register(void);
63 static inline int nfc_llc_shdlc_register(void)
69 #endif /* __LOCAL_LLC_H_ */