Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros
idp.h File Reference

Go to the source code of this file.

Macros

#define IDP_FLASH_PHYS   (PXA_CS0_PHYS)
 
#define IDP_ALT_FLASH_PHYS   (PXA_CS1_PHYS)
 
#define IDP_MEDIAQ_PHYS   (PXA_CS3_PHYS)
 
#define IDP_IDE_PHYS   (PXA_CS5_PHYS + 0x03000000)
 
#define IDP_ETH_PHYS   (PXA_CS5_PHYS + 0x03400000)
 
#define IDP_COREVOLT_PHYS   (PXA_CS5_PHYS + 0x03800000)
 
#define IDP_CPLD_PHYS   (PXA_CS5_PHYS + 0x03C00000)
 
#define IDP_COREVOLT_VIRT   (0xf0000000)
 
#define IDP_COREVOLT_SIZE   (1*1024*1024)
 
#define IDP_CPLD_VIRT   (IDP_COREVOLT_VIRT + IDP_COREVOLT_SIZE)
 
#define IDP_CPLD_SIZE   (1*1024*1024)
 
#define CPLD_P2V(x)   ((x) - IDP_CPLD_PHYS + IDP_CPLD_VIRT)
 
#define CPLD_V2P(x)   ((x) - IDP_CPLD_VIRT + IDP_CPLD_PHYS)
 
#define __CPLD_REG(x)   (*((volatile unsigned long *)CPLD_P2V(x)))
 
#define _IDP_CPLD_REV   (IDP_CPLD_PHYS + 0x00)
 
#define _IDP_CPLD_PERIPH_PWR   (IDP_CPLD_PHYS + 0x04)
 
#define _IDP_CPLD_LED_CONTROL   (IDP_CPLD_PHYS + 0x08)
 
#define _IDP_CPLD_KB_COL_HIGH   (IDP_CPLD_PHYS + 0x0C)
 
#define _IDP_CPLD_KB_COL_LOW   (IDP_CPLD_PHYS + 0x10)
 
#define _IDP_CPLD_PCCARD_EN   (IDP_CPLD_PHYS + 0x14)
 
#define _IDP_CPLD_GPIOH_DIR   (IDP_CPLD_PHYS + 0x18)
 
#define _IDP_CPLD_GPIOH_VALUE   (IDP_CPLD_PHYS + 0x1C)
 
#define _IDP_CPLD_GPIOL_DIR   (IDP_CPLD_PHYS + 0x20)
 
#define _IDP_CPLD_GPIOL_VALUE   (IDP_CPLD_PHYS + 0x24)
 
#define _IDP_CPLD_PCCARD_PWR   (IDP_CPLD_PHYS + 0x28)
 
#define _IDP_CPLD_MISC_CTRL   (IDP_CPLD_PHYS + 0x2C)
 
#define _IDP_CPLD_LCD   (IDP_CPLD_PHYS + 0x30)
 
#define _IDP_CPLD_FLASH_WE   (IDP_CPLD_PHYS + 0x34)
 
#define _IDP_CPLD_KB_ROW   (IDP_CPLD_PHYS + 0x50)
 
#define _IDP_CPLD_PCCARD0_STATUS   (IDP_CPLD_PHYS + 0x54)
 
#define _IDP_CPLD_PCCARD1_STATUS   (IDP_CPLD_PHYS + 0x58)
 
#define _IDP_CPLD_MISC_STATUS   (IDP_CPLD_PHYS + 0x5C)
 
#define IDP_CPLD_REV   __CPLD_REG(_IDP_CPLD_REV)
 
#define IDP_CPLD_PERIPH_PWR   __CPLD_REG(_IDP_CPLD_PERIPH_PWR)
 
#define IDP_CPLD_LED_CONTROL   __CPLD_REG(_IDP_CPLD_LED_CONTROL)
 
#define IDP_CPLD_KB_COL_HIGH   __CPLD_REG(_IDP_CPLD_KB_COL_HIGH)
 
#define IDP_CPLD_KB_COL_LOW   __CPLD_REG(_IDP_CPLD_KB_COL_LOW)
 
#define IDP_CPLD_PCCARD_EN   __CPLD_REG(_IDP_CPLD_PCCARD_EN)
 
#define IDP_CPLD_GPIOH_DIR   __CPLD_REG(_IDP_CPLD_GPIOH_DIR)
 
#define IDP_CPLD_GPIOH_VALUE   __CPLD_REG(_IDP_CPLD_GPIOH_VALUE)
 
