Re: [PATCH 01/15] media: atomisp: Adjust for v4l2_subdev_state handling changes in 6.8

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Dec 31, 2023 at 12:31 PM Hans de Goede <hdegoede@xxxxxxxxxx> wrote:
>
> The atomisp driver emulates a standard v4l2 device, which also works
> for non media-controller aware applications.
>
> Part of this requires making try_fmt calls on the sensor when
> a normal v4l2 app is making try_fmt calls on the /dev/video# mode.
>
> With the recent v4l2_subdev_state handling changes in 6.8 this no longer
> works, fixing this requires 2 changes:
>
> 1. The atomisp code was using its own internal v4l2_subdev_pad_config
>    for this. Replace the internal v4l2_subdev_pad_config with allocating
>    a full v4l2_subdev_state for storing the full try_fmt state.
>
> 2. The paths actually setting the fmt or crop selection now need to be
>    passed the v4l2_subdev's active state, so that sensor drivers which
>    are using the v4l2_subdev's active state to store their state keep
>    working.

Two comments:
- why not 'if (!ret)' in a few cases?
- can actually v4l2 generic code define a class for
v4l2_subdev_lock_state() (and friends) via cleanup.h and hence make
those labels and unlocking calls unneeded with use of guard() /
scoped_guard()?


-- 
With Best Regards,
Andy Shevchenko





[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux