aboutsummaryrefslogtreecommitdiffstats
path: root/samples
diff options
context:
space:
mode:
Diffstat (limited to 'samples')
-rw-r--r--samples/mic/mpssd/mpssd.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/samples/mic/mpssd/mpssd.c b/samples/mic/mpssd/mpssd.c
index 49db1def1721..f42ce551bb48 100644
--- a/samples/mic/mpssd/mpssd.c
+++ b/samples/mic/mpssd/mpssd.c
@@ -65,7 +65,7 @@ static struct mic_info mic_list;
65/* to align the pointer to the (next) page boundary */ 65/* to align the pointer to the (next) page boundary */
66#define PAGE_ALIGN(addr) _ALIGN(addr, PAGE_SIZE) 66#define PAGE_ALIGN(addr) _ALIGN(addr, PAGE_SIZE)
67 67
68#define ACCESS_ONCE(x) (*(volatile typeof(x) *)&(x)) 68#define READ_ONCE(x) (*(volatile typeof(x) *)&(x))
69 69
70#define GSO_ENABLED 1 70#define GSO_ENABLED 1
71#define MAX_GSO_SIZE (64 * 1024) 71#define MAX_GSO_SIZE (64 * 1024)
@@ -382,7 +382,7 @@ disp_iovec(struct mic_info *mic, struct mic_copy_desc *copy,
382 382
383static inline __u16 read_avail_idx(struct mic_vring *vr) 383static inline __u16 read_avail_idx(struct mic_vring *vr)
384{ 384{
385 return ACCESS_ONCE(vr->info->avail_idx); 385 return READ_ONCE(vr->info->avail_idx);
386} 386}
387 387
388static inline void txrx_prepare(int type, bool tx, struct mic_vring *vr, 388static inline void txrx_prepare(int type, bool tx, struct mic_vring *vr,
@@ -523,7 +523,7 @@ spin_for_descriptors(struct mic_info *mic, struct mic_vring *vr)
523{ 523{
524 __u16 avail_idx = read_avail_idx(vr); 524 __u16 avail_idx = read_avail_idx(vr);
525 525
526 while (avail_idx == le16toh(ACCESS_ONCE(vr->vr.avail->idx))) { 526 while (avail_idx == le16toh(READ_ONCE(vr->vr.avail->idx))) {
527#ifdef DEBUG 527#ifdef DEBUG
528 mpsslog("%s %s waiting for desc avail %d info_avail %d\n", 528 mpsslog("%s %s waiting for desc avail %d info_avail %d\n",
529 mic->name, __func__, 529 mic->name, __func__,