#define IDP_CPLD_GPIOL_DIR   __CPLD_REG(_IDP_CPLD_GPIOL_DIR)
 
#define IDP_CPLD_GPIOL_VALUE   __CPLD_REG(_IDP_CPLD_GPIOL_VALUE)
 
#define IDP_CPLD_PCCARD_PWR   __CPLD_REG(_IDP_CPLD_PCCARD_PWR)
 
#define IDP_CPLD_MISC_CTRL   __CPLD_REG(_IDP_CPLD_MISC_CTRL)
 
#define IDP_CPLD_LCD   __CPLD_REG(_IDP_CPLD_LCD)
 
#define IDP_CPLD_FLASH_WE   __CPLD_REG(_IDP_CPLD_FLASH_WE)
 
#define IDP_CPLD_KB_ROW   __CPLD_REG(_IDP_CPLD_KB_ROW)
 
#define IDP_CPLD_PCCARD0_STATUS   __CPLD_REG(_IDP_CPLD_PCCARD0_STATUS)
 
#define IDP_CPLD_PCCARD1_STATUS   __CPLD_REG(_IDP_CPLD_PCCARD1_STATUS)
 
#define IDP_CPLD_MISC_STATUS   __CPLD_REG(_IDP_CPLD_MISC_STATUS)
 
#define PCC0_PWR0   (1 << 0)
 
#define PCC0_PWR1   (1 << 1)
 
#define PCC0_PWR2   (1 << 2)
 
#define PCC0_PWR3   (1 << 3)
 
#define PCC1_PWR0   (1 << 4)
 
#define PCC1_PWR1   (1 << 5)
 
#define PCC1_PWR2   (1 << 6)
 
#define PCC1_PWR3   (1 << 7)
 
#define PCC0_RESET   (1 << 6)
 
#define PCC1_RESET   (1 << 7)
 
#define PCC0_ENABLE   (1 << 0)
 
#define PCC1_ENABLE   (1 << 1)
 
#define _PCC_WRPROT   (1 << 7)
 
#define _PCC_RESET   (1 << 6)
 
#define _PCC_IRQ   (1 << 5)
 
#define _PCC_INPACK   (1 << 4)
 
#define PCC_BVD2   (1 << 3)
 
#define PCC_BVD1   (1 << 2)
 
#define PCC_VS2   (1 << 1)
 
#define PCC_VS1   (1 << 0)
 
#define TOUCH_PANEL_IRQ   PXA_GPIO_TO_IRQ(5)
 
#define IDE_IRQ   PXA_GPIO_TO_IRQ(21)
 
#define TOUCH_PANEL_IRQ_EDGE   IRQ_TYPE_EDGE_FALLING
 
#define ETHERNET_IRQ   PXA_GPIO_TO_IRQ(4)
 
#define ETHERNET_IRQ_EDGE   IRQ_TYPE_EDGE_RISING
 
#define IDE_IRQ_EDGE   IRQ_TYPE_EDGE_RISING
 
#define PCMCIA_S0_CD_VALID   PXA_GPIO_TO_IRQ(7)
 
#define PCMCIA_S0_CD_VALID_EDGE   IRQ_TYPE_EDGE_BOTH
 
#define PCMCIA_S1_CD_VALID   PXA_GPIO_TO_IRQ(8)
 
#define PCMCIA_S1_CD_VALID_EDGE   IRQ_TYPE_EDGE_BOTH
 
#define PCMCIA_S0_RDYINT   PXA_GPIO_TO_IRQ(19)
 
#define PCMCIA_S1_RDYINT   PXA_GPIO_TO_IRQ(22)
 
#define IDP_HB_LED   (1<<5)
 
#define IDP_BUSY_LED   (1<<6)
 
#define IDP_LEDS_MASK   (IDP_HB_LED | IDP_BUSY_LED)
 
#define FLASH_WRITE_PROTECT_DISABLE()   ((IDP_CPLD_FLASH_WE) &= ~(0x1))
 
#define FLASH_WRITE_PROTECT_ENABLE()   ((IDP_CPLD_FLASH_WE) |= (0x1))
 
#define KEYBD_MATRIX_NUMBER_INPUTS   7
 
#define KEYBD_MATRIX_NUMBER_OUTPUTS   14
 
#define KEYBD_MATRIX_INVERT_OUTPUT_LOGIC   FALSE
 
