Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
gpio_extended.c File Reference
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/init.h>
#include <linux/gpio.h>
#include <linux/io.h>

Go to the source code of this file.

Data Structures

struct  msp71xx_exd_gpio_chip
 

Macros

#define MSP71XX_DATA_OFFSET(gpio)   (2 * (gpio))
 
#define MSP71XX_READ_OFFSET(gpio)   (MSP71XX_DATA_OFFSET(gpio) + 1)
 
#define MSP71XX_CFG_OUT_OFFSET(gpio)   (MSP71XX_DATA_OFFSET(gpio) + 16)
 
#define MSP71XX_CFG_IN_OFFSET(gpio)   (MSP71XX_CFG_OUT_OFFSET(gpio) + 1)
 
#define MSP71XX_EXD_GPIO_BASE   0x0BC000000L
 
#define to_msp71xx_exd_gpio_chip(c)   container_of(c, struct msp71xx_exd_gpio_chip, chip)
 
#define MSP71XX_EXD_GPIO_BANK(name, exd_reg, base_gpio, num_gpio)
 

Functions

void __init msp71xx_init_gpio_extended (void)
 

Macro Definition Documentation

#define MSP71XX_CFG_IN_OFFSET (   gpio)    (MSP71XX_CFG_OUT_OFFSET(gpio) + 1)

Definition at line 22 of file gpio_extended.c.

#define MSP71XX_CFG_OUT_OFFSET (   gpio)    (MSP71XX_DATA_OFFSET(gpio) + 16)

Definition at line 21 of file gpio_extended.c.

#define MSP71XX_DATA_OFFSET (   gpio)    (2 * (gpio))

Definition at line 19 of file gpio_extended.c.

#define MSP71XX_EXD_GPIO_BANK (   name,
  exd_reg,
  base_gpio,
  num_gpio 
)
Value:
{ \
.chip = { \
.label = name, \
.direction_input = msp71xx_exd_direction_input, \
.direction_output = msp71xx_exd_direction_output, \
.get = msp71xx_exd_gpio_get, \
.set = msp71xx_exd_gpio_set, \
.base = base_gpio, \
.ngpio = num_gpio, \
}, \
.reg = (void __iomem *)(MSP71XX_EXD_GPIO_BASE + exd_reg), \
}

Definition at line 110 of file gpio_extended.c.

#define MSP71XX_EXD_GPIO_BASE   0x0BC000000L

Definition at line 24 of file gpio_extended.c.

#define MSP71XX_READ_OFFSET (   gpio)    (MSP71XX_DATA_OFFSET(gpio) + 1)

Definition at line 20 of file gpio_extended.c.

#define to_msp71xx_exd_gpio_chip (   c)    container_of(c, struct msp71xx_exd_gpio_chip, chip)

Definition at line 26 of file gpio_extended.c.

Function Documentation

void __init msp71xx_init_gpio_extended ( void  )

Definition at line 140 of file gpio_extended.c.