Lines Matching defs:state

154 	struct tw2804 *state = to_state(sd);
157 state->norm & V4L2_STD_525_60 ? "60 Hz" : "50 Hz");
158 v4l2_info(sd, "Channel: %d\n", state->channel);
159 v4l2_info(sd, "Input: %d\n", state->input);
178 struct tw2804 *state = to_state_from_ctrl(ctrl);
179 struct i2c_client *client = v4l2_get_subdevdata(&state->sd);
203 struct tw2804 *state = to_state_from_ctrl(ctrl);
204 struct i2c_client *client = v4l2_get_subdevdata(&state->sd);
211 reg = read_reg(client, addr, state->channel);
218 return write_reg(client, addr, reg, state->channel);
222 reg = read_reg(client, addr, state->channel);
226 return write_reg(client, addr, reg, state->channel);
242 ctrl->val, state->channel);
246 ctrl->val, state->channel);
250 ctrl->val, state->channel);
254 ctrl->val, state->channel);
362 struct tw2804 *state;
370 state = devm_kzalloc(&client->dev, sizeof(*state), GFP_KERNEL);
371 if (state == NULL)
373 sd = &state->sd;
375 state->channel = -1;
376 state->norm = V4L2_STD_NTSC;
378 v4l2_ctrl_handler_init(&state->hdl, 10);
379 v4l2_ctrl_new_std(&state->hdl, &tw2804_ctrl_ops,
381 v4l2_ctrl_new_std(&state->hdl, &tw2804_ctrl_ops,
383 v4l2_ctrl_new_std(&state->hdl, &tw2804_ctrl_ops,
385 v4l2_ctrl_new_std(&state->hdl, &tw2804_ctrl_ops,
387 v4l2_ctrl_new_std(&state->hdl, &tw2804_ctrl_ops,
389 v4l2_ctrl_new_std(&state->hdl, &tw2804_ctrl_ops,
391 ctrl = v4l2_ctrl_new_std(&state->hdl, &tw2804_ctrl_ops,
395 ctrl = v4l2_ctrl_new_std(&state->hdl, &tw2804_ctrl_ops,
399 ctrl = v4l2_ctrl_new_std(&state->hdl, &tw2804_ctrl_ops,
403 ctrl = v4l2_ctrl_new_std(&state->hdl, &tw2804_ctrl_ops,
407 sd->ctrl_handler = &state->hdl;
408 err = state->hdl.error;
410 v4l2_ctrl_handler_free(&state->hdl);
423 struct tw2804 *state = to_state(sd);
426 v4l2_ctrl_handler_free(&state->hdl);