#define KEYBD_MATRIX_INVERT_INPUT_LOGIC   FALSE
 
#define KEYBD_MATRIX_SETTLING_TIME_US   100
 
#define KEYBD_MATRIX_KEYSTATE_DEBOUNCE_CONSTANT   2
 
#define KEYBD_MATRIX_SET_OUTPUTS(outputs)
 
#define KEYBD_MATRIX_GET_INPUTS(inputs)
 

Macro Definition Documentation

#define __CPLD_REG (   x)    (*((volatile unsigned long *)CPLD_P2V(x)))

Definition at line 54 of file idp.h.

#define _IDP_CPLD_FLASH_WE   (IDP_CPLD_PHYS + 0x34)

Definition at line 74 of file idp.h.

#define _IDP_CPLD_GPIOH_DIR   (IDP_CPLD_PHYS + 0x18)

Definition at line 67 of file idp.h.

#define _IDP_CPLD_GPIOH_VALUE   (IDP_CPLD_PHYS + 0x1C)

Definition at line 68 of file idp.h.

#define _IDP_CPLD_GPIOL_DIR   (IDP_CPLD_PHYS + 0x20)

Definition at line 69 of file idp.h.

#define _IDP_CPLD_GPIOL_VALUE   (IDP_CPLD_PHYS + 0x24)

Definition at line 70 of file idp.h.

#define _IDP_CPLD_KB_COL_HIGH   (IDP_CPLD_PHYS + 0x0C)

Definition at line 64 of file idp.h.

#define _IDP_CPLD_KB_COL_LOW   (IDP_CPLD_PHYS + 0x10)

Definition at line 65 of file idp.h.

#define _IDP_CPLD_KB_ROW   (IDP_CPLD_PHYS + 0x50)

Definition at line 76 of file idp.h.

#define _IDP_CPLD_LCD   (IDP_CPLD_PHYS + 0x30)

Definition at line 73 of file idp.h.

#define _IDP_CPLD_LED_CONTROL   (IDP_CPLD_PHYS + 0x08)

Definition at line 63 of file idp.h.

#define _IDP_CPLD_MISC_CTRL   (IDP_CPLD_PHYS + 0x2C)

Definition at line 72 of file idp.h.

#define _IDP_CPLD_MISC_STATUS   (IDP_CPLD_PHYS + 0x5C)

Definition at line 79 of file idp.h.

#define _IDP_CPLD_PCCARD0_STATUS   (IDP_CPLD_PHYS + 0x54)

Definition at line 77 of file idp.h.

#define _IDP_CPLD_PCCARD1_STATUS   (IDP_CPLD_PHYS + 0x58)

Definition at line 78 of file idp.h.

#define _IDP_CPLD_PCCARD_EN   (IDP_CPLD_PHYS + 0x14)

Definition at line 66 of file idp.h.

#define _IDP_CPLD_PCCARD_PWR   (IDP_CPLD_PHYS + 0x28)

Definition at line 71 of file idp.h.

#define _IDP_CPLD_PERIPH_PWR   (IDP_CPLD_PHYS + 0x04)

Definition at line 62 of file idp.h.

#define _IDP_CPLD_REV   (IDP_CPLD_PHYS + 0x00)

Definition at line 61 of file idp.h.

#define _PCC_INPACK   (1 << 4)

Definition at line 128 of file idp.h.

#define _PCC_IRQ   (1 << 5)

Definition at line 127 of file idp.h.

#define _PCC_RESET   (1 << 6)

Definition at line 126 of file idp.h.

#define _PCC_WRPROT   (1 << 7)

Definition at line 125 of file idp.h.

#define CPLD_P2V (   x)    ((x) - IDP_CPLD_PHYS + IDP_CPLD_VIRT)

Definition at line 50 of file idp.h.

#define CPLD_V2P (   x)    ((x) - IDP_CPLD_VIRT + IDP_CPLD_PHYS)

Definition at line 51 of file idp.h.

#define ETHERNET_IRQ   PXA_GPIO_TO_IRQ(4)

Definition at line 141 of file idp.h.

#define ETHERNET_IRQ_EDGE   IRQ_TYPE_EDGE_RISING

Definition at line 142 of file idp.h.

#define FLASH_WRITE_PROTECT_DISABLE ( )    ((IDP_CPLD_FLASH_WE) &= ~(0x1))

Definition at line 170 of file idp.h.

