Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] alternative split devices #417

Closed
wants to merge 28 commits into from
Closed

Commits on Mar 13, 2021

  1. clang-format

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 13, 2021
    Configuration menu
    Copy the full SHA
    1a9445e View commit details
    Browse the repository at this point in the history

Commits on Mar 17, 2021

  1. Configuration menu
    Copy the full SHA
    d3f7442 View commit details
    Browse the repository at this point in the history
  2. drop hacks for linux<<3

    umlaeute authored and vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    1ca5cce View commit details
    Browse the repository at this point in the history
  3. mention that linux<<3.0.0 is unsupported

    umlaeute authored and vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    7bace70 View commit details
    Browse the repository at this point in the history
  4. drop VIDIOCGMBUF support

    V4L1 has been completely removed from kernel since 2.6.39.
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    89b476b View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    790a046 View commit details
    Browse the repository at this point in the history
  6. mod: add output_nr module parameter in parallel with video_nr

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    c256fb7 View commit details
    Browse the repository at this point in the history
  7. keep track of both output_nr and capture_nr in IDR

    With this change, output_nr will be allocated and deallocated as
    capture_nr is, but currently saved with no other reference to it.
    
    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    03366a7 View commit details
    Browse the repository at this point in the history
  8. refactor v4l2loopback_lookup

    Since now both output_nr and capture_nr are meaningful, don't return
    either of them.
    
    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    727e625 View commit details
    Browse the repository at this point in the history
  9. cache vdev for latter uses

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    32cbef3 View commit details
    Browse the repository at this point in the history
  10. embed struct video_device into v4l2_loopback_device

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    6c6a6c1 View commit details
    Browse the repository at this point in the history
  11. set v4l2_loopback_device addr as video_device drvdata instead

    Converting function v4l2loopback_cd2dev and v4l2loopback_getdevice
    searches v4l2loopback_index_idr with device number retrieved from
    video_device drvdata, but this could be time consuming and creates
    unecessary complexity. And since we may need to retrieve
    v4l2_loopback_device address from callbacks shared between capture and
    output devices, this patch reuses video_device drvdata instead of struct
    member offsets.
    
    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    c580737 View commit details
    Browse the repository at this point in the history
  12. move v4l2_loopback_device->vdev into v4l2_loopback_device->capture

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    fd056bd View commit details
    Browse the repository at this point in the history
  13. move all vdev init procedures into init_vdev

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    2670509 View commit details
    Browse the repository at this point in the history
  14. fix cap->device_caps may not be defined before v3.3

    Also use V4L2_CAP_DEVICE_CAPS to detect this instead of hardcoded kernel
    version.
    
    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    68616dd View commit details
    Browse the repository at this point in the history
  15. don't change device state in vidioc_s_fmt_out

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    eeb0625 View commit details
    Browse the repository at this point in the history
  16. create a draft output video_device

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    50e2fcf View commit details
    Browse the repository at this point in the history
  17. remove dev->output_nr

    Since we have already instantiated an output video device, use its `num`
    field instead.
    
    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    210e307 View commit details
    Browse the repository at this point in the history
  18. output: add ioctl handlers

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    babaffe View commit details
    Browse the repository at this point in the history
  19. re-implement a separate output device

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    2f0fb5a View commit details
    Browse the repository at this point in the history
  20. prepare to share output/capture entity init

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    4e0ef85 View commit details
    Browse the repository at this point in the history
  21. capture: init vb2_queue

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    6d4a482 View commit details
    Browse the repository at this point in the history
  22. capture: use fops callback from videobuf2

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    37c700e View commit details
    Browse the repository at this point in the history
  23. [wip] reimplement capture entity using videobuf2

    Signed-off-by: You-Sheng Yang <vicamo@gmail.com>
    vicamo committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    ac6439b View commit details
    Browse the repository at this point in the history

Commits on Mar 18, 2021

  1. Configuration menu
    Copy the full SHA
    8a94f49 View commit details
    Browse the repository at this point in the history

Commits on Mar 19, 2021

  1. clang-format

    umlaeute committed Mar 19, 2021
    Configuration menu
    Copy the full SHA
    2350269 View commit details
    Browse the repository at this point in the history
  2. simplified capabilities logic (with only split-devices), setting CAPT…

    …URE only for capture devices
    umlaeute committed Mar 19, 2021
    Configuration menu
    Copy the full SHA
    3a1ab9a View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    2e76bec View commit details
    Browse the repository at this point in the history