mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-30 08:02:30 +00:00
[media] as3645a: move relevant code under __devinit/__devexit
There is no needs to keep .remove under .exit.text. This driver is for a standalone chip that could be on any board and connected to any i2c bus. At the same time we don't need to keep the as3645a_probe() after initializing the device. Therefore we mark it and relevant functions with __devinit tag. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
parent
31ed29f981
commit
b151d9a231
1 changed files with 5 additions and 5 deletions
|
@ -713,7 +713,7 @@ static int as3645a_resume(struct device *dev)
|
||||||
* The number of LEDs reported in platform data is used to compute default
|
* The number of LEDs reported in platform data is used to compute default
|
||||||
* limits. Parameters passed through platform data can override those limits.
|
* limits. Parameters passed through platform data can override those limits.
|
||||||
*/
|
*/
|
||||||
static int as3645a_init_controls(struct as3645a *flash)
|
static int __devinit as3645a_init_controls(struct as3645a *flash)
|
||||||
{
|
{
|
||||||
const struct as3645a_platform_data *pdata = flash->pdata;
|
const struct as3645a_platform_data *pdata = flash->pdata;
|
||||||
struct v4l2_ctrl *ctrl;
|
struct v4l2_ctrl *ctrl;
|
||||||
|
@ -804,8 +804,8 @@ static int as3645a_init_controls(struct as3645a *flash)
|
||||||
return flash->ctrls.error;
|
return flash->ctrls.error;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int as3645a_probe(struct i2c_client *client,
|
static int __devinit as3645a_probe(struct i2c_client *client,
|
||||||
const struct i2c_device_id *devid)
|
const struct i2c_device_id *devid)
|
||||||
{
|
{
|
||||||
struct as3645a *flash;
|
struct as3645a *flash;
|
||||||
int ret;
|
int ret;
|
||||||
|
@ -846,7 +846,7 @@ static int as3645a_probe(struct i2c_client *client,
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int __exit as3645a_remove(struct i2c_client *client)
|
static int __devexit as3645a_remove(struct i2c_client *client)
|
||||||
{
|
{
|
||||||
struct v4l2_subdev *subdev = i2c_get_clientdata(client);
|
struct v4l2_subdev *subdev = i2c_get_clientdata(client);
|
||||||
struct as3645a *flash = to_as3645a(subdev);
|
struct as3645a *flash = to_as3645a(subdev);
|
||||||
|
@ -877,7 +877,7 @@ static struct i2c_driver as3645a_i2c_driver = {
|
||||||
.pm = &as3645a_pm_ops,
|
.pm = &as3645a_pm_ops,
|
||||||
},
|
},
|
||||||
.probe = as3645a_probe,
|
.probe = as3645a_probe,
|
||||||
.remove = __exit_p(as3645a_remove),
|
.remove = __devexit_p(as3645a_remove),
|
||||||
.id_table = as3645a_id_table,
|
.id_table = as3645a_id_table,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue