Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Typedefs | Enumerations | Functions | Variables
irnet.h File Reference
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/skbuff.h>
#include <linux/tty.h>
#include <linux/proc_fs.h>
#include <linux/netdevice.h>
#include <linux/miscdevice.h>
#include <linux/poll.h>
#include <linux/capability.h>
#include <linux/ctype.h>
#include <linux/string.h>
#include <asm/uaccess.h>
#include <linux/init.h>
#include <linux/ppp_defs.h>
#include <linux/ppp-ioctl.h>
#include <linux/ppp_channel.h>
#include <net/irda/irda.h>
#include <net/irda/iriap.h>
#include <net/irda/irias_object.h>
#include <net/irda/irlmp.h>
#include <net/irda/irttp.h>
#include <net/irda/discovery.h>

Go to the source code of this file.

Data Structures

struct  irnet_socket
 
struct  irnet_log
 
struct  irnet_ctrl_channel
 

Macros

#define DISCOVERY_NOMASK   /* To enable W2k compatibility... */
 
#define ADVERTISE_HINT   /* Advertise IrLAN hint bit */
 
#define ALLOW_SIMULT_CONNECT   /* This seem to work, cross fingers... */
 
#define DISCOVERY_EVENTS   /* Query the discovery log to post events */
 
#define INITIAL_DISCOVERY   /* Dump current discovery log as events */
 
#define BLOCK_WHEN_CONNECT   /* Block packets when connecting */
 
#define CONNECT_IN_SEND   /* Retry IrDA connection procedure */
 
#define DEBUG_CTRL_TRACE   0 /* Control channel */
 
#define DEBUG_CTRL_INFO   0 /* various info */
 
#define DEBUG_CTRL_ERROR   1 /* problems */
 
#define DEBUG_FS_TRACE   0 /* filesystem callbacks */
 
#define DEBUG_FS_INFO   0 /* various info */
 
#define DEBUG_FS_ERROR   1 /* problems */
 
#define DEBUG_PPP_TRACE   0 /* PPP related functions */
 
#define DEBUG_PPP_INFO   0 /* various info */
 
#define DEBUG_PPP_ERROR   1 /* problems */
 
#define DEBUG_MODULE_TRACE   0 /* module insertion/removal */
 
#define DEBUG_MODULE_ERROR   1 /* problems */
 
#define DEBUG_IRDA_SR_TRACE   0 /* IRDA subroutines */
 
#define DEBUG_IRDA_SR_INFO   0 /* various info */
 
#define DEBUG_IRDA_SR_ERROR   1 /* problems */
 
#define DEBUG_IRDA_SOCK_TRACE   0 /* IRDA main socket functions */
 
#define DEBUG_IRDA_SOCK_INFO   0 /* various info */
 
#define DEBUG_IRDA_SOCK_ERROR   1 /* problems */
 
#define DEBUG_IRDA_SERV_TRACE   0 /* The IrNET server */
 
#define DEBUG_IRDA_SERV_INFO   0 /* various info */
 
#define DEBUG_IRDA_SERV_ERROR   1 /* problems */
 
#define DEBUG_IRDA_TCB_TRACE   0 /* IRDA IrTTP callbacks */
 
#define DEBUG_IRDA_CB_INFO   0 /* various info */
 
#define DEBUG_IRDA_CB_ERROR   1 /* problems */
 
#define DEBUG_IRDA_OCB_TRACE   0 /* IRDA other callbacks */
 
#define DEBUG_IRDA_OCB_INFO   0 /* various info */
 
#define DEBUG_IRDA_OCB_ERROR   1 /* problems */
 
#define DEBUG_ASSERT   0 /* Verify all assertions */
 
#define DERROR(dbg, format, args...)
 
#define DEBUG(dbg, format, args...)
 
#define DENTER(dbg, format, args...)
 
#define DPASS(dbg, format, args...)
 
#define DEXIT(dbg, format, args...)
 
#define DRETURN(ret, dbg, args...)
 
#define DABORT(cond, ret, dbg, args...)
 
#define DASSERT(cond, ret, dbg, args...)
 
#define IRNET_MAGIC   0xB00754
 
