diff options
author | Marc Kleine-Budde <mkl@pengutronix.de> | 2019-10-07 10:00:52 +0200 |
---|---|---|
committer | Marc Kleine-Budde <mkl@pengutronix.de> | 2019-11-11 21:58:10 +0100 |
commit | f1242cd981e36385169281bf7b978e2bfa942eb5 (patch) | |
tree | 2246f73ef755db82728fd88bddd95dc2ba55edde /drivers/net/can | |
parent | a7b70e2d62d86fcb3f665d325dbc6f0303ee3c51 (diff) |
can: rx-offload: can_rx_offload_irq_offload_timestamp(): don't use assignment in if condition
This patch moves the assignment of queue_len out of the if condition.
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'drivers/net/can')
-rw-r--r-- | drivers/net/can/rx-offload.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/can/rx-offload.c b/drivers/net/can/rx-offload.c index c277c5151153..412a8cec5d18 100644 --- a/drivers/net/can/rx-offload.c +++ b/drivers/net/can/rx-offload.c @@ -238,8 +238,8 @@ int can_rx_offload_irq_offload_timestamp(struct can_rx_offload *offload, skb_queue_splice_tail(&skb_queue, &offload->skb_queue); spin_unlock_irqrestore(&offload->skb_queue.lock, flags); - if ((queue_len = skb_queue_len(&offload->skb_queue)) > - (offload->skb_queue_len_max / 8)) + queue_len = skb_queue_len(&offload->skb_queue); + if (queue_len > offload->skb_queue_len_max / 8) netdev_dbg(offload->dev, "%s: queue_len=%d\n", __func__, queue_len); |