|
Linux Kernel
3.7.1
|
#include <linux/kernel.h>#include <linux/module.h>#include <linux/init.h>#include <linux/platform_device.h>#include <linux/i2c.h>#include <linux/interrupt.h>#include <linux/completion.h>#include <linux/mutex.h>#include <linux/delay.h>#include <linux/io.h>Go to the source code of this file.
Data Structures | |
| struct | pmcmsptwi_clock |
| struct | pmcmsptwi_clockcfg |
| struct | pmcmsptwi_cfg |
| struct | pmcmsptwi_cmd |
| struct | pmcmsptwi_data |
Macros | |
| #define | DRV_NAME "pmcmsptwi" |
| #define | MSP_TWI_SF_CLK_REG_OFFSET 0x00 |
| #define | MSP_TWI_HS_CLK_REG_OFFSET 0x04 |
| #define | MSP_TWI_CFG_REG_OFFSET 0x08 |
| #define | MSP_TWI_CMD_REG_OFFSET 0x0c |
| #define | MSP_TWI_ADD_REG_OFFSET 0x10 |
| #define | MSP_TWI_DAT_0_REG_OFFSET 0x14 |
| #define | MSP_TWI_DAT_1_REG_OFFSET 0x18 |
| #define | MSP_TWI_INT_STS_REG_OFFSET 0x1c |
| #define | MSP_TWI_INT_MSK_REG_OFFSET 0x20 |
| #define | MSP_TWI_BUSY_REG_OFFSET 0x24 |
| #define | MSP_TWI_INT_STS_DONE (1 << 0) |
| #define | MSP_TWI_INT_STS_LOST_ARBITRATION (1 << 1) |
| #define | MSP_TWI_INT_STS_NO_RESPONSE (1 << 2) |
| #define | MSP_TWI_INT_STS_DATA_COLLISION (1 << 3) |
| #define | MSP_TWI_INT_STS_BUSY (1 << 4) |
| #define | MSP_TWI_INT_STS_ALL 0x1f |
| #define | MSP_MAX_BYTES_PER_RW 8 |
| #define | MSP_MAX_POLL 5 |
| #define | MSP_POLL_DELAY 10 |
| #define | MSP_IRQ_TIMEOUT (MSP_MAX_POLL * MSP_POLL_DELAY) |
| #define | pmcmsptwi_readl __raw_readl |
| #define | pmcmsptwi_writel __raw_writel |
Enumerations | |
| enum | pmcmsptwi_cmd_type { MSP_TWI_CMD_WRITE = 0, MSP_TWI_CMD_READ = 1, MSP_TWI_CMD_WRITE_READ = 2 } |
| enum | pmcmsptwi_xfer_result { MSP_TWI_XFER_OK = 0, MSP_TWI_XFER_TIMEOUT, MSP_TWI_XFER_BUSY, MSP_TWI_XFER_DATA_COLLISION, MSP_TWI_XFER_NO_RESPONSE, MSP_TWI_XFER_LOST_ARBITRATION } |
Functions | |
| module_platform_driver (pmcmsptwi_driver) | |
| MODULE_DESCRIPTION ("PMC MSP TWI/SMBus/I2C driver") | |
| MODULE_LICENSE ("GPL") | |
| MODULE_ALIAS ("platform:"DRV_NAME) | |
| #define DRV_NAME "pmcmsptwi" |
Definition at line 38 of file i2c-pmcmsp.c.
| #define MSP_IRQ_TIMEOUT (MSP_MAX_POLL * MSP_POLL_DELAY) |
Definition at line 61 of file i2c-pmcmsp.c.
| #define MSP_MAX_BYTES_PER_RW 8 |
Definition at line 58 of file i2c-pmcmsp.c.
| #define MSP_MAX_POLL 5 |
Definition at line 59 of file i2c-pmcmsp.c.
| #define MSP_POLL_DELAY 10 |
Definition at line 60 of file i2c-pmcmsp.c.
| #define MSP_TWI_ADD_REG_OFFSET 0x10 |
Definition at line 44 of file i2c-pmcmsp.c.
| #define MSP_TWI_BUSY_REG_OFFSET 0x24 |
Definition at line 49 of file i2c-pmcmsp.c.
| #define MSP_TWI_CFG_REG_OFFSET 0x08 |
Definition at line 42 of file i2c-pmcmsp.c.
| #define MSP_TWI_CMD_REG_OFFSET 0x0c |
Definition at line 43 of file i2c-pmcmsp.c.
| #define MSP_TWI_DAT_0_REG_OFFSET 0x14 |
Definition at line 45 of file i2c-pmcmsp.c.
| #define MSP_TWI_DAT_1_REG_OFFSET 0x18 |
Definition at line 46 of file i2c-pmcmsp.c.
| #define MSP_TWI_HS_CLK_REG_OFFSET 0x04 |
Definition at line 41 of file i2c-pmcmsp.c.
| #define MSP_TWI_INT_MSK_REG_OFFSET 0x20 |
Definition at line 48 of file i2c-pmcmsp.c.
| #define MSP_TWI_INT_STS_ALL 0x1f |
Definition at line 56 of file i2c-pmcmsp.c.
| #define MSP_TWI_INT_STS_BUSY (1 << 4) |
Definition at line 55 of file i2c-pmcmsp.c.
| #define MSP_TWI_INT_STS_DATA_COLLISION (1 << 3) |
Definition at line 54 of file i2c-pmcmsp.c.
| #define MSP_TWI_INT_STS_DONE (1 << 0) |
Definition at line 51 of file i2c-pmcmsp.c.
| #define MSP_TWI_INT_STS_LOST_ARBITRATION (1 << 1) |
Definition at line 52 of file i2c-pmcmsp.c.
| #define MSP_TWI_INT_STS_NO_RESPONSE (1 << 2) |
Definition at line 53 of file i2c-pmcmsp.c.
| #define MSP_TWI_INT_STS_REG_OFFSET 0x1c |
Definition at line 47 of file i2c-pmcmsp.c.
| #define MSP_TWI_SF_CLK_REG_OFFSET 0x00 |
Definition at line 40 of file i2c-pmcmsp.c.
| #define pmcmsptwi_readl __raw_readl |
Definition at line 64 of file i2c-pmcmsp.c.
| #define pmcmsptwi_writel __raw_writel |
Definition at line 65 of file i2c-pmcmsp.c.
| enum pmcmsptwi_cmd_type |
Definition at line 68 of file i2c-pmcmsp.c.
| MSP_TWI_XFER_OK | |
| MSP_TWI_XFER_TIMEOUT | |
| MSP_TWI_XFER_BUSY | |
| MSP_TWI_XFER_DATA_COLLISION | |
| MSP_TWI_XFER_NO_RESPONSE | |
| MSP_TWI_XFER_LOST_ARBITRATION |
Definition at line 75 of file i2c-pmcmsp.c.
| MODULE_ALIAS | ( | "platform:" | DRV_NAME | ) |
| MODULE_LICENSE | ( | "GPL" | ) |
| module_platform_driver | ( | pmcmsptwi_driver | ) |
1.8.2