]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - drivers/net/ethernet/intel/ixgbe/ixgbe_ptp.c
locking/atomics: COCCINELLE/treewide: Convert trivial ACCESS_ONCE() patterns to READ_...
[mirror_ubuntu-bionic-kernel.git] / drivers / net / ethernet / intel / ixgbe / ixgbe_ptp.c
index 86d6924a2b714ad7535e34149078f10f31ca53dc..ae312c45696afd8b85f25d675810029c5ea126a2 100644 (file)
@@ -378,7 +378,7 @@ static int ixgbe_ptp_adjfreq_82599(struct ptp_clock_info *ptp, s32 ppb)
        }
 
        smp_mb();
-       incval = ACCESS_ONCE(adapter->base_incval);
+       incval = READ_ONCE(adapter->base_incval);
 
        freq = incval;
        freq *= ppb;
@@ -1159,7 +1159,7 @@ void ixgbe_ptp_start_cyclecounter(struct ixgbe_adapter *adapter)
        }
 
        /* update the base incval used to calculate frequency adjustment */
-       ACCESS_ONCE(adapter->base_incval) = incval;
+       WRITE_ONCE(adapter->base_incval, incval);
        smp_mb();
 
        /* need lock to prevent incorrect read while modifying cyclecounter */