#define IRNET_MAX_EVENTS   8 /* Should be more than enough... */
 

Typedefs

typedef struct irnet_socket irnet_socket
 
typedef enum irnet_event irnet_event
 
typedef struct irnet_log irnet_log
 
typedef struct irnet_ctrl_channel irnet_ctrl_channel
 

Enumerations

enum  irnet_event {
  IRNET_DISCOVER, IRNET_EXPIRE, IRNET_CONNECT_TO, IRNET_CONNECT_FROM,
  IRNET_REQUEST_FROM, IRNET_NOANSWER_FROM, IRNET_BLOCKED_LINK, IRNET_DISCONNECT_FROM,
  IRNET_DISCONNECT_TO
}
 

Functions

int irda_irnet_create (irnet_socket *)
 
int irda_irnet_connect (irnet_socket *)
 
void irda_irnet_destroy (irnet_socket *)
 
int irda_irnet_init (void)
 
void irda_irnet_cleanup (void)
 

Variables

struct irnet_ctrl_channel irnet_events
 

Macro Definition Documentation

#define ADVERTISE_HINT   /* Advertise IrLAN hint bit */

Definition at line 276 of file irnet.h.

#define ALLOW_SIMULT_CONNECT   /* This seem to work, cross fingers... */

Definition at line 277 of file irnet.h.

#define BLOCK_WHEN_CONNECT   /* Block packets when connecting */

Definition at line 287 of file irnet.h.

#define CONNECT_IN_SEND   /* Retry IrDA connection procedure */

Definition at line 288 of file irnet.h.

#define DABORT (   cond,
  ret,
  dbg,
  args... 
)
Value:
{if(cond) {\
DERROR(dbg, args);\
return ret; }}

Definition at line 369 of file irnet.h.

#define DASSERT (   cond,
  ret,
  dbg,
  args... 
)
Value:
{if((DEBUG_ASSERT) && !(cond)) {\
DERROR(dbg, "Invalid assertion: " args);\
return ret; }}

Definition at line 375 of file irnet.h.

