Skip to content

Commit

Permalink
media: entity: Pass entity to get_fwnode_pad operation
Browse files Browse the repository at this point in the history
Add a missing pointer to the entity in the media_entity operation
get_fwnode_pad. There are no implementers of this op yet, but a future
entity that does so will almost certainly need a reference to itself
to carry out the work.

operation")

Fixes: ae45cd5 ("[media] media: entity: Add get_fwnode_pad entity
Signed-off-by: Steve Longerbeam <[email protected]>
Reviewed-by: Laurent Pinchart <[email protected]>
Signed-off-by: Sakari Ailus <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
  • Loading branch information
slongerbeam authored and mchehab committed May 18, 2020
1 parent b2bbf1a commit 70d4a9e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion drivers/media/mc/mc-entity.c
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,7 @@ int media_entity_get_fwnode_pad(struct media_entity *entity,
if (ret)
return ret;

ret = entity->ops->get_fwnode_pad(&endpoint);
ret = entity->ops->get_fwnode_pad(entity, &endpoint);
if (ret < 0)
return ret;

Expand Down
3 changes: 2 additions & 1 deletion include/media/media-entity.h
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,8 @@ struct media_pad {
* mutex held.
*/
struct media_entity_operations {
int (*get_fwnode_pad)(struct fwnode_endpoint *endpoint);
int (*get_fwnode_pad)(struct media_entity *entity,
struct fwnode_endpoint *endpoint);
int (*link_setup)(struct media_entity *entity,
const struct media_pad *local,
const struct media_pad *remote, u32 flags);
Expand Down

0 comments on commit 70d4a9e

Please sign in to comment.