|
Linux Kernel
3.7.1
|
#include <linux/kernel.h>#include <linux/module.h>#include <linux/init.h>#include <linux/errno.h>#include <linux/platform_device.h>#include <linux/i2c.h>#include <linux/interrupt.h>#include <linux/wait.h>#include <linux/i2c-ocores.h>#include <linux/slab.h>#include <linux/io.h>#include <linux/of_i2c.h>#include <linux/log2.h>Go to the source code of this file.
Data Structures | |
| struct | ocores_i2c |
Macros | |
| #define | OCI2C_PRELOW 0 |
| #define | OCI2C_PREHIGH 1 |
| #define | OCI2C_CONTROL 2 |
| #define | OCI2C_DATA 3 |
| #define | OCI2C_CMD 4 /* write only */ |
| #define | OCI2C_STATUS 4 /* read only, same address as OCI2C_CMD */ |
| #define | OCI2C_CTRL_IEN 0x40 |
| #define | OCI2C_CTRL_EN 0x80 |
| #define | OCI2C_CMD_START 0x91 |
| #define | OCI2C_CMD_STOP 0x41 |
| #define | OCI2C_CMD_READ 0x21 |
| #define | OCI2C_CMD_WRITE 0x11 |
| #define | OCI2C_CMD_READ_ACK 0x21 |
| #define | OCI2C_CMD_READ_NACK 0x29 |
| #define | OCI2C_CMD_IACK 0x01 |
| #define | OCI2C_STAT_IF 0x01 |
| #define | OCI2C_STAT_TIP 0x02 |
| #define | OCI2C_STAT_ARBLOST 0x20 |
| #define | OCI2C_STAT_BUSY 0x40 |
| #define | OCI2C_STAT_NACK 0x80 |
| #define | STATE_DONE 0 |
| #define | STATE_START 1 |
| #define | STATE_WRITE 2 |
| #define | STATE_READ 3 |
| #define | STATE_ERROR 4 |
| #define | ocores_i2c_of_probe(pdev, i2c) -ENODEV |
| #define | OCORES_I2C_PM NULL |
Functions | |
| MODULE_DEVICE_TABLE (of, ocores_i2c_match) | |
| module_platform_driver (ocores_i2c_driver) | |
| MODULE_AUTHOR ("Peter Korsgaard <[email protected]>") | |
| MODULE_DESCRIPTION ("OpenCores I2C bus driver") | |
| MODULE_LICENSE ("GPL") | |
| MODULE_ALIAS ("platform:ocores-i2c") | |
| #define OCI2C_CMD 4 /* write only */ |
Definition at line 48 of file i2c-ocores.c.
| #define OCI2C_CMD_IACK 0x01 |
Definition at line 60 of file i2c-ocores.c.
| #define OCI2C_CMD_READ 0x21 |
Definition at line 56 of file i2c-ocores.c.
| #define OCI2C_CMD_READ_ACK 0x21 |
Definition at line 58 of file i2c-ocores.c.
| #define OCI2C_CMD_READ_NACK 0x29 |
Definition at line 59 of file i2c-ocores.c.
| #define OCI2C_CMD_START 0x91 |
Definition at line 54 of file i2c-ocores.c.
| #define OCI2C_CMD_STOP 0x41 |
Definition at line 55 of file i2c-ocores.c.
| #define OCI2C_CMD_WRITE 0x11 |
Definition at line 57 of file i2c-ocores.c.
| #define OCI2C_CONTROL 2 |
Definition at line 46 of file i2c-ocores.c.
| #define OCI2C_CTRL_EN 0x80 |
Definition at line 52 of file i2c-ocores.c.
| #define OCI2C_CTRL_IEN 0x40 |
Definition at line 51 of file i2c-ocores.c.
| #define OCI2C_DATA 3 |
Definition at line 47 of file i2c-ocores.c.
| #define OCI2C_PREHIGH 1 |
Definition at line 45 of file i2c-ocores.c.
| #define OCI2C_PRELOW 0 |
Definition at line 44 of file i2c-ocores.c.
| #define OCI2C_STAT_ARBLOST 0x20 |
Definition at line 64 of file i2c-ocores.c.
| #define OCI2C_STAT_BUSY 0x40 |
Definition at line 65 of file i2c-ocores.c.
| #define OCI2C_STAT_IF 0x01 |
Definition at line 62 of file i2c-ocores.c.
| #define OCI2C_STAT_NACK 0x80 |
Definition at line 66 of file i2c-ocores.c.
| #define OCI2C_STAT_TIP 0x02 |
Definition at line 63 of file i2c-ocores.c.
Definition at line 49 of file i2c-ocores.c.
Definition at line 263 of file i2c-ocores.c.
| #define OCORES_I2C_PM NULL |
Definition at line 387 of file i2c-ocores.c.
| #define STATE_DONE 0 |
Definition at line 68 of file i2c-ocores.c.
| #define STATE_ERROR 4 |
Definition at line 72 of file i2c-ocores.c.
| #define STATE_READ 3 |
Definition at line 71 of file i2c-ocores.c.
| #define STATE_START 1 |
Definition at line 69 of file i2c-ocores.c.
| #define STATE_WRITE 2 |
Definition at line 70 of file i2c-ocores.c.
| MODULE_ALIAS | ( | "platform:ocores-i2c" | ) |
| MODULE_AUTHOR | ( | "Peter Korsgaard <[email protected]>" | ) |
| MODULE_DEVICE_TABLE | ( | of | , |
| ocores_i2c_match | |||
| ) |
| MODULE_LICENSE | ( | "GPL" | ) |
| module_platform_driver | ( | ocores_i2c_driver | ) |
1.8.2