media/bcm2835-unicam: Parse pad numbers correctly
authorDave Stevenson <dave.stevenson@raspberrypi.com>
Wed, 23 Sep 2020 14:16:18 +0000 (15:16 +0100)
committerDom Cobley <popcornmix@gmail.com>
Mon, 19 Feb 2024 11:33:13 +0000 (11:33 +0000)
commite4e414bc57f7913297cfeb8ec44c44b9960c277a
tree8196e100267e59b818acc69a6a71b880d1379308
parenta99215eabcd580dcc77b3c40d706bac0f8660f70
media/bcm2835-unicam: Parse pad numbers correctly

The driver was making big assumptions about the source device
using pad 0 and 1, which doesn't follow for more complex
devices where Unicam's source device may be a sink device for
something else.

Read the pad numbers through media controller, and reference
them appropriately.

Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
drivers/media/platform/bcm2835/bcm2835-unicam.c