This patch refactors tail bump check.
Change-ID: Ide0e19171d67d90cb2b06b8dcd4fa791ae120160
Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
                                                  I40E_TXD_QW1_CMD_SHIFT);
 
        /* notify HW of packet */
-       if (!tail_bump)
+       if (!tail_bump) {
                prefetchw(tx_desc + 1);
-
-       if (tail_bump) {
+       } else {
                /* Force memory writes to complete before letting h/w
                 * know there are new descriptors to fetch.  (Only
                 * applicable for weak-ordered memory model archs,
                wmb();
                writel(i, tx_ring->tail);
        }
-
        return;
 
 dma_error:
 
                                                  I40E_TXD_QW1_CMD_SHIFT);
 
        /* notify HW of packet */
-       if (!tail_bump)
+       if (!tail_bump) {
                prefetchw(tx_desc + 1);
-
-       if (tail_bump) {
+       } else {
                /* Force memory writes to complete before letting h/w
                 * know there are new descriptors to fetch.  (Only
                 * applicable for weak-ordered memory model archs,
                wmb();
                writel(i, tx_ring->tail);
        }
-
        return;
 
 dma_error: