> > static inline void > > vmbus_set_monitor(const struct vmbus_channel *channel, uint32_t > monitor_id) > > { > > - uint32_t *monitor_addr, monitor_mask; > > + RTE_ATOMIC(uint32_t) *monitor_addr, monitor_mask; > > unsigned int trigger_index; > > > > trigger_index = monitor_id / HV_MON_TRIG_LEN; > > monitor_mask = 1u << (monitor_id % HV_MON_TRIG_LEN); > > > > - monitor_addr = &channel->monitor_page->trigs[trigger_index].pending; > > + monitor_addr = > > + (uint32_t __rte_atomic > > +*)&channel->monitor_page->trigs[trigger_index].pending; > > Why is "pending" not RTE_ATOMIC()?
The usage is okay. The value is used to notify the VSP (Hyper-V). It's always set (no read) from DPDK. Linux kernel driver does the same thing. Long