• Niklas Söderlund's avatar
    media: rcar-vin: add link notify for Gen3 · c0cc5aef
    Niklas Söderlund authored
    Add the ability to process media device link change requests. Link
    enabling is a bit complicated on Gen3, whether or not it's possible to
    enable a link depends on what other links already are enabled. On Gen3
    the 8 VINs are split into two subgroup's (VIN0-3 and VIN4-7) and from a
    routing perspective these two groups are independent of each other.
    Each subgroup's routing is controlled by the subgroup VIN master
    instance (VIN0 and VIN4).
    
    There are a limited number of possible route setups available for each
    subgroup and the configuration of each setup is dictated by the
    hardware. On H3 for example there are 6 possible route setups for each
    subgroup to choose from.
    
    This leads to the media device link notification code being rather large
    since it will find the best routing configuration to try and accommodate
    as many links as possible. When it's not possible to enable a new link
    due to hardware constrains the link_notifier callback will return
    -EMLINK.
    Signed-off-by: default avatarNiklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
    Reviewed-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
    Signed-off-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
    Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
    c0cc5aef
rcar-core.c 23.2 KB