]> git.baikalelectronics.ru Git - kernel.git/commitdiff
net: wan: add braces {} to all arms of the statement
authorPeng Li <lipeng321@huawei.com>
Mon, 24 May 2021 14:47:17 +0000 (22:47 +0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 24 May 2021 21:07:39 +0000 (14:07 -0700)
Braces {} should be used on all arms of this statement.

Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/wan/wanxl.c

index 18de5f1bb0ed8eae5ba0cf866f1cdd56407b1b4f..f22e48415e6f46c771e894685f1f8619f62ac612 100644 (file)
@@ -210,18 +210,18 @@ static inline void wanxl_rx_intr(struct card *card)
 
        while (desc = &card->status->rx_descs[card->rx_in],
               desc->stat != PACKET_EMPTY) {
-               if ((desc->stat & PACKET_PORT_MASK) > card->n_ports)
+               if ((desc->stat & PACKET_PORT_MASK) > card->n_ports) {
                        pr_crit("%s: received packet for nonexistent port\n",
                                pci_name(card->pdev));
-               else {
+               else {
                        struct sk_buff *skb = card->rx_skbs[card->rx_in];
                        struct port *port = &card->ports[desc->stat &
                                                    PACKET_PORT_MASK];
                        struct net_device *dev = port->dev;
 
-                       if (!skb)
+                       if (!skb) {
                                dev->stats.rx_dropped++;
-                       else {
+                       else {
                                dma_unmap_single(&card->pdev->dev,
                                                 desc->address, BUFFER_LENGTH,
                                                 DMA_FROM_DEVICE);