Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Typedefs | Enumerations | Functions
vrc4171_card.c File Reference
#include <linux/init.h>
#include <linux/ioport.h>
#include <linux/interrupt.h>
#include <linux/module.h>
#include <linux/spinlock.h>
#include <linux/types.h>
#include <linux/platform_device.h>
#include <asm/io.h>
#include <pcmcia/ss.h>
#include "i82365.h"

Go to the source code of this file.

Data Structures

struct  vrc4171_socket
 

Macros

#define CARD_MAX_SLOTS   2
 
#define CARD_SLOTA   0
 
#define CARD_SLOTB   1
 
#define CARD_SLOTB_OFFSET   0x40
 
#define CARD_MEM_START   0x10000000
 
#define CARD_MEM_END   0x13ffffff
 
#define CARD_MAX_MEM_OFFSET   0x3ffffff
 
#define CARD_MAX_MEM_SPEED   1000
 
#define CARD_CONTROLLER_INDEX   0x03e0
 
#define CARD_CONTROLLER_DATA   0x03e1
 
#define VPP_GET_VCC   0x01
 
#define POWER_ENABLE   0x10
 
#define CARD_VOLTAGE_SENSE   0x1f
 
#define VCC_3VORXV_CAPABLE   0x00
 
#define VCC_XV_ONLY   0x01
 
#define VCC_3V_CAPABLE   0x02
 
#define VCC_5V_ONLY   0x03
 
#define CARD_VOLTAGE_SELECT   0x2f
 
#define VCC_3V   0x01
 
#define VCC_5V   0x00
 
#define VCC_XV   0x02
 
#define VCC_STATUS_3V   0x02
 
#define VCC_STATUS_5V   0x01
 
#define VCC_STATUS_XV   0x03
 
#define GLOBAL_CONTROL   0x1e
 
#define EXWRBK   0x04
 
#define IRQPM_EN   0x08
 
#define CLRPMIRQ   0x10
 
#define INTERRUPT_STATUS   0x05fa
 
#define IRQ_A   0x02
 
#define IRQ_B   0x04
 
#define CONFIGURATION1   0x05fe
 
#define SLOTB_CONFIG   0xc000
 
#define SLOTB_NONE   0x0000
 
#define SLOTB_PCCARD   0x4000
 
#define SLOTB_CF   0x8000
 
#define SLOTB_FLASHROM   0xc000
 
#define CARD_CONTROLLER_START   CARD_CONTROLLER_INDEX
 
#define CARD_CONTROLLER_END   CARD_CONTROLLER_DATA
 
#define IO_MAX_MAPS   2
 
#define MEM_MAX_MAPS   5
 

Typedefs

typedef struct vrc4171_socket vrc4171_socket_t
 

Enumerations

enum  vrc4171_slot_t {
  SLOT_PROBE = 0, SLOT_NOPROBE_IO, SLOT_NOPROBE_MEM, SLOT_NOPROBE_ALL,
  SLOT_INITIALIZED
}
 
enum  vrc4171_slotb_t { SLOTB_IS_NONE, SLOTB_IS_PCCARD, SLOTB_IS_CF, SLOTB_IS_FLASHROM }
 

Functions

 MODULE_DESCRIPTION ("NEC VRC4171 Card Controllers driver for Socket Services")
 
 MODULE_AUTHOR ("Yoichi Yuasa <[email protected]>")
 
 MODULE_LICENSE ("GPL")
 
 __setup ("vrc4171_card=", vrc4171_card_setup)
 
 module_init (vrc4171_card_init)
 
 module_exit (vrc4171_card_exit)
 

Macro Definition Documentation

#define CARD_CONTROLLER_DATA   0x03e1

Definition at line 49 of file vrc4171_card.c.

#define CARD_CONTROLLER_END   CARD_CONTROLLER_DATA

Definition at line 82 of file vrc4171_card.c.

#define CARD_CONTROLLER_INDEX   0x03e0

Definition at line 48 of file vrc4171_card.c.

#define CARD_CONTROLLER_START   CARD_CONTROLLER_INDEX

Definition at line 81 of file vrc4171_card.c.

#define CARD_MAX_MEM_OFFSET   0x3ffffff

Definition at line 45 of file vrc4171_card.c.

#define CARD_MAX_MEM_SPEED   1000

Definition at line 46 of file vrc4171_card.c.

