Lines Matching refs:dw9807_dev

150 static void dw9807_subdev_cleanup(struct dw9807_device *dw9807_dev)  in dw9807_subdev_cleanup()  argument
152 v4l2_async_unregister_subdev(&dw9807_dev->sd); in dw9807_subdev_cleanup()
153 v4l2_ctrl_handler_free(&dw9807_dev->ctrls_vcm); in dw9807_subdev_cleanup()
154 media_entity_cleanup(&dw9807_dev->sd.entity); in dw9807_subdev_cleanup()
180 struct dw9807_device *dw9807_dev; in dw9807_probe() local
183 dw9807_dev = devm_kzalloc(&client->dev, sizeof(*dw9807_dev), in dw9807_probe()
185 if (dw9807_dev == NULL) in dw9807_probe()
188 v4l2_i2c_subdev_init(&dw9807_dev->sd, client, &dw9807_ops); in dw9807_probe()
189 dw9807_dev->sd.flags |= V4L2_SUBDEV_FL_HAS_DEVNODE; in dw9807_probe()
190 dw9807_dev->sd.internal_ops = &dw9807_int_ops; in dw9807_probe()
192 rval = dw9807_init_controls(dw9807_dev); in dw9807_probe()
196 rval = media_entity_pads_init(&dw9807_dev->sd.entity, 0, NULL); in dw9807_probe()
200 dw9807_dev->sd.entity.function = MEDIA_ENT_F_LENS; in dw9807_probe()
202 rval = v4l2_async_register_subdev(&dw9807_dev->sd); in dw9807_probe()
213 v4l2_ctrl_handler_free(&dw9807_dev->ctrls_vcm); in dw9807_probe()
214 media_entity_cleanup(&dw9807_dev->sd.entity); in dw9807_probe()
222 struct dw9807_device *dw9807_dev = sd_to_dw9807_vcm(sd); in dw9807_remove() local
226 dw9807_subdev_cleanup(dw9807_dev); in dw9807_remove()
238 struct dw9807_device *dw9807_dev = sd_to_dw9807_vcm(sd); in dw9807_vcm_suspend() local
242 for (val = dw9807_dev->current_val & ~(DW9807_CTRL_STEPS - 1); in dw9807_vcm_suspend()
270 struct dw9807_device *dw9807_dev = sd_to_dw9807_vcm(sd); in dw9807_vcm_resume() local
281 for (val = dw9807_dev->current_val % DW9807_CTRL_STEPS; in dw9807_vcm_resume()
282 val < dw9807_dev->current_val + DW9807_CTRL_STEPS - 1; in dw9807_vcm_resume()