- 论坛徽章:
- 0
|
struct i2c_driver {
unsigned int class;
int (* attach_adapter) (struct i2c_adapter *);
int (* detach_adapter) (struct i2c_adapter *);
int (* probe) (struct i2c_client *, const struct i2c_device_id *);
int (* remove) (struct i2c_client *);
void (* shutdown) (struct i2c_client *);
int (* suspend) (struct i2c_client *, pm_message_t mesg);
int (* resume) (struct i2c_client *);
int (* command) (struct i2c_client *client, unsigned int cmd, void *arg);
struct device_driver driver;
const struct i2c_device_id * id_table;
int (* detect) (struct i2c_client *, int kind, struct i2c_board_info *);
const struct i2c_client_address_data * address_data;
struct list_head clients;
};
在I2C驱动中,command这一项是不是能用ioctl把命令传到函数中!跟ioctl一样使用! |
|