#define FLASH_WRITE_PROTECT_ENABLE ( )    ((IDP_CPLD_FLASH_WE) |= (0x1))

Definition at line 171 of file idp.h.

#define IDE_IRQ   PXA_GPIO_TO_IRQ(21)

Definition at line 137 of file idp.h.

#define IDE_IRQ_EDGE   IRQ_TYPE_EDGE_RISING

Definition at line 144 of file idp.h.

#define IDP_ALT_FLASH_PHYS   (PXA_CS1_PHYS)

Definition at line 28 of file idp.h.

#define IDP_BUSY_LED   (1<<6)

Definition at line 162 of file idp.h.

#define IDP_COREVOLT_PHYS   (PXA_CS5_PHYS + 0x03800000)

Definition at line 32 of file idp.h.

#define IDP_COREVOLT_SIZE   (1*1024*1024)

Definition at line 41 of file idp.h.

#define IDP_COREVOLT_VIRT   (0xf0000000)

Definition at line 40 of file idp.h.

#define IDP_CPLD_FLASH_WE   __CPLD_REG(_IDP_CPLD_FLASH_WE)

Definition at line 96 of file idp.h.

#define IDP_CPLD_GPIOH_DIR   __CPLD_REG(_IDP_CPLD_GPIOH_DIR)

Definition at line 89 of file idp.h.

#define IDP_CPLD_GPIOH_VALUE   __CPLD_REG(_IDP_CPLD_GPIOH_VALUE)

Definition at line 90 of file idp.h.

#define IDP_CPLD_GPIOL_DIR   __CPLD_REG(_IDP_CPLD_GPIOL_DIR)

Definition at line 91 of file idp.h.

#define IDP_CPLD_GPIOL_VALUE   __CPLD_REG(_IDP_CPLD_GPIOL_VALUE)

Definition at line 92 of file idp.h.

#define IDP_CPLD_KB_COL_HIGH   __CPLD_REG(_IDP_CPLD_KB_COL_HIGH)

Definition at line 86 of file idp.h.

#define IDP_CPLD_KB_COL_LOW   __CPLD_REG(_IDP_CPLD_KB_COL_LOW)

Definition at line 87 of file idp.h.

#define IDP_CPLD_KB_ROW   __CPLD_REG(_IDP_CPLD_KB_ROW)

Definition at line 98 of file idp.h.

#define IDP_CPLD_LCD   __CPLD_REG(_IDP_CPLD_LCD)

Definition at line 95 of file idp.h.

#define IDP_CPLD_LED_CONTROL   __CPLD_REG(_IDP_CPLD_LED_CONTROL)

Definition at line 85 of file idp.h.

#define IDP_CPLD_MISC_CTRL   __CPLD_REG(_IDP_CPLD_MISC_CTRL)

Definition at line 94 of file idp.h.

#define IDP_CPLD_MISC_STATUS   __CPLD_REG(_IDP_CPLD_MISC_STATUS)

Definition at line 101 of file idp.h.

#define IDP_CPLD_PCCARD0_STATUS   __CPLD_REG(_IDP_CPLD_PCCARD0_STATUS)

Definition at line 99 of file idp.h.

#define IDP_CPLD_PCCARD1_STATUS   __CPLD_REG(_IDP_CPLD_PCCARD1_STATUS)

Definition at line 100 of file idp.h.

#define IDP_CPLD_PCCARD_EN   __CPLD_REG(_IDP_CPLD_PCCARD_EN)

Definition at line 88 of file idp.h.

#define IDP_CPLD_PCCARD_PWR   __CPLD_REG(_IDP_CPLD_PCCARD_PWR)

Definition at line 93 of file idp.h.

#define IDP_CPLD_PERIPH_PWR   __CPLD_REG(_IDP_CPLD_PERIPH_PWR)

Definition at line 84 of file idp.h.

#define IDP_CPLD_PHYS   (PXA_CS5_PHYS + 0x03C00000)

Definition at line 33 of file idp.h.

#define IDP_CPLD_REV   __CPLD_REG(_IDP_CPLD_REV)

Definition at line 83 of file idp.h.

#define IDP_CPLD_SIZE   (1*1024*1024)

Definition at line 44 of file idp.h.

#define IDP_CPLD_VIRT   (IDP_COREVOLT_VIRT + IDP_COREVOLT_SIZE)

Definition at line 43 of file idp.h.

#define IDP_ETH_PHYS   (PXA_CS5_PHYS + 0x03400000)

