Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

serial: 8250_pci: remove redundant assignment to tmp after the mask operation

The variable tmp is being masked with a bitmask and the value is being
written to port base + 0x3c. However, the masked value is being written
back to tmp and tmp is never used after this. The assignmentment is
redundant, replace the &= operator with just &.

Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Reviewesd-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20211205232822.110099-1-colin.i.king@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Colin Ian King and committed by
Greg Kroah-Hartman
4b95391c e5ce127e

+1 -1
+1 -1
drivers/tty/serial/8250/8250_pci.c
··· 1278 1278 outl(inl(base + 0x38) | 0x00002000, base + 0x38); 1279 1279 tmp = inl(base + 0x3c); 1280 1280 outl(tmp | 0x01000000, base + 0x3c); 1281 - outl(tmp &= ~0x01000000, base + 0x3c); 1281 + outl(tmp & ~0x01000000, base + 0x3c); 1282 1282 } 1283 1283 } 1284 1284 return 0;