locking/atomics: COCCINELLE/treewide: Convert trivial ACCESS_ONCE() patterns to READ_...
[sfrench/cifs-2.6.git] / drivers / net / ethernet / hisilicon / hip04_eth.c
index 0cec06bec63ee1c0085019f0f1ee456b675c2ece..340e28211135a266b5a955ef432f6e8786d4f23b 100644 (file)
@@ -373,7 +373,7 @@ static int hip04_tx_reclaim(struct net_device *ndev, bool force)
        unsigned int count;
 
        smp_rmb();
-       count = tx_count(ACCESS_ONCE(priv->tx_head), tx_tail);
+       count = tx_count(READ_ONCE(priv->tx_head), tx_tail);
        if (count == 0)
                goto out;
 
@@ -431,7 +431,7 @@ static int hip04_mac_start_xmit(struct sk_buff *skb, struct net_device *ndev)
        dma_addr_t phys;
 
        smp_rmb();
-       count = tx_count(tx_head, ACCESS_ONCE(priv->tx_tail));
+       count = tx_count(tx_head, READ_ONCE(priv->tx_tail));
        if (count == (TX_DESC_NUM - 1)) {
                netif_stop_queue(ndev);
                return NETDEV_TX_BUSY;