diff options
author | Hans de Goede <hdegoede@redhat.com> | 2023-01-29 21:49:10 +0100 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@kernel.org> | 2023-02-08 08:07:32 +0100 |
commit | c7c49ac854d0d3ef8ff8ab7e667482faa813e757 (patch) | |
tree | 10194c1b7a8db216c293d4cc09d83e68d8771cce /include/media | |
parent | media: atomisp: Remove isp_subdev_link_setup() (diff) | |
download | linux-c7c49ac854d0d3ef8ff8ab7e667482faa813e757.tar.xz linux-c7c49ac854d0d3ef8ff8ab7e667482faa813e757.zip |
media: atomisp: Remove csi2_link_setup()
Looking at csi2_link_setup(), this function can never work,
it does a switch-case like this:
switch (local->index | is_media_entity_v4l2_subdev(remote->entity))
with cases like this:
case ATOMISP_SUBDEV_PAD_SOURCE | MEDIA_ENT_F_V4L2_SUBDEV_UNKNOWN
where ATOMISP_SUBDEV_PAD_SOURCE matches an index (0-1) and
MEDIA_ENT_F_V4L2_SUBDEV_UNKNOWN is 0x00020000, but
is_media_entity_v4l2_subdev(remote->entity) does not return
MEDIA_ENT_F_* values, it return a bool, so 0 or 1 which means
that non of the cases can ever match the input value.
Looking at the rest of the function all it ever does (if it
would actually hit one of the cases) is set the atomisp_mipi_csi2_device
struct's output member.
And checking the rest of the atomisp code that member is never
read. Also userspace does not actually setup media-controller
links when using the atomisp /dev/video$ nodes since all the links
are fixed. So csi2_link_setup() never runs.
Remove the unnecessary and broken csi2_link_setup() function
and also remove the unused atomisp_mipi_csi2_device struct's
output member.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Diffstat (limited to 'include/media')
0 files changed, 0 insertions, 0 deletions