Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
sierra_net.c File Reference
#include <linux/module.h>
#include <linux/etherdevice.h>
#include <linux/ethtool.h>
#include <linux/mii.h>
#include <linux/sched.h>
#include <linux/timer.h>
#include <linux/usb.h>
#include <linux/usb/cdc.h>
#include <net/ip.h>
#include <net/udp.h>
#include <asm/unaligned.h>
#include <linux/usb/usbnet.h>

Go to the source code of this file.

Data Structures

struct  sierra_net_data
 
struct  param
 
struct  lsi_umts
 
struct  hip_hdr
 

Macros

#define DRIVER_VERSION   "v.2.0"
 
#define DRIVER_AUTHOR   "Paxton Smith, Matthew Safar, Rory Filer"
 
#define DRIVER_DESC   "USB-to-WWAN Driver for Sierra Wireless modems"
 
#define SWI_USB_REQUEST_GET_FW_ATTR   0x06
 
#define SWI_GET_FW_ATTR_MASK   0x08
 
#define SIERRA_NET_SYNCDELAY   (2*HZ)
 
#define SIERRA_NET_MAX_SUPPORTED_MTU   1500
 
#define SIERRA_NET_USBCTL_BUF_LEN   1024
 
#define SIERRA_NET_RX_URB_SIZE   (8 * 1024)
 
#define SIERRA_NET_EVENT_RESP_AVAIL   0x01
 
#define SIERRA_NET_TIMER_EXPIRY   0x02
 
#define SIERRA_NET_HIP_EXTENDEDID   0x7F
 
#define SIERRA_NET_HIP_HSYNC_ID   0x60 /* Modem -> host */
 
#define SIERRA_NET_HIP_RESTART_ID   0x62 /* Modem -> host */
 
#define SIERRA_NET_HIP_MSYNC_ID   0x20 /* Host -> modem */
 
#define SIERRA_NET_HIP_SHUTD_ID   0x26 /* Host -> modem */
 
#define SIERRA_NET_HIP_EXT_IP_IN_ID   0x0202
 
#define SIERRA_NET_HIP_EXT_IP_OUT_ID   0x0002
 
#define SIERRA_NET_HIP_LSI_UMTSID   0x78
 
#define SIERRA_NET_HIP_RCGI   0x64
 
#define SIERRA_NET_PROTOCOL_UMTS   0x01
 
#define SIERRA_NET_COVERAGE_NONE   0x00
 
#define SIERRA_NET_COVERAGE_NOPACKET   0x01
 
#define SIERRA_NET_SESSION_IDLE   0x00
 
#define SIERRA_NET_AS_LINK_TYPE_IPv4   0x00
 
#define SIERRA_NET_LSI_COMMON_LEN   4
 
#define SIERRA_NET_LSI_UMTS_LEN   (sizeof(struct lsi_umts))
 
#define SIERRA_NET_LSI_UMTS_STATUS_LEN   (SIERRA_NET_LSI_UMTS_LEN - SIERRA_NET_LSI_COMMON_LEN)
 
#define SIERRA_NET_HIP_HDR_LEN   4
 
#define SIERRA_NET_HIP_EXT_HDR_LEN   6
 
#define DIRECT_IP_DEVICE(vend, prod)
 

Functions

 MODULE_DEVICE_TABLE (usb, products)
 
 module_usb_driver (sierra_net_driver)
 
 MODULE_AUTHOR (DRIVER_AUTHOR)
 
 MODULE_DESCRIPTION (DRIVER_DESC)
 
 MODULE_VERSION (DRIVER_VERSION)
 
 MODULE_LICENSE ("GPL")
 

Variables

struct lsi_umts __packed
 

Macro Definition Documentation

#define DIRECT_IP_DEVICE (   vend,
  prod 
)
Value:
{USB_DEVICE_INTERFACE_NUMBER(vend, prod, 7), \
.driver_info = (unsigned long)&sierra_net_info_direct_ip}, \
{USB_DEVICE_INTERFACE_NUMBER(vend, prod, 10), \
.driver_info = (unsigned long)&sierra_net_info_direct_ip}, \
{USB_DEVICE_INTERFACE_NUMBER(vend, prod, 11), \
.driver_info = (unsigned long)&sierra_net_info_direct_ip}

Definition at line 927 of file sierra_net.c.

