Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
gpio-cfg-helpers.h File Reference

Go to the source code of this file.

Macros

#define __PLAT_GPIO_CFG_HELPERS_H   __FILE__
 

Functions

int s3c24xx_gpio_setpull_1up (struct samsung_gpio_chip *chip, unsigned int off, samsung_gpio_pull_t pull)
 
int s3c24xx_gpio_setpull_1down (struct samsung_gpio_chip *chip, unsigned int off, samsung_gpio_pull_t pull)
 
int samsung_gpio_setpull_updown (struct samsung_gpio_chip *chip, unsigned int off, samsung_gpio_pull_t pull)
 
samsung_gpio_pull_t samsung_gpio_getpull_updown (struct samsung_gpio_chip *chip, unsigned int off)
 
samsung_gpio_pull_t s3c24xx_gpio_getpull_1up (struct samsung_gpio_chip *chip, unsigned int off)
 
samsung_gpio_pull_t s3c24xx_gpio_getpull_1down (struct samsung_gpio_chip *chip, unsigned int off)
 
int s3c2443_gpio_setpull (struct samsung_gpio_chip *chip, unsigned int off, samsung_gpio_pull_t pull)
 
samsung_gpio_pull_t s3c2443_gpio_getpull (struct samsung_gpio_chip *chip, unsigned int off)
 

Macro Definition Documentation

#define __PLAT_GPIO_CFG_HELPERS_H   __FILE__

Definition at line 20 of file gpio-cfg-helpers.h.

Function Documentation

samsung_gpio_pull_t s3c2443_gpio_getpull ( struct samsung_gpio_chip chip,
unsigned int  off 
)

s3c2443_gpio_getpull() - Get configuration for s3c2443 pull resistors : The gpio chip that the GPIO pin belongs to. : The offset to the pin to get the configuration of.

This helper function reads the state of the pull-{up,down} resistor for the given GPIO in the same case as samsung_gpio_setpull_upown.

Definition at line 96 of file gpio-samsung.c.

int s3c2443_gpio_setpull ( struct samsung_gpio_chip chip,
unsigned int  off,
samsung_gpio_pull_t  pull 
)

s3c2443_gpio_setpull() - Pull configuration for s3c2443. : The gpio chip that is being configured. : The offset for the GPIO being configured.

Parameters
pull: The pull mode being requested.

This is a helper function for the case where we have GPIOs with two bits configuring the presence of a pull resistor, in the following order: 00 = Pull-up resistor connected 10 = Pull-down resistor connected x1 = No pull up resistor

Definition at line 79 of file gpio-samsung.c.

samsung_gpio_pull_t s3c24xx_gpio_getpull_1down ( struct samsung_gpio_chip chip,
unsigned int  off 
)

s3c24xx_gpio_getpull_1down() - Get configuration for choice of down or none : The gpio chip that the GPIO pin belongs to : The offset to the pin to get the configuration of.

This helper function reads the state of the pull-down resistor for the given GPIO in the same case as s3c24xx_gpio_setpull_1down.

Definition at line 160 of file gpio-samsung.c.

samsung_gpio_pull_t s3c24xx_gpio_getpull_1up ( struct samsung_gpio_chip chip,
unsigned int  off 
)

s3c24xx_gpio_getpull_1up() - Get configuration for choice of up or none : The gpio chip that the GPIO pin belongs to : The offset to the pin to get the configuration of.

This helper function reads the state of the pull-up resistor for the given GPIO in the same case as s3c24xx_gpio_setpull_1up.

Definition at line 148 of file gpio-samsung.c.

int s3c24xx_gpio_setpull_1down ( struct samsung_gpio_chip chip,
unsigned int  off,
samsung_gpio_pull_t  pull 
)

s3c24xx_gpio_setpull_1down() - Pull configuration for choice of down or none : The gpio chip that is being configured : The offset for the GPIO being configured

Parameters
pull: The pull mode being requested

This is a helper function for the case where we have GPIOs with one bit configuring the presence of a pull-down resistor.

Definition at line 166 of file gpio-samsung.c.

int s3c24xx_gpio_setpull_1up ( struct samsung_gpio_chip chip,
unsigned int  off,
samsung_gpio_pull_t  pull 
)

s3c24xx_gpio_setpull_1up() - Pull configuration for choice of up or none. : The gpio chip that is being configured. : The offset for the GPIO being configured.

Parameters
pull: The pull mode being requested.

This is a helper function for the case where we have GPIOs with one bit configuring the presence of a pull-up resistor.

Definition at line 154 of file gpio-samsung.c.

samsung_gpio_pull_t samsung_gpio_getpull_updown ( struct samsung_gpio_chip chip,
unsigned int  off 
)

samsung_gpio_getpull_updown() - Get configuration for choice of up, down or none

: The gpio chip that the GPIO pin belongs to : The offset to the pin to get the configuration of.

This helper function reads the state of the pull-{up,down} resistor for the given GPIO in the same case as samsung_gpio_setpull_upown.

Definition at line 66 of file gpio-samsung.c.

int samsung_gpio_setpull_updown ( struct samsung_gpio_chip chip,
unsigned int  off,
samsung_gpio_pull_t  pull 
)

samsung_gpio_setpull_upown() - Pull configuration for choice of up, down or none

: The gpio chip that is being configured. : The offset for the GPIO being configured.

Parameters
pull: The pull mode being requested.

This is a helper function for the case where we have GPIOs with two bits configuring the presence of a pull resistor, in the following order: 00 = No pull resistor connected 01 = Pull-up resistor connected 10 = Pull-down resistor connected

Definition at line 51 of file gpio-samsung.c.