mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-11 04:18:39 +08:00
Renesas R-Car VSP1 driver regression fix
-----BEGIN PGP SIGNATURE----- iJgEABYKAEAWIQTAnvhxs4J7QT+XHKnMPy2AAyfeZAUCZVGCnCIcbGF1cmVudC5w aW5jaGFydEBpZGVhc29uYm9hcmQuY29tAAoJEMw/LYADJ95kxTwBAIpJM1mmwLk8 yp3Nl5N27oz30kmuO7MjemiWSGWZ+vqpAQCkXN33z0dUZcAPGBkrFc0sDfuef1Qh onPrtXwtmh8QCQ== =/yLm -----END PGP SIGNATURE----- Merge tag 'media-renesas-fixes-20231113' of git://git.kernel.org/pub/scm/linux/kernel/git/pinchartl/linux.git Laurent Pinchart says: ---------------------------------------------------------------- Renesas R-Car VSP1 driver regression fix ---------------------------------------------------------------- Laurent Pinchart (1): media: vsp1: Remove unbalanced .s_stream(0) calls Link: https://lore.kernel.org/linux-media/20231113020054.GA18039@pendragon.ideasonboard.com/ Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
This commit is contained in:
commit
32138be394
@ -373,7 +373,7 @@ int vsp1_pipeline_stop(struct vsp1_pipeline *pipe)
|
||||
(7 << VI6_DPR_SMPPT_TGW_SHIFT) |
|
||||
(VI6_DPR_NODE_UNUSED << VI6_DPR_SMPPT_PT_SHIFT));
|
||||
|
||||
v4l2_subdev_call(&pipe->output->entity.subdev, video, s_stream, 0);
|
||||
vsp1_wpf_stop(pipe->output);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
@ -43,14 +43,6 @@ static inline void vsp1_rpf_write(struct vsp1_rwpf *rpf,
|
||||
data);
|
||||
}
|
||||
|
||||
/* -----------------------------------------------------------------------------
|
||||
* V4L2 Subdevice Operations
|
||||
*/
|
||||
|
||||
static const struct v4l2_subdev_ops rpf_ops = {
|
||||
.pad = &vsp1_rwpf_pad_ops,
|
||||
};
|
||||
|
||||
/* -----------------------------------------------------------------------------
|
||||
* VSP1 Entity Operations
|
||||
*/
|
||||
@ -411,7 +403,7 @@ struct vsp1_rwpf *vsp1_rpf_create(struct vsp1_device *vsp1, unsigned int index)
|
||||
rpf->entity.index = index;
|
||||
|
||||
sprintf(name, "rpf.%u", index);
|
||||
ret = vsp1_entity_init(vsp1, &rpf->entity, name, 2, &rpf_ops,
|
||||
ret = vsp1_entity_init(vsp1, &rpf->entity, name, 2, &vsp1_rwpf_subdev_ops,
|
||||
MEDIA_ENT_F_PROC_VIDEO_PIXEL_FORMATTER);
|
||||
if (ret < 0)
|
||||
return ERR_PTR(ret);
|
||||
|
@ -24,7 +24,7 @@ struct v4l2_rect *vsp1_rwpf_get_crop(struct vsp1_rwpf *rwpf,
|
||||
}
|
||||
|
||||
/* -----------------------------------------------------------------------------
|
||||
* V4L2 Subdevice Pad Operations
|
||||
* V4L2 Subdevice Operations
|
||||
*/
|
||||
|
||||
static int vsp1_rwpf_enum_mbus_code(struct v4l2_subdev *subdev,
|
||||
@ -243,7 +243,7 @@ done:
|
||||
return ret;
|
||||
}
|
||||
|
||||
const struct v4l2_subdev_pad_ops vsp1_rwpf_pad_ops = {
|
||||
static const struct v4l2_subdev_pad_ops vsp1_rwpf_pad_ops = {
|
||||
.init_cfg = vsp1_entity_init_cfg,
|
||||
.enum_mbus_code = vsp1_rwpf_enum_mbus_code,
|
||||
.enum_frame_size = vsp1_rwpf_enum_frame_size,
|
||||
@ -253,6 +253,10 @@ const struct v4l2_subdev_pad_ops vsp1_rwpf_pad_ops = {
|
||||
.set_selection = vsp1_rwpf_set_selection,
|
||||
};
|
||||
|
||||
const struct v4l2_subdev_ops vsp1_rwpf_subdev_ops = {
|
||||
.pad = &vsp1_rwpf_pad_ops,
|
||||
};
|
||||
|
||||
/* -----------------------------------------------------------------------------
|
||||
* Controls
|
||||
*/
|
||||
|
@ -79,9 +79,11 @@ static inline struct vsp1_rwpf *entity_to_rwpf(struct vsp1_entity *entity)
|
||||
struct vsp1_rwpf *vsp1_rpf_create(struct vsp1_device *vsp1, unsigned int index);
|
||||
struct vsp1_rwpf *vsp1_wpf_create(struct vsp1_device *vsp1, unsigned int index);
|
||||
|
||||
void vsp1_wpf_stop(struct vsp1_rwpf *wpf);
|
||||
|
||||
int vsp1_rwpf_init_ctrls(struct vsp1_rwpf *rwpf, unsigned int ncontrols);
|
||||
|
||||
extern const struct v4l2_subdev_pad_ops vsp1_rwpf_pad_ops;
|
||||
extern const struct v4l2_subdev_ops vsp1_rwpf_subdev_ops;
|
||||
|
||||
struct v4l2_rect *vsp1_rwpf_get_crop(struct vsp1_rwpf *rwpf,
|
||||
struct v4l2_subdev_state *sd_state);
|
||||
|
@ -186,17 +186,13 @@ static int wpf_init_controls(struct vsp1_rwpf *wpf)
|
||||
}
|
||||
|
||||
/* -----------------------------------------------------------------------------
|
||||
* V4L2 Subdevice Core Operations
|
||||
* VSP1 Entity Operations
|
||||
*/
|
||||
|
||||
static int wpf_s_stream(struct v4l2_subdev *subdev, int enable)
|
||||
void vsp1_wpf_stop(struct vsp1_rwpf *wpf)
|
||||
{
|
||||
struct vsp1_rwpf *wpf = to_rwpf(subdev);
|
||||
struct vsp1_device *vsp1 = wpf->entity.vsp1;
|
||||
|
||||
if (enable)
|
||||
return 0;
|
||||
|
||||
/*
|
||||
* Write to registers directly when stopping the stream as there will be
|
||||
* no pipeline run to apply the display list.
|
||||
@ -204,27 +200,8 @@ static int wpf_s_stream(struct v4l2_subdev *subdev, int enable)
|
||||
vsp1_write(vsp1, VI6_WPF_IRQ_ENB(wpf->entity.index), 0);
|
||||
vsp1_write(vsp1, wpf->entity.index * VI6_WPF_OFFSET +
|
||||
VI6_WPF_SRCRPF, 0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* -----------------------------------------------------------------------------
|
||||
* V4L2 Subdevice Operations
|
||||
*/
|
||||
|
||||
static const struct v4l2_subdev_video_ops wpf_video_ops = {
|
||||
.s_stream = wpf_s_stream,
|
||||
};
|
||||
|
||||
static const struct v4l2_subdev_ops wpf_ops = {
|
||||
.video = &wpf_video_ops,
|
||||
.pad = &vsp1_rwpf_pad_ops,
|
||||
};
|
||||
|
||||
/* -----------------------------------------------------------------------------
|
||||
* VSP1 Entity Operations
|
||||
*/
|
||||
|
||||
static void vsp1_wpf_destroy(struct vsp1_entity *entity)
|
||||
{
|
||||
struct vsp1_rwpf *wpf = entity_to_rwpf(entity);
|
||||
@ -583,7 +560,7 @@ struct vsp1_rwpf *vsp1_wpf_create(struct vsp1_device *vsp1, unsigned int index)
|
||||
wpf->entity.index = index;
|
||||
|
||||
sprintf(name, "wpf.%u", index);
|
||||
ret = vsp1_entity_init(vsp1, &wpf->entity, name, 2, &wpf_ops,
|
||||
ret = vsp1_entity_init(vsp1, &wpf->entity, name, 2, &vsp1_rwpf_subdev_ops,
|
||||
MEDIA_ENT_F_PROC_VIDEO_PIXEL_FORMATTER);
|
||||
if (ret < 0)
|
||||
return ERR_PTR(ret);
|
||||
|
Loading…
Reference in New Issue
Block a user