Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
sddr55.c File Reference
#include <linux/jiffies.h>
#include <linux/errno.h>
#include <linux/module.h>
#include <linux/slab.h>
#include <scsi/scsi.h>
#include <scsi/scsi_cmnd.h>
#include "usb.h"
#include "transport.h"
#include "protocol.h"
#include "debug.h"
#include "unusual_sddr55.h"

Go to the source code of this file.

Data Structures

struct  sddr55_card_info
 

Macros

#define UNUSUAL_DEV(id_vendor, id_product, bcdDeviceMin, bcdDeviceMax, vendorName, productName, useProtocol, useTransport, initFunction, flags)
 
#define UNUSUAL_DEV(idVendor, idProduct, bcdDeviceMin, bcdDeviceMax, vendor_name, product_name, use_protocol, use_transport, init_function, Flags)
 
#define short_pack(lsb, msb)   ( ((u16)(lsb)) | ( ((u16)(msb))<<8 ) )
 
#define LSB_of(s)   ((s)&0xFF)
 
#define MSB_of(s)   ((s)>>8)
 
#define PAGESIZE   512
 
#define set_sense_info(sk, asc, ascq)
 
#define NOT_ALLOCATED   0xffffffff
 
#define BAD_BLOCK   0xffff
 
#define CIS_BLOCK   0x400
 
#define UNUSED_BLOCK   0x3ff
 

Functions

 MODULE_DESCRIPTION ("Driver for SanDisk SDDR-55 SmartMedia reader")
 
 MODULE_AUTHOR ("Simon Munton")
 
 MODULE_LICENSE ("GPL")
 
 MODULE_DEVICE_TABLE (usb, sddr55_usb_ids)
 
 module_usb_driver (sddr55_driver)
 

Macro Definition Documentation

#define BAD_BLOCK   0xffff

Definition at line 113 of file sddr55.c.

#define CIS_BLOCK   0x400

Definition at line 114 of file sddr55.c.

#define LSB_of (   s)    ((s)&0xFF)

Definition at line 82 of file sddr55.c.

#define MSB_of (   s)    ((s)>>8)

Definition at line 83 of file sddr55.c.

#define NOT_ALLOCATED   0xffffffff

Definition at line 112 of file sddr55.c.

#define PAGESIZE   512

Definition at line 84 of file sddr55.c.

#define set_sense_info (   sk,
  asc,
  ascq 
)
Value:
do { \
info->sense_data[2] = sk; \
info->sense_data[12] = asc; \
info->sense_data[13] = ascq; \
} while (0)

Definition at line 86 of file sddr55.c.

#define short_pack (   lsb,
  msb 
)    ( ((u16)(lsb)) | ( ((u16)(msb))<<8 ) )

Definition at line 81 of file sddr55.c.

#define UNUSED_BLOCK   0x3ff

Definition at line 115 of file sddr55.c.

#define UNUSUAL_DEV (   id_vendor,
  id_product,
  bcdDeviceMin,
  bcdDeviceMax,
  vendorName,
  productName,
  useProtocol,
  useTransport,
  initFunction,
  flags 
)
Value:
{ USB_DEVICE_VER(id_vendor, id_product, bcdDeviceMin, bcdDeviceMax), \
.driver_info = (flags) }

Definition at line 62 of file sddr55.c.

#define UNUSUAL_DEV (   idVendor,
  idProduct,
  bcdDeviceMin,
  bcdDeviceMax,
  vendor_name,
  product_name,
  use_protocol,
  use_transport,
  init_function,
  Flags 
)
Value:
{ \
.vendorName = vendor_name, \
.productName = product_name, \
.useProtocol = use_protocol, \
.useTransport = use_transport, \
.initFunction = init_function, \
}

Definition at line 62 of file sddr55.c.

Function Documentation

MODULE_AUTHOR ( "Simon Munton"  )
MODULE_DESCRIPTION ( "Driver for SanDisk SDDR-55 SmartMedia reader"  )
MODULE_DEVICE_TABLE ( usb  ,
sddr55_usb_ids   
)
MODULE_LICENSE ( "GPL"  )
module_usb_driver ( sddr55_driver  )