Definition at line 31 of file idp.h.

#define IDP_FLASH_PHYS   (PXA_CS0_PHYS)

Definition at line 27 of file idp.h.

#define IDP_HB_LED   (1<<5)

Definition at line 161 of file idp.h.

#define IDP_IDE_PHYS   (PXA_CS5_PHYS + 0x03000000)

Definition at line 30 of file idp.h.

#define IDP_LEDS_MASK   (IDP_HB_LED | IDP_BUSY_LED)

Definition at line 164 of file idp.h.

#define IDP_MEDIAQ_PHYS   (PXA_CS3_PHYS)

Definition at line 29 of file idp.h.

#define KEYBD_MATRIX_GET_INPUTS (   inputs)
Value:
{\
inputs = (IDP_CPLD_KB_ROW & 0x7f);\
}

Definition at line 192 of file idp.h.

#define KEYBD_MATRIX_INVERT_INPUT_LOGIC   FALSE

Definition at line 181 of file idp.h.

#define KEYBD_MATRIX_INVERT_OUTPUT_LOGIC   FALSE

Definition at line 180 of file idp.h.

#define KEYBD_MATRIX_KEYSTATE_DEBOUNCE_CONSTANT   2

Definition at line 184 of file idp.h.

#define KEYBD_MATRIX_NUMBER_INPUTS   7

Definition at line 177 of file idp.h.

#define KEYBD_MATRIX_NUMBER_OUTPUTS   14

Definition at line 178 of file idp.h.

#define KEYBD_MATRIX_SET_OUTPUTS (   outputs)
Value:
{\
IDP_CPLD_KB_COL_LOW = outputs;\
IDP_CPLD_KB_COL_HIGH = outputs >> 7;\
}

Definition at line 186 of file idp.h.

#define KEYBD_MATRIX_SETTLING_TIME_US   100

Definition at line 183 of file idp.h.

#define PCC0_ENABLE   (1 << 0)

Definition at line 121 of file idp.h.

#define PCC0_PWR0   (1 << 0)

Definition at line 109 of file idp.h.

#define PCC0_PWR1   (1 << 1)

Definition at line 110 of file idp.h.

#define PCC0_PWR2   (1 << 2)

Definition at line 111 of file idp.h.

#define PCC0_PWR3   (1 << 3)

Definition at line 112 of file idp.h.

#define PCC0_RESET   (1 << 6)

Definition at line 119 of file idp.h.

#define PCC1_ENABLE   (1 << 1)

Definition at line 122 of file idp.h.

#define PCC1_PWR0   (1 << 4)

Definition at line 113 of file idp.h.

#define PCC1_PWR1   (1 << 5)

Definition at line 114 of file idp.h.

#define PCC1_PWR2   (1 << 6)

Definition at line 115 of file idp.h.

#define PCC1_PWR3   (1 << 7)

Definition at line 116 of file idp.h.

#define PCC1_RESET   (1 << 7)

Definition at line 120 of file idp.h.

#define PCC_BVD1   (1 << 2)

Definition at line 130 of file idp.h.

#define PCC_BVD2   (1 << 3)

Definition at line 129 of file idp.h.

#define PCC_VS1   (1 << 0)

Definition at line 132 of file idp.h.

#define PCC_VS2   (1 << 1)

Definition at line 131 of file idp.h.

#define PCMCIA_S0_CD_VALID   PXA_GPIO_TO_IRQ(7)

Definition at line 146 of file idp.h.

#define PCMCIA_S0_CD_VALID_EDGE   IRQ_TYPE_EDGE_BOTH

Definition at line 147 of file idp.h.

#define PCMCIA_S0_RDYINT   PXA_GPIO_TO_IRQ(19)

Definition at line 152 of file idp.h.

#define PCMCIA_S1_CD_VALID   PXA_GPIO_TO_IRQ(8)

Definition at line 149 of file idp.h.

#define PCMCIA_S1_CD_VALID_EDGE   IRQ_TYPE_EDGE_BOTH

Definition at line 150 of file idp.h.

#define PCMCIA_S1_RDYINT   PXA_GPIO_TO_IRQ(22)

Definition at line 153 of file idp.h.

#define TOUCH_PANEL_IRQ   PXA_GPIO_TO_IRQ(5)

Definition at line 136 of file idp.h.

#define TOUCH_PANEL_IRQ_EDGE   IRQ_TYPE_EDGE_FALLING

Definition at line 139 of file idp.h.