#define DEBUG (   dbg,
  format,
  args... 
)
Value:
{if(DEBUG_##dbg) \
printk(KERN_DEBUG "irnet: %s(): " format, __func__ , ##args);}

Definition at line 344 of file irnet.h.

#define DEBUG_ASSERT   0 /* Verify all assertions */

Definition at line 329 of file irnet.h.

#define DEBUG_CTRL_ERROR   1 /* problems */

Definition at line 302 of file irnet.h.

#define DEBUG_CTRL_INFO   0 /* various info */

Definition at line 301 of file irnet.h.

#define DEBUG_CTRL_TRACE   0 /* Control channel */

Definition at line 300 of file irnet.h.

#define DEBUG_FS_ERROR   1 /* problems */

Definition at line 305 of file irnet.h.

#define DEBUG_FS_INFO   0 /* various info */

Definition at line 304 of file irnet.h.

#define DEBUG_FS_TRACE   0 /* filesystem callbacks */

Definition at line 303 of file irnet.h.

#define DEBUG_IRDA_CB_ERROR   1 /* problems */

Definition at line 324 of file irnet.h.

#define DEBUG_IRDA_CB_INFO   0 /* various info */

Definition at line 323 of file irnet.h.

#define DEBUG_IRDA_OCB_ERROR   1 /* problems */

Definition at line 327 of file irnet.h.

#define DEBUG_IRDA_OCB_INFO   0 /* various info */

Definition at line 326 of file irnet.h.

#define DEBUG_IRDA_OCB_TRACE   0 /* IRDA other callbacks */

Definition at line 325 of file irnet.h.

#define DEBUG_IRDA_SERV_ERROR   1 /* problems */

Definition at line 321 of file irnet.h.

#define DEBUG_IRDA_SERV_INFO   0 /* various info */

Definition at line 320 of file irnet.h.

#define DEBUG_IRDA_SERV_TRACE   0 /* The IrNET server */

Definition at line 319 of file irnet.h.

#define DEBUG_IRDA_SOCK_ERROR   1 /* problems */

Definition at line 318 of file irnet.h.

#define DEBUG_IRDA_SOCK_INFO   0 /* various info */

Definition at line 317 of file irnet.h.

#define DEBUG_IRDA_SOCK_TRACE   0 /* IRDA main socket functions */

Definition at line 316 of file irnet.h.

#define DEBUG_IRDA_SR_ERROR   1 /* problems */

Definition at line 315 of file irnet.h.

#define DEBUG_IRDA_SR_INFO   0 /* various info */

Definition at line 314 of file irnet.h.

#define DEBUG_IRDA_SR_TRACE   0 /* IRDA subroutines */

Definition at line 313 of file irnet.h.

#define DEBUG_IRDA_TCB_TRACE   0 /* IRDA IrTTP callbacks */

Definition at line 322 of file irnet.h.

#define DEBUG_MODULE_ERROR   1 /* problems */

Definition at line 310 of file irnet.h.

#define DEBUG_MODULE_TRACE   0 /* module insertion/removal */

Definition at line 309 of file irnet.h.

#define DEBUG_PPP_ERROR   1 /* problems */

Definition at line 308 of file irnet.h.

#define DEBUG_PPP_INFO   0 /* various info */

Definition at line 307 of file irnet.h.

#define DEBUG_PPP_TRACE   0 /* PPP related functions */

Definition at line 306 of file irnet.h.

#define DENTER (   dbg,
  format,
  args... 
)
Value:
{if(DEBUG_##dbg) \
printk(KERN_DEBUG "irnet: -> %s" format, __func__ , ##args);}

Definition at line 349 of file irnet.h.

#define DERROR (   dbg,
  format,
  args... 
)
Value:
{if(DEBUG_##dbg) \
printk(KERN_INFO "irnet: %s(): " format, __func__ , ##args);}

Definition at line 339 of file irnet.h.

#define DEXIT (   dbg,
  format,
  args... 
)
Value:
{if(DEBUG_##dbg) \
printk(KERN_DEBUG "irnet: <-%s()" format, __func__ , ##args);}

Definition at line 359 of file irnet.h.

#define DISCOVERY_EVENTS   /* Query the discovery log to post events */

Definition at line 278 of file irnet.h.

#define DISCOVERY_NOMASK   /* To enable W2k compatibility... */

Definition at line 275 of file irnet.h.

#define DPASS (   dbg,
  format,
  args... 
)
Value:
{if(DEBUG_##dbg) \
printk(KERN_DEBUG "irnet: <>%s" format, __func__ , ##args);}

Definition at line 354 of file irnet.h.

#define DRETURN (   ret,
  dbg,
  args... 
)
Value:
{DEXIT(dbg, ": " args);\
return ret; }

Definition at line 364 of file irnet.h.

#define INITIAL_DISCOVERY   /* Dump current discovery log as events */

Definition at line 279 of file irnet.h.

#define IRNET_MAGIC   0xB00754

Definition at line 383 of file irnet.h.

#define IRNET_MAX_EVENTS   8 /* Should be more than enough... */

Definition at line 386 of file irnet.h.

Typedef Documentation

typedef enum irnet_event irnet_event

Enumeration Type Documentation

Enumerator:
IRNET_DISCOVER 
IRNET_EXPIRE 
IRNET_CONNECT_TO 
IRNET_CONNECT_FROM 
IRNET_REQUEST_FROM 
IRNET_NOANSWER_FROM 
IRNET_BLOCKED_LINK 
IRNET_DISCONNECT_FROM 
IRNET_DISCONNECT_TO 

Definition at line 468 of file irnet.h.

Function Documentation

void irda_irnet_cleanup ( void  )

Definition at line 1866 of file irnet_irda.c.

int irda_irnet_connect ( irnet_socket )

Definition at line 547 of file irnet_irda.c.

int irda_irnet_create ( irnet_socket )

Definition at line 503 of file irnet_irda.c.

void irda_irnet_destroy ( irnet_socket )

Definition at line 616 of file irnet_irda.c.

int irda_irnet_init ( void  )

Definition at line 1823 of file irnet_irda.c.

Variable Documentation

struct irnet_ctrl_channel irnet_events

Definition at line 171 of file irnet_irda.h.