#define CARD_MAX_SLOTS   2

Definition at line 38 of file vrc4171_card.c.

#define CARD_MEM_END   0x13ffffff

Definition at line 44 of file vrc4171_card.c.

#define CARD_MEM_START   0x10000000

Definition at line 43 of file vrc4171_card.c.

#define CARD_SLOTA   0

Definition at line 39 of file vrc4171_card.c.

#define CARD_SLOTB   1

Definition at line 40 of file vrc4171_card.c.

#define CARD_SLOTB_OFFSET   0x40

Definition at line 41 of file vrc4171_card.c.

#define CARD_VOLTAGE_SELECT   0x2f

Definition at line 58 of file vrc4171_card.c.

#define CARD_VOLTAGE_SENSE   0x1f

Definition at line 53 of file vrc4171_card.c.

#define CLRPMIRQ   0x10

Definition at line 68 of file vrc4171_card.c.

#define CONFIGURATION1   0x05fe

Definition at line 74 of file vrc4171_card.c.

#define EXWRBK   0x04

Definition at line 66 of file vrc4171_card.c.

#define GLOBAL_CONTROL   0x1e

Definition at line 65 of file vrc4171_card.c.

#define INTERRUPT_STATUS   0x05fa

Definition at line 70 of file vrc4171_card.c.

#define IO_MAX_MAPS   2

Definition at line 84 of file vrc4171_card.c.

#define IRQ_A   0x02

Definition at line 71 of file vrc4171_card.c.

#define IRQ_B   0x04

Definition at line 72 of file vrc4171_card.c.

#define IRQPM_EN   0x08

Definition at line 67 of file vrc4171_card.c.

#define MEM_MAX_MAPS   5

Definition at line 85 of file vrc4171_card.c.

#define POWER_ENABLE   0x10

Definition at line 52 of file vrc4171_card.c.

#define SLOTB_CF   0x8000

Definition at line 78 of file vrc4171_card.c.

#define SLOTB_CONFIG   0xc000

Definition at line 75 of file vrc4171_card.c.

#define SLOTB_FLASHROM   0xc000

Definition at line 79 of file vrc4171_card.c.

#define SLOTB_NONE   0x0000

Definition at line 76 of file vrc4171_card.c.

#define SLOTB_PCCARD   0x4000

Definition at line 77 of file vrc4171_card.c.

#define VCC_3V   0x01

Definition at line 59 of file vrc4171_card.c.

#define VCC_3V_CAPABLE   0x02

Definition at line 56 of file vrc4171_card.c.

#define VCC_3VORXV_CAPABLE   0x00

Definition at line 54 of file vrc4171_card.c.

#define VCC_5V   0x00

Definition at line 60 of file vrc4171_card.c.

#define VCC_5V_ONLY   0x03

Definition at line 57 of file vrc4171_card.c.

#define VCC_STATUS_3V   0x02

Definition at line 62 of file vrc4171_card.c.

#define VCC_STATUS_5V   0x01

Definition at line 63 of file vrc4171_card.c.

#define VCC_STATUS_XV   0x03

Definition at line 64 of file vrc4171_card.c.

#define VCC_XV   0x02

Definition at line 61 of file vrc4171_card.c.

#define VCC_XV_ONLY   0x01

Definition at line 55 of file vrc4171_card.c.

#define VPP_GET_VCC   0x01

Definition at line 51 of file vrc4171_card.c.

Typedef Documentation

Enumeration Type Documentation

Enumerator:
SLOT_PROBE 
SLOT_NOPROBE_IO 
SLOT_NOPROBE_MEM 
SLOT_NOPROBE_ALL 
SLOT_INITIALIZED 

Definition at line 87 of file vrc4171_card.c.

Enumerator:
SLOTB_IS_NONE 
SLOTB_IS_PCCARD 
SLOTB_IS_CF 
SLOTB_IS_FLASHROM 

Definition at line 95 of file vrc4171_card.c.

Function Documentation

__setup ( )
MODULE_AUTHOR ( "Yoichi Yuasa <[email protected]>"  )
MODULE_DESCRIPTION ( "NEC VRC4171 Card Controllers driver for Socket Services"  )
module_exit ( vrc4171_card_exit  )
module_init ( vrc4171_card_init  )
MODULE_LICENSE ( "GPL"  )