wimax/i2400m: remove unlikely() from WARN*() condition
authorDenis Efremov <efremov@linux.com>
Wed, 25 Sep 2019 23:49:34 +0000 (16:49 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 26 Sep 2019 17:10:30 +0000 (10:10 -0700)
"unlikely(WARN_ON(x))" is excessive. WARN_ON() already uses unlikely()
internally.

Link: http://lkml.kernel.org/r/20190829165025.15750-6-efremov@linux.com
Signed-off-by: Denis Efremov <efremov@linux.com>
Cc: Inaky Perez-Gonzalez <inaky.perez-gonzalez@intel.com>
Cc: Joe Perches <joe@perches.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/net/wimax/i2400m/tx.c

index ebd64e0837264bb9636bed91f58e6809edbaad47..1255302e251e40911d16fdbccf999c333c0b39b3 100644 (file)
@@ -654,8 +654,7 @@ void i2400m_tx_close(struct i2400m *i2400m)
        padding = aligned_size - tx_msg_moved->size;
        if (padding > 0) {
                pad_buf = i2400m_tx_fifo_push(i2400m, padding, 0, 0);
-               if (unlikely(WARN_ON(pad_buf == NULL
-                                    || pad_buf == TAIL_FULL))) {
+               if (WARN_ON(pad_buf == NULL || pad_buf == TAIL_FULL)) {
                        /* This should not happen -- append should verify
                         * there is always space left at least to append
                         * tx_block_size */