From 2a262f7bdef014895fbf941eab8c44b6700d96d7 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Mon, 5 Jun 2023 19:09:16 +0200 Subject: [PATCH] 5.10-stable patches added patches: eth-sun-cassini-remove-dead-code.patch --- .../eth-sun-cassini-remove-dead-code.patch | 47 +++++++++++++++++++ queue-5.10/series | 1 + 2 files changed, 48 insertions(+) create mode 100644 queue-5.10/eth-sun-cassini-remove-dead-code.patch diff --git a/queue-5.10/eth-sun-cassini-remove-dead-code.patch b/queue-5.10/eth-sun-cassini-remove-dead-code.patch new file mode 100644 index 00000000000..f063e500785 --- /dev/null +++ b/queue-5.10/eth-sun-cassini-remove-dead-code.patch @@ -0,0 +1,47 @@ +From 32329216ca1d6ee29c41215f18b3053bb6158541 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Martin=20Li=C5=A1ka?= +Date: Wed, 18 May 2022 09:18:53 +0200 +Subject: eth: sun: cassini: remove dead code +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: Martin Liška + +commit 32329216ca1d6ee29c41215f18b3053bb6158541 upstream. + +Fixes the following GCC warning: + +drivers/net/ethernet/sun/cassini.c:1316:29: error: comparison between two arrays [-Werror=array-compare] +drivers/net/ethernet/sun/cassini.c:3783:34: error: comparison between two arrays [-Werror=array-compare] + +Note that 2 arrays should be compared by comparing of their addresses: +note: use ‘&cas_prog_workaroundtab[0] == &cas_prog_null[0]’ to compare the addresses + +Signed-off-by: Martin Liska +Signed-off-by: David S. Miller +Signed-off-by: Greg Kroah-Hartman +--- + drivers/net/ethernet/sun/cassini.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +--- a/drivers/net/ethernet/sun/cassini.c ++++ b/drivers/net/ethernet/sun/cassini.c +@@ -1325,7 +1325,7 @@ static void cas_init_rx_dma(struct cas * + writel(val, cp->regs + REG_RX_PAGE_SIZE); + + /* enable the header parser if desired */ +- if (CAS_HP_FIRMWARE == cas_prog_null) ++ if (&CAS_HP_FIRMWARE[0] == &cas_prog_null[0]) + return; + + val = CAS_BASE(HP_CFG_NUM_CPU, CAS_NCPUS > 63 ? 0 : CAS_NCPUS); +@@ -3793,7 +3793,7 @@ static void cas_reset(struct cas *cp, in + + /* program header parser */ + if ((cp->cas_flags & CAS_FLAG_TARGET_ABORT) || +- (CAS_HP_ALT_FIRMWARE == cas_prog_null)) { ++ (&CAS_HP_ALT_FIRMWARE[0] == &cas_prog_null[0])) { + cas_load_firmware(cp, CAS_HP_FIRMWARE); + } else { + cas_load_firmware(cp, CAS_HP_ALT_FIRMWARE); diff --git a/queue-5.10/series b/queue-5.10/series index cd3a271841d..17ec2ef9bd1 100644 --- a/queue-5.10/series +++ b/queue-5.10/series @@ -91,3 +91,4 @@ x86-boot-wrap-literal-addresses-in-absolute_pointer.patch acpi-thermal-drop-an-always-true-check.patch ath6kl-use-struct_group-to-avoid-size-mismatched-casting.patch gcc-12-disable-wdangling-pointer-warning-for-now.patch +eth-sun-cassini-remove-dead-code.patch -- 2.47.3