#define DRIVER_AUTHOR   "Paxton Smith, Matthew Safar, Rory Filer"

Definition at line 29 of file sierra_net.c.

#define DRIVER_DESC   "USB-to-WWAN Driver for Sierra Wireless modems"

Definition at line 30 of file sierra_net.c.

#define DRIVER_VERSION   "v.2.0"

Definition at line 28 of file sierra_net.c.

#define SIERRA_NET_AS_LINK_TYPE_IPv4   0x00

Definition at line 133 of file sierra_net.c.

#define SIERRA_NET_COVERAGE_NONE   0x00

Definition at line 127 of file sierra_net.c.

#define SIERRA_NET_COVERAGE_NOPACKET   0x01

Definition at line 128 of file sierra_net.c.

#define SIERRA_NET_EVENT_RESP_AVAIL   0x01

Definition at line 91 of file sierra_net.c.

#define SIERRA_NET_HIP_EXT_HDR_LEN   6

Definition at line 242 of file sierra_net.c.

#define SIERRA_NET_HIP_EXT_IP_IN_ID   0x0202

Definition at line 115 of file sierra_net.c.

#define SIERRA_NET_HIP_EXT_IP_OUT_ID   0x0002

Definition at line 116 of file sierra_net.c.

#define SIERRA_NET_HIP_EXTENDEDID   0x7F

Definition at line 109 of file sierra_net.c.

#define SIERRA_NET_HIP_HDR_LEN   4

Definition at line 240 of file sierra_net.c.

#define SIERRA_NET_HIP_HSYNC_ID   0x60 /* Modem -> host */

Definition at line 110 of file sierra_net.c.

#define SIERRA_NET_HIP_LSI_UMTSID   0x78

Definition at line 119 of file sierra_net.c.

#define SIERRA_NET_HIP_MSYNC_ID   0x20 /* Host -> modem */

Definition at line 112 of file sierra_net.c.

#define SIERRA_NET_HIP_RCGI   0x64

Definition at line 122 of file sierra_net.c.

#define SIERRA_NET_HIP_RESTART_ID   0x62 /* Modem -> host */

Definition at line 111 of file sierra_net.c.

#define SIERRA_NET_HIP_SHUTD_ID   0x26 /* Host -> modem */

Definition at line 113 of file sierra_net.c.

#define SIERRA_NET_LSI_COMMON_LEN   4

Definition at line 162 of file sierra_net.c.

#define SIERRA_NET_LSI_UMTS_LEN   (sizeof(struct lsi_umts))

Definition at line 163 of file sierra_net.c.

#define SIERRA_NET_LSI_UMTS_STATUS_LEN   (SIERRA_NET_LSI_UMTS_LEN - SIERRA_NET_LSI_COMMON_LEN)

Definition at line 164 of file sierra_net.c.

#define SIERRA_NET_MAX_SUPPORTED_MTU   1500

Definition at line 63 of file sierra_net.c.

#define SIERRA_NET_PROTOCOL_UMTS   0x01

Definition at line 125 of file sierra_net.c.

#define SIERRA_NET_RX_URB_SIZE   (8 * 1024)

Definition at line 72 of file sierra_net.c.

#define SIERRA_NET_SESSION_IDLE   0x00

Definition at line 131 of file sierra_net.c.

#define SIERRA_NET_SYNCDELAY   (2*HZ)

Definition at line 60 of file sierra_net.c.

#define SIERRA_NET_TIMER_EXPIRY   0x02

Definition at line 92 of file sierra_net.c.

#define SIERRA_NET_USBCTL_BUF_LEN   1024

Definition at line 69 of file sierra_net.c.

#define SWI_GET_FW_ATTR_MASK   0x08

Definition at line 50 of file sierra_net.c.

#define SWI_USB_REQUEST_GET_FW_ATTR   0x06

Definition at line 49 of file sierra_net.c.

Function Documentation

MODULE_AUTHOR ( DRIVER_AUTHOR  )
MODULE_DESCRIPTION ( DRIVER_DESC  )
MODULE_DEVICE_TABLE ( usb  ,
products   
)
MODULE_LICENSE ( "GPL"  )
module_usb_driver ( sierra_net_driver  )
MODULE_VERSION ( DRIVER_VERSION  )

Variable Documentation