Linux Kernel
3.7.1
|
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/types.h>
#include <linux/slab.h>
#include <linux/sched.h>
#include <linux/wait.h>
#include <linux/delay.h>
#include <linux/init.h>
#include <linux/interrupt.h>
#include <linux/of.h>
#include <linux/of_device.h>
#include <asm/bbc.h>
#include <asm/io.h>
#include "bbc_i2c.h"
Go to the source code of this file.
Macros | |
#define | I2C_PCF_PIN 0x80 |
#define | I2C_PCF_ESO 0x40 |
#define | I2C_PCF_ES1 0x20 |
#define | I2C_PCF_ES2 0x10 |
#define | I2C_PCF_ENI 0x08 |
#define | I2C_PCF_STA 0x04 |
#define | I2C_PCF_STO 0x02 |
#define | I2C_PCF_ACK 0x01 |
#define | I2C_PCF_START (I2C_PCF_PIN | I2C_PCF_ESO | I2C_PCF_ENI | I2C_PCF_STA | I2C_PCF_ACK) |
#define | I2C_PCF_STOP (I2C_PCF_PIN | I2C_PCF_ESO | I2C_PCF_STO | I2C_PCF_ACK) |
#define | I2C_PCF_REPSTART ( I2C_PCF_ESO | I2C_PCF_STA | I2C_PCF_ACK) |
#define | I2C_PCF_IDLE (I2C_PCF_PIN | I2C_PCF_ESO | I2C_PCF_ACK) |
#define | I2C_PCF_INI 0x40 /* 1 if not initialized */ |
#define | I2C_PCF_STS 0x20 |
#define | I2C_PCF_BER 0x10 |
#define | I2C_PCF_AD0 0x08 |
#define | I2C_PCF_LRB 0x08 |
#define | I2C_PCF_AAS 0x04 |
#define | I2C_PCF_LAB 0x02 |
#define | I2C_PCF_BB 0x01 |
#define | claim_device(BP, ECHILD) set_device_claimage(BP,ECHILD,1) |
#define | release_device(BP, ECHILD) set_device_claimage(BP,ECHILD,0) |
Functions | |
struct platform_device * | bbc_i2c_getdev (struct bbc_i2c_bus *bp, int index) |
struct bbc_i2c_client * | bbc_i2c_attach (struct bbc_i2c_bus *bp, struct platform_device *op) |
void | bbc_i2c_detach (struct bbc_i2c_client *client) |
int | bbc_i2c_writeb (struct bbc_i2c_client *client, unsigned char val, int off) |
int | bbc_i2c_readb (struct bbc_i2c_client *client, unsigned char *byte, int off) |
int | bbc_i2c_write_buf (struct bbc_i2c_client *client, char *buf, int len, int off) |
int | bbc_i2c_read_buf (struct bbc_i2c_client *client, char *buf, int len, int off) |
EXPORT_SYMBOL (bbc_i2c_getdev) | |
EXPORT_SYMBOL (bbc_i2c_attach) | |
EXPORT_SYMBOL (bbc_i2c_detach) | |
EXPORT_SYMBOL (bbc_i2c_writeb) | |
EXPORT_SYMBOL (bbc_i2c_readb) | |
EXPORT_SYMBOL (bbc_i2c_write_buf) | |
EXPORT_SYMBOL (bbc_i2c_read_buf) | |
int | bbc_envctrl_init (struct bbc_i2c_bus *bp) |
void | bbc_envctrl_cleanup (struct bbc_i2c_bus *bp) |
MODULE_DEVICE_TABLE (of, bbc_i2c_match) | |
module_platform_driver (bbc_i2c_driver) | |
MODULE_LICENSE ("GPL") | |
#define I2C_PCF_IDLE (I2C_PCF_PIN | I2C_PCF_ESO | I2C_PCF_ACK) |
#define I2C_PCF_REPSTART ( I2C_PCF_ESO | I2C_PCF_STA | I2C_PCF_ACK) |
#define I2C_PCF_START (I2C_PCF_PIN | I2C_PCF_ESO | I2C_PCF_ENI | I2C_PCF_STA | I2C_PCF_ACK) |
#define I2C_PCF_STOP (I2C_PCF_PIN | I2C_PCF_ESO | I2C_PCF_STO | I2C_PCF_ACK) |
void bbc_envctrl_cleanup | ( | struct bbc_i2c_bus * | bp | ) |
Definition at line 588 of file bbc_envctrl.c.
int bbc_envctrl_init | ( | struct bbc_i2c_bus * | bp | ) |
Definition at line 560 of file bbc_envctrl.c.
|
read |
void bbc_i2c_detach | ( | struct bbc_i2c_client * | client | ) |
|
read |
int bbc_i2c_readb | ( | struct bbc_i2c_client * | client, |
unsigned char * | byte, | ||
int | off | ||
) |
int bbc_i2c_writeb | ( | struct bbc_i2c_client * | client, |
unsigned char | val, | ||
int | off | ||
) |
EXPORT_SYMBOL | ( | bbc_i2c_getdev | ) |
EXPORT_SYMBOL | ( | bbc_i2c_attach | ) |
EXPORT_SYMBOL | ( | bbc_i2c_detach | ) |
EXPORT_SYMBOL | ( | bbc_i2c_writeb | ) |
EXPORT_SYMBOL | ( | bbc_i2c_readb | ) |
EXPORT_SYMBOL | ( | bbc_i2c_write_buf | ) |
EXPORT_SYMBOL | ( | bbc_i2c_read_buf | ) |
MODULE_DEVICE_TABLE | ( | of | , |
bbc_i2c_match | |||
) |
MODULE_LICENSE | ( | "GPL" | ) |
module_platform_driver | ( | bbc_i2c_driver | ) |