Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Enumerations | Functions
nci_core.h File Reference
#include <linux/interrupt.h>
#include <linux/skbuff.h>
#include <net/nfc/nfc.h>
#include <net/nfc/nci.h>

Go to the source code of this file.

Data Structures

struct  nci_ops
 
struct  nci_dev
 

Macros

#define NCI_RESET_TIMEOUT   5000
 
#define NCI_INIT_TIMEOUT   5000
 
#define NCI_SET_CONFIG_TIMEOUT   5000
 
#define NCI_RF_DISC_TIMEOUT   5000
 
#define NCI_RF_DISC_SELECT_TIMEOUT   5000
 
#define NCI_RF_DEACTIVATE_TIMEOUT   30000
 
#define NCI_CMD_TIMEOUT   5000
 
#define NCI_DATA_TIMEOUT   700
 
#define NCI_MAX_SUPPORTED_RF_INTERFACES   4
 
#define NCI_MAX_DISCOVERED_TARGETS   10
 
#define NCI_REQ_DONE   0
 
#define NCI_REQ_PEND   1
 
#define NCI_REQ_CANCELED   2
 

Enumerations

enum  nci_flag { NCI_INIT, NCI_UP, NCI_DATA_EXCHANGE, NCI_DATA_EXCHANGE_TO }
 
enum  nci_state {
  NCI_IDLE, NCI_DISCOVERY, NCI_W4_ALL_DISCOVERIES, NCI_W4_HOST_SELECT,
  NCI_POLL_ACTIVE
}
 

Functions

struct nci_devnci_allocate_device (struct nci_ops *ops, __u32 supported_protocols, int tx_headroom, int tx_tailroom)
 
void nci_free_device (struct nci_dev *ndev)
 
int nci_register_device (struct nci_dev *ndev)
 
void nci_unregister_device (struct nci_dev *ndev)
 
int nci_recv_frame (struct sk_buff *skb)
 
void nci_rsp_packet (struct nci_dev *ndev, struct sk_buff *skb)
 
void nci_ntf_packet (struct nci_dev *ndev, struct sk_buff *skb)
 
void nci_rx_data_packet (struct nci_dev *ndev, struct sk_buff *skb)
 
int nci_send_cmd (struct nci_dev *ndev, __u16 opcode, __u8 plen, void *payload)
 
int nci_send_data (struct nci_dev *ndev, __u8 conn_id, struct sk_buff *skb)
 
void nci_data_exchange_complete (struct nci_dev *ndev, struct sk_buff *skb, int err)
 
void nci_clear_target_list (struct nci_dev *ndev)
 
void nci_req_complete (struct nci_dev *ndev, int result)
 
int nci_to_errno (__u8 code)
 

Macro Definition Documentation

#define NCI_CMD_TIMEOUT   5000

Definition at line 61 of file nci_core.h.

#define NCI_DATA_TIMEOUT   700

Definition at line 62 of file nci_core.h.

#define NCI_INIT_TIMEOUT   5000

Definition at line 56 of file nci_core.h.

#define NCI_MAX_DISCOVERED_TARGETS   10

Definition at line 73 of file nci_core.h.

#define NCI_MAX_SUPPORTED_RF_INTERFACES   4

Definition at line 72 of file nci_core.h.

#define NCI_REQ_CANCELED   2

Definition at line 197 of file nci_core.h.

#define NCI_REQ_DONE   0

Definition at line 195 of file nci_core.h.

#define NCI_REQ_PEND   1

Definition at line 196 of file nci_core.h.

#define NCI_RESET_TIMEOUT   5000

Definition at line 55 of file nci_core.h.

#define NCI_RF_DEACTIVATE_TIMEOUT   30000

Definition at line 60 of file nci_core.h.

#define NCI_RF_DISC_SELECT_TIMEOUT   5000

Definition at line 59 of file nci_core.h.

#define NCI_RF_DISC_TIMEOUT   5000

Definition at line 58 of file nci_core.h.

#define NCI_SET_CONFIG_TIMEOUT   5000

Definition at line 57 of file nci_core.h.

Enumeration Type Documentation

enum nci_flag
Enumerator:
NCI_INIT 
NCI_UP 
NCI_DATA_EXCHANGE 
NCI_DATA_EXCHANGE_TO 

Definition at line 38 of file nci_core.h.

enum nci_state
Enumerator:
NCI_IDLE 
NCI_DISCOVERY 
NCI_W4_ALL_DISCOVERIES 
NCI_W4_HOST_SELECT 
NCI_POLL_ACTIVE 

Definition at line 46 of file nci_core.h.

Function Documentation

struct nci_dev* nci_allocate_device ( struct nci_ops ops,
__u32  supported_protocols,
int  tx_headroom,
int  tx_tailroom 
)
read

nci_allocate_device - allocate a new nci device

: device operations : NFC protocols supported by the device

Definition at line 662 of file core.c.

void nci_clear_target_list ( struct nci_dev ndev)

Definition at line 264 of file ntf.c.

void nci_data_exchange_complete ( struct nci_dev ndev,
struct sk_buff skb,
int  err 
)

Definition at line 38 of file data.c.

void nci_free_device ( struct nci_dev ndev)

nci_free_device - deallocate nci device

: The nci device to deallocate

Definition at line 706 of file core.c.

void nci_ntf_packet ( struct nci_dev ndev,
struct sk_buff skb 
)

Definition at line 567 of file ntf.c.

int nci_recv_frame ( struct sk_buff skb)

nci_recv_frame - receive frame from NCI drivers

: The sk_buff to receive

Definition at line 803 of file core.c.

int nci_register_device ( struct nci_dev ndev)

nci_register_device - register a nci device in the nfc subsystem

: The nci device to register

Definition at line 718 of file core.c.

void nci_req_complete ( struct nci_dev ndev,
int  result 
)

Definition at line 50 of file core.c.

void nci_rsp_packet ( struct nci_dev ndev,
struct sk_buff skb 
)

Definition at line 182 of file rsp.c.

void nci_rx_data_packet ( struct nci_dev ndev,
struct sk_buff skb 
)

Definition at line 233 of file data.c.

int nci_send_cmd ( struct nci_dev ndev,
__u16  opcode,
__u8  plen,
void payload 
)

Definition at line 841 of file core.c.

int nci_send_data ( struct nci_dev ndev,
__u8  conn_id,
struct sk_buff skb 
)

Definition at line 154 of file data.c.

int nci_to_errno ( __u8  code)

Definition at line 37 of file lib.c.

void nci_unregister_device ( struct nci_dev ndev)

nci_unregister_device - unregister a nci device in the nfc subsystem

: The nci device to unregister

Definition at line 786 of file core.c.