Re: question about soc_camera_open
Thank you for comment
> > soc_camera_open use icd->current_fmt directly.
> > It doesn't check if icd->current_fmt != NULL.
> Which kernel version, resp., version of the soc-camera stack are you
> using? What you describe would be a bug, but it shouldn't be present
> neither in the soc-camera stack, converted to v4l2-subdev (see my last
> series of 10 patches), nor in a partially converted stack.
I use latest Paul's (for SH) git
> is present in the current mainline. There's a call to
> if (icd->ops->remove)
> missing on the "goto eiufmt;" error path. You'd just have to insert the
> above call before the goto. Would you like to prepare a patch?
why can I call soc_camera_open even if soc_camera_probe failed ?
I'm not sure why... but...
following is my kernel panic story.
1) I use "soc_camera_platform" and "sh_mobile_ceu" driver.
2) soc_camera_platform_info :: bus_param = SOCAM_xxx;
this bus_param is miss mach to sh_mobile_ceu.
ex) if it use SOCAM_DATAWIDTH_4, sh_mobile_ceu can not use it.
3) soc_camera_bus_param_compatible will be return 0
I think this behavior is correct
4) sh_mobile_ceu_get_formats return 0
because sh_mobile_ceu_try_bus_param return 0
5) soc_camera_init_user_formats return -ENXIO
because fmts is 0.
then, icd->current_fmt is still NULL.
6) when I use mplayer, kernel panic occur on soc_camera_open.
because .pixelformat = icd->current_fmt->fourcc will access NULL address
but why can I call soc_camera_open ?
video4linux-list mailing list