Exemplo n.º 1
0
	return 0;
}

/* ----------------------------------------------------------------------- */

static struct i2c_driver driver = {
        .name           = "i2c tda9887 driver",
        .id             = -1, /* FIXME */
        .flags          = I2C_DF_NOTIFY,
        .attach_adapter = tda9887_probe,
        .detach_client  = tda9887_detach,
        .command        = tda9887_command,
};
static struct i2c_client client_template =
{
	I2C_DEVNAME("tda9887"),
	.flags     = I2C_CLIENT_ALLOW_USE,
        .driver    = &driver,
};

static int tda9887_init_module(void)
{
	i2c_add_driver(&driver);
	return 0;
}

static void tda9887_cleanup_module(void)
{
	i2c_del_driver(&driver);
}
Exemplo n.º 2
0
/* ----------------------------------------------------------------------- */

static struct i2c_driver driver = {
	.owner =		THIS_MODULE,
	.name =			"ovcamchip",
	.id =			I2C_DRIVERID_OVCAMCHIP,
	.class =		I2C_CLASS_CAM_DIGITAL,
	.flags =		I2C_DF_NOTIFY,
	.attach_adapter =	ovcamchip_attach,
	.detach_client =	ovcamchip_detach,
	.command =		ovcamchip_command,
};

static struct i2c_client client_template = {
	I2C_DEVNAME("(unset)"),
	.driver =	&driver,
};

static int __init ovcamchip_init(void)
{
#ifdef DEBUG
	ovcamchip_debug = debug;
#endif

	PINFO(DRIVER_VERSION " : " DRIVER_DESC);
	return i2c_add_driver(&driver);
}

static void __exit ovcamchip_exit(void)
{
Exemplo n.º 3
0
	return result;
}

static struct i2c_driver driver = {
	.owner	= THIS_MODULE,
	.name 	= "tea6415c",
	.id 	= I2C_DRIVERID_TEA6415C,
	.flags 	= I2C_DF_NOTIFY,
	.attach_adapter	= attach,
	.detach_client	= detach,
	.command	= command,
};

static struct i2c_client client_template = {
	I2C_DEVNAME("tea6415c"),
	.driver = &driver,
};

static int __init this_module_init(void)
{
	return i2c_add_driver(&driver);
}

static void __exit this_module_exit(void)
{
	i2c_del_driver(&driver);
}

module_init(this_module_init);
module_exit(this_module_exit);