Commit 68bd7422 authored by Wolfram Sang's avatar Wolfram Sang Committed by David S. Miller

net/can/mscan: drop assignment in while-construct

As suggested by Wolfgang Grandegger.
Signed-off-by: default avatarWolfram Sang <w.sang@pengutronix.de>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 1712fe59
......@@ -379,8 +379,10 @@ static int mscan_rx_poll(struct napi_struct *napi, int quota)
struct can_frame *frame;
u8 canrflg;
while (npackets < quota && ((canrflg = in_8(&regs->canrflg)) &
(MSCAN_RXF | MSCAN_ERR_IF))) {
while (npackets < quota) {
canrflg = in_8(&regs->canrflg);
if (!(canrflg & (MSCAN_RXF | MSCAN_ERR_IF)))
break;
skb = alloc_can_skb(dev, &frame);
if (!skb) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment