media: platform: mtk-mdp3: Use devicetree phandle to retrieve SCP
authorAngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Thu, 5 Oct 2023 10:49:05 +0000 (12:49 +0200)
committerHans Verkuil <hverkuil-cisco@xs4all.nl>
Thu, 7 Dec 2023 07:31:14 +0000 (08:31 +0100)
commit52e1fc9aa8282d783f6cfedd79b79db98259900c
treed4c4cf310978dacad03b576d975e64b6c5e9f276
parenta60577cef7de982166baa132a8423f413b617b63
media: platform: mtk-mdp3: Use devicetree phandle to retrieve SCP

Instead of walking the entire parent node for something that has the
right compatible, use the scp_get() function provided by the MediaTek
SCP remoteproc driver to retrieve a handle to mtk_scp through the
devicetree "mediatek,scp" (phandle) property.

In case of multi-core SCP, this also allows to select a specific core.

Reviewed-by: Chen-Yu Tsai <wenst@chromium.org>
Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Reviewed-by: Alexandre Mergnat <amergnat@baylibre.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
drivers/media/platform/mediatek/mdp3/mtk-mdp3-core.c