* [PATCH][next] tty: jsm: Remove redundant assignment to variable linestatus
@ 2024-02-16 12:17 Colin Ian King
0 siblings, 0 replies; only message in thread
From: Colin Ian King @ 2024-02-16 12:17 UTC (permalink / raw)
To: Greg Kroah-Hartman, Jiri Slaby, linux-serial
Cc: kernel-janitors, linux-kernel
The variable linestate being assigned a value that is never read, the
following continue statement jumps to the end of the while-loop and then
it is re-assigned a new value. The assignment is redundant and can be
removed.
Cleans up clang scan build warning:
drivers/tty/serial/jsm/jsm_cls.c:398:4: warning: Value stored
to 'linestatus' is never read [deadcode.DeadStores]
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
---
drivers/tty/serial/jsm/jsm_cls.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/tty/serial/jsm/jsm_cls.c b/drivers/tty/serial/jsm/jsm_cls.c
index 1eda48964c0b..ddbd42c09637 100644
--- a/drivers/tty/serial/jsm/jsm_cls.c
+++ b/drivers/tty/serial/jsm/jsm_cls.c
@@ -395,7 +395,6 @@ static void cls_copy_data_from_uart_to_queue(struct jsm_channel *ch)
* which in this case is the break signal.
*/
if (linestatus & error_mask) {
- linestatus = 0;
readb(&ch->ch_cls_uart->txrx);
continue;
}
--
2.39.2
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-02-16 12:17 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-02-16 12:17 [PATCH][next] tty: jsm: Remove redundant assignment to variable linestatus Colin Ian King
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®