Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
xpnet.c File Reference
#include <linux/slab.h>
#include <linux/module.h>
#include <linux/netdevice.h>
#include <linux/etherdevice.h>
#include "xp.h"

Go to the source code of this file.

Data Structures

struct  xpnet_message
 
struct  xpnet_pending_msg
 

Macros

#define XPNET_MSG_SIZE   XPC_MSG_PAYLOAD_MAX_SIZE
 
#define XPNET_MSG_DATA_MAX   (XPNET_MSG_SIZE - offsetof(struct xpnet_message, data))
 
#define XPNET_MSG_NENTRIES   (PAGE_SIZE / XPC_MSG_MAX_SIZE)
 
#define XPNET_MAX_KTHREADS   (XPNET_MSG_NENTRIES + 1)
 
#define XPNET_MAX_IDLE_KTHREADS   (XPNET_MSG_NENTRIES + 1)
 
#define _XPNET_VERSION(_major, _minor)   (((_major) << 4) | (_minor))
 
#define XPNET_VERSION_MAJOR(_v)   ((_v) >> 4)
 
#define XPNET_VERSION_MINOR(_v)   ((_v) & 0xf)
 
#define XPNET_VERSION   _XPNET_VERSION(1, 0) /* version 1.0 */
 
#define XPNET_VERSION_EMBED   _XPNET_VERSION(1, 1) /* version 1.1 */
 
#define XPNET_MAGIC   0x88786984 /* "XNET" */
 
#define XPNET_VALID_MSG(_m)
 
#define XPNET_DEVICE_NAME   "xp0"
 
#define XPNET_MAX_MTU   (0x800000UL - L1_CACHE_BYTES)
 
#define XPNET_DEF_MTU   (0x8000UL)
 
#define XPNET_PARTID_OCTET   2
 

Functions

 module_init (xpnet_init)
 
 module_exit (xpnet_exit)
 
 MODULE_AUTHOR ("Silicon Graphics, Inc.")
 
 MODULE_DESCRIPTION ("Cross Partition Network adapter (XPNET)")
 
 MODULE_LICENSE ("GPL")
 

Variables

struct net_devicexpnet_device
 
struct device_driver xpnet_dbg_name
 
struct device xpnet_dbg_subname
 
struct devicexpnet = &xpnet_dbg_subname
 

Macro Definition Documentation

#define _XPNET_VERSION (   _major,
  _minor 
)    (((_major) << 4) | (_minor))

Definition at line 73 of file xpnet.c.

#define XPNET_DEF_MTU   (0x8000UL)

Definition at line 122 of file xpnet.c.

#define XPNET_DEVICE_NAME   "xp0"

Definition at line 85 of file xpnet.c.

#define XPNET_MAGIC   0x88786984 /* "XNET" */

Definition at line 79 of file xpnet.c.

#define XPNET_MAX_IDLE_KTHREADS   (XPNET_MSG_NENTRIES + 1)

Definition at line 67 of file xpnet.c.

#define XPNET_MAX_KTHREADS   (XPNET_MSG_NENTRIES + 1)

Definition at line 66 of file xpnet.c.

#define XPNET_MAX_MTU   (0x800000UL - L1_CACHE_BYTES)

Definition at line 120 of file xpnet.c.

#define XPNET_MSG_DATA_MAX   (XPNET_MSG_SIZE - offsetof(struct xpnet_message, data))

Definition at line 62 of file xpnet.c.

#define XPNET_MSG_NENTRIES   (PAGE_SIZE / XPC_MSG_MAX_SIZE)

Definition at line 64 of file xpnet.c.

#define XPNET_MSG_SIZE   XPC_MSG_PAYLOAD_MAX_SIZE

Definition at line 61 of file xpnet.c.

#define XPNET_PARTID_OCTET   2

Definition at line 128 of file xpnet.c.

#define XPNET_VALID_MSG (   _m)
Value:

Definition at line 81 of file xpnet.c.

#define XPNET_VERSION   _XPNET_VERSION(1, 0) /* version 1.0 */

Definition at line 77 of file xpnet.c.

#define XPNET_VERSION_EMBED   _XPNET_VERSION(1, 1) /* version 1.1 */

Definition at line 78 of file xpnet.c.

#define XPNET_VERSION_MAJOR (   _v)    ((_v) >> 4)

Definition at line 74 of file xpnet.c.

#define XPNET_VERSION_MINOR (   _v)    ((_v) & 0xf)

Definition at line 75 of file xpnet.c.

Function Documentation

MODULE_AUTHOR ( "Silicon  Graphics,
Inc."   
)
MODULE_DESCRIPTION ( "Cross Partition Network adapter (XPNET)"  )
module_exit ( xpnet_exit  )
module_init ( xpnet_init  )
MODULE_LICENSE ( "GPL"  )

Variable Documentation

Definition at line 141 of file xpnet.c.

struct device_driver xpnet_dbg_name
Initial value:
= {
.name = "xpnet"
}

Definition at line 132 of file xpnet.c.

struct device xpnet_dbg_subname
Initial value:
= {
.init_name = "",
.driver = &xpnet_dbg_name
}

Definition at line 136 of file xpnet.c.

struct net_device* xpnet_device

Definition at line 99 of file xpnet.c.