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

Add ancillary links #123

Merged
merged 5 commits into from
Apr 29, 2022
Merged

Conversation

djrscally
Copy link
Collaborator

Ancillary links are a new kind of media link intended to describe the connection between media subdevs that are intended to operate as a single logical unit, principally flash LEDs and lens motors. Libcamera supports them already and includes auto focus algorithms now (at least on master) so with this series, the world facing camera should focus properly.

When iterating over the media graph, don't follow links that are not
data links.

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Daniel Scally <djrscally@gmail.com>
To describe in the kernel the connection between devices and their
supporting peripherals (for example, a camera sensor and the vcm
driving the focusing lens for it), add a new type of media link
to introduce the concept of these ancillary links.

Add some elements to the uAPI documentation to explain the new link
type, their purpose and some aspects of their current implementation.

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Daniel Scally <djrscally@gmail.com>
Now we have three types of media link, printing the right name during
debug output is slightly more complicated. Add a helper function to
make it easier.

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Daniel Scally <djrscally@gmail.com>
Add functions to create ancillary links, so that they don't need to
be manually created by users.

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Daniel Scally <djrscally@gmail.com>
Upon an async fwnode match, there's some typical behaviour that the
notifier and matching subdev will want to do. For example, a notifier
representing a sensor matching to an async subdev representing its
VCM will want to create an ancillary link to expose that relationship
to userspace.

To avoid lots of code in individual drivers, try to build these links
within v4l2 core.

Signed-off-by: Daniel Scally <djrscally@gmail.com>
@qzed
Copy link
Member

qzed commented Apr 29, 2022

Thanks, I'll give it a try in a second.

@qzed qzed merged commit 6ea3d62 into linux-surface:v5.17-surface-devel Apr 29, 2022
qzed added a commit to linux-surface/linux-surface that referenced this pull request Apr 29, 2022
Changes:
- Add auto-focus support for world-facing camera (@djrscally)
  - PR: linux-surface/kernel#123
- Refactor Surface Aggregator subsystem device hubs

Links:
- kernel: linux-surface/kernel@6ea3d62
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants