]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
6.1-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 17 Sep 2023 07:11:05 +0000 (09:11 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 17 Sep 2023 07:11:05 +0000 (09:11 +0200)
added patches:
drm-amd-display-fix-a-bug-when-searching-for-insert_above_mpcc.patch
mips-only-fiddle-with-checkflags-if-need-compiler.patch

queue-6.1/drm-amd-display-fix-a-bug-when-searching-for-insert_above_mpcc.patch [new file with mode: 0644]
queue-6.1/mips-only-fiddle-with-checkflags-if-need-compiler.patch [new file with mode: 0644]
queue-6.1/series

diff --git a/queue-6.1/drm-amd-display-fix-a-bug-when-searching-for-insert_above_mpcc.patch b/queue-6.1/drm-amd-display-fix-a-bug-when-searching-for-insert_above_mpcc.patch
new file mode 100644 (file)
index 0000000..ec7e0bf
--- /dev/null
@@ -0,0 +1,43 @@
+From 3d028d5d60d516c536de1ddd3ebf3d55f3f8983b Mon Sep 17 00:00:00 2001
+From: Wesley Chalmers <wesley.chalmers@amd.com>
+Date: Wed, 21 Jun 2023 19:13:26 -0400
+Subject: drm/amd/display: Fix a bug when searching for insert_above_mpcc
+
+From: Wesley Chalmers <wesley.chalmers@amd.com>
+
+commit 3d028d5d60d516c536de1ddd3ebf3d55f3f8983b upstream.
+
+[WHY]
+Currently, when insert_plane is called with insert_above_mpcc
+parameter that is equal to tree->opp_list, the function returns NULL.
+
+[HOW]
+Instead, the function should insert the plane at the top of the tree.
+
+Cc: Mario Limonciello <mario.limonciello@amd.com>
+Cc: Alex Deucher <alexander.deucher@amd.com>
+Cc: stable@vger.kernel.org
+Reviewed-by: Jun Lei <jun.lei@amd.com>
+Acked-by: Tom Chung <chiahsuan.chung@amd.com>
+Signed-off-by: Wesley Chalmers <wesley.chalmers@amd.com>
+Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/gpu/drm/amd/display/dc/dcn10/dcn10_mpc.c |    5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+--- a/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_mpc.c
++++ b/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_mpc.c
+@@ -212,8 +212,9 @@ struct mpcc *mpc1_insert_plane(
+               /* check insert_above_mpcc exist in tree->opp_list */
+               struct mpcc *temp_mpcc = tree->opp_list;
+-              while (temp_mpcc && temp_mpcc->mpcc_bot != insert_above_mpcc)
+-                      temp_mpcc = temp_mpcc->mpcc_bot;
++              if (temp_mpcc != insert_above_mpcc)
++                      while (temp_mpcc && temp_mpcc->mpcc_bot != insert_above_mpcc)
++                              temp_mpcc = temp_mpcc->mpcc_bot;
+               if (temp_mpcc == NULL)
+                       return NULL;
+       }
diff --git a/queue-6.1/mips-only-fiddle-with-checkflags-if-need-compiler.patch b/queue-6.1/mips-only-fiddle-with-checkflags-if-need-compiler.patch
new file mode 100644 (file)
index 0000000..382c904
--- /dev/null
@@ -0,0 +1,54 @@
+From 4fe4a6374c4db9ae2b849b61e84b58685dca565a Mon Sep 17 00:00:00 2001
+From: "Maciej W. Rozycki" <macro@orcam.me.uk>
+Date: Tue, 18 Jul 2023 15:37:23 +0100
+Subject: MIPS: Only fiddle with CHECKFLAGS if `need-compiler'
+
+From: Maciej W. Rozycki <macro@orcam.me.uk>
+
+commit 4fe4a6374c4db9ae2b849b61e84b58685dca565a upstream.
+
+We have originally guarded fiddling with CHECKFLAGS in our arch Makefile
+by checking for the CONFIG_MIPS variable, not set for targets such as
+`distclean', etc. that neither include `.config' nor use the compiler.
+
+Starting from commit 805b2e1d427a ("kbuild: include Makefile.compiler
+only when compiler is needed") we have had a generic `need-compiler'
+variable explicitly telling us if the compiler will be used and thus its
+capabilities need to be checked and expressed in the form of compilation
+flags.  If this variable is not set, then `make' functions such as
+`cc-option' are undefined, causing all kinds of weirdness to happen if
+we expect specific results to be returned, most recently:
+
+cc1: error: '-mloongson-mmi' must be used with '-mhard-float'
+
+messages with configurations such as `fuloong2e_defconfig' and the
+`modules_install' target, which does include `.config' and yet does not
+use the compiler.
+
+Replace the check for CONFIG_MIPS with one for `need-compiler' instead,
+so as to prevent the compiler from being ever called for CHECKFLAGS when
+not needed.
+
+Reported-by: Guillaume Tucker <guillaume.tucker@collabora.com>
+Closes: https://lore.kernel.org/r/85031c0c-d981-031e-8a50-bc4fad2ddcd8@collabora.com/
+Signed-off-by: Maciej W. Rozycki <macro@orcam.me.uk>
+Fixes: 805b2e1d427a ("kbuild: include Makefile.compiler only when compiler is needed")
+Cc: stable@vger.kernel.org # v5.13+
+Reported-by: "kernelci.org bot" <bot@kernelci.org>
+Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ arch/mips/Makefile |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/arch/mips/Makefile
++++ b/arch/mips/Makefile
+@@ -350,7 +350,7 @@ KBUILD_CFLAGS += -fno-asynchronous-unwin
+ KBUILD_LDFLAGS                += -m $(ld-emul)
+-ifdef CONFIG_MIPS
++ifdef need-compiler
+ CHECKFLAGS += $(shell $(CC) $(KBUILD_CFLAGS) -dM -E -x c /dev/null | \
+       egrep -vw '__GNUC_(MINOR_|PATCHLEVEL_)?_' | \
+       sed -e "s/^\#define /-D'/" -e "s/ /'='/" -e "s/$$/'/" -e 's/\$$/&&/g')
index e15119f45cce1f0d453f82ac01d5522990b1487b..c75381e02e6b16070f429597a84e4971488036ea 100644 (file)
@@ -216,3 +216,5 @@ tcp-fix-bind-regression-for-v4-mapped-v6-wildcard-ad.patch
 tcp-fix-bind-regression-for-v4-mapped-v6-non-wildcar.patch
 ixgbe-fix-timestamp-configuration-code.patch
 kcm-fix-error-handling-for-sock_dgram-in-kcm_sendmsg.patch
+mips-only-fiddle-with-checkflags-if-need-compiler.patch
+drm-amd-display-fix-a-bug-when-searching-for-insert_above_mpcc.patch