From 20ea6adbf199097c4f5f591ffee088340630dae4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lvaro=20Fern=C3=A1ndez=20Rojas?= Date: Mon, 16 May 2022 23:40:32 +0200 Subject: bcm27xx: add support for linux v5.15 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Build system: x86_64 Build-tested: bcm2708, bcm2709, bcm2710, bcm2711 Run-tested: bcm2708/RPiB+, bcm2709/RPi3B, bcm2710/RPi3B, bcm2711/RPi4B Signed-off-by: Marty Jones Signed-off-by: Álvaro Fernández Rojas --- ...ty-Skip-non-data-links-in-graph-iteration.patch | 29 ++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 target/linux/bcm27xx/patches-5.15/950-0767-media-entity-Skip-non-data-links-in-graph-iteration.patch (limited to 'target/linux/bcm27xx/patches-5.15/950-0767-media-entity-Skip-non-data-links-in-graph-iteration.patch') diff --git a/target/linux/bcm27xx/patches-5.15/950-0767-media-entity-Skip-non-data-links-in-graph-iteration.patch b/target/linux/bcm27xx/patches-5.15/950-0767-media-entity-Skip-non-data-links-in-graph-iteration.patch new file mode 100644 index 0000000000..a99a529831 --- /dev/null +++ b/target/linux/bcm27xx/patches-5.15/950-0767-media-entity-Skip-non-data-links-in-graph-iteration.patch @@ -0,0 +1,29 @@ +From 74a4bd2caa37f07786cdf3e86ad9f7cbc6977b31 Mon Sep 17 00:00:00 2001 +From: Daniel Scally +Date: Wed, 2 Mar 2022 22:03:00 +0000 +Subject: [PATCH] media: entity: Skip non-data links in graph iteration + +When iterating over the media graph, don't follow links that are not +data links. + +Reviewed-by: Laurent Pinchart +Signed-off-by: Daniel Scally +--- + drivers/media/mc/mc-entity.c | 6 ++++++ + 1 file changed, 6 insertions(+) + +--- a/drivers/media/mc/mc-entity.c ++++ b/drivers/media/mc/mc-entity.c +@@ -313,6 +313,12 @@ static void media_graph_walk_iter(struct + + link = list_entry(link_top(graph), typeof(*link), list); + ++ /* If the link is not a data link, don't follow it */ ++ if ((link->flags & MEDIA_LNK_FL_LINK_TYPE) != MEDIA_LNK_FL_DATA_LINK) { ++ link_top(graph) = link_top(graph)->next; ++ return; ++ } ++ + /* The link is not enabled so we do not follow. */ + if (!(link->flags & MEDIA_LNK_FL_ENABLED)) { + link_top(graph) = link_top(graph)->next; -- cgit v1.2.3