From: Gautam Menghani <gautam@linux.ibm.com>
To: mpe@ellerman.id.au, npiggin@gmail.com, christophe.leroy@csgroup.eu
Cc: Gautam Menghani <gautam@linux.ibm.com>,
linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org
Subject: [PATCH] arch/powerpc: Remove unnecessary endian conversion code in XICS
Date: Fri, 30 Jun 2023 11:26:28 +0530 [thread overview]
Message-ID: <20230630055628.17790-1-gautam@linux.ibm.com> (raw)
Remove an unnecessary piece of code that does an endianness conversion but
does not use the result. The following warning was reported by Clang's
static analyzer:
arch/powerpc/sysdev/xics/ics-opal.c:114:2: warning: Value stored to
'server' is never read [deadcode.DeadStores]
server = be16_to_cpu(oserver);
As the result of endianness conversion is never used, delete the line
and fix the warning.
Signed-off-by: Gautam Menghani <gautam@linux.ibm.com>
---
arch/powerpc/sysdev/xics/ics-opal.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/arch/powerpc/sysdev/xics/ics-opal.c b/arch/powerpc/sysdev/xics/ics-opal.c
index 6cfbb4fac7fb..5fe73dabab79 100644
--- a/arch/powerpc/sysdev/xics/ics-opal.c
+++ b/arch/powerpc/sysdev/xics/ics-opal.c
@@ -111,7 +111,6 @@ static int ics_opal_set_affinity(struct irq_data *d,
__func__, d->irq, hw_irq, rc);
return -1;
}
- server = be16_to_cpu(oserver);
wanted_server = xics_get_irq_server(d->irq, cpumask, 1);
if (wanted_server < 0) {
--
2.39.3
next reply other threads:[~2023-06-30 5:57 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-30 5:56 Gautam Menghani [this message]
2023-07-03 6:41 ` [PATCH] arch/powerpc: Remove unnecessary endian conversion code in XICS Michael Ellerman
2023-07-06 7:50 ` Jordan Niethe
2023-07-11 9:33 ` Gautam Menghani
2023-07-26 8:07 ` Gautam Menghani
2023-07-26 9:12 ` Gautam Menghani
2023-07-29 10:54 ` Michael Ellerman
2023-07-31 12:00 ` Gautam Menghani
-- strict thread matches above, loose matches on Subject: below --
2023-06-30 6:13 Gautam Menghani
2023-06-30 6:16 ` Gautam Menghani
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230630055628.17790-1-gautam@linux.ibm.com \
--to=gautam@linux.ibm.com \
--cc=christophe.leroy@csgroup.eu \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mpe@ellerman.id.au \
--cc=npiggin@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).