2010-03-06 04:44:34 +07:00
|
|
|
#ifndef _LINUX_PCA953X_H
|
|
|
|
#define _LINUX_PCA953X_H
|
|
|
|
|
|
|
|
#include <linux/types.h>
|
|
|
|
#include <linux/i2c.h>
|
|
|
|
|
2008-02-05 13:28:26 +07:00
|
|
|
/* platform data for the PCA9539 16-bit I/O expander driver */
|
|
|
|
|
2008-02-06 16:39:03 +07:00
|
|
|
struct pca953x_platform_data {
|
2008-02-05 13:28:26 +07:00
|
|
|
/* number of the first GPIO */
|
|
|
|
unsigned gpio_base;
|
|
|
|
|
|
|
|
/* initial polarity inversion setting */
|
|
|
|
uint16_t invert;
|
|
|
|
|
2010-03-06 04:44:36 +07:00
|
|
|
/* interrupt base */
|
|
|
|
int irq_base;
|
|
|
|
|
2008-02-05 13:28:26 +07:00
|
|
|
void *context; /* param to setup/teardown */
|
|
|
|
|
|
|
|
int (*setup)(struct i2c_client *client,
|
|
|
|
unsigned gpio, unsigned ngpio,
|
|
|
|
void *context);
|
|
|
|
int (*teardown)(struct i2c_client *client,
|
|
|
|
unsigned gpio, unsigned ngpio,
|
|
|
|
void *context);
|
2009-06-18 06:26:15 +07:00
|
|
|
char **names;
|
2008-02-05 13:28:26 +07:00
|
|
|
};
|
2010-03-06 04:44:34 +07:00
|
|
|
|
|
|
|
#endif /* _LINUX_PCA953X_H */
|