On Jan 7, 2013, at 3:11 AM, Isaku Yamahata <yamah...@valinux.co.jp> wrote:
>> + if (++dpif->event_offset >= dpif->n_events) { >> + dpif->event_offset = dpif->n_events = 0; >> + } > > dpfi->event_offset isn't initialized as zero. Perhaps I missed a spot, but I didn't see any issues. The dpif structure is initialized to zero in open_dpif() and it is reset to 0 when dpif_linux_recv_set() is called with "enable" set to false. Is there a way to get there with an uninitialized or invalid value that I missed? > And dpif->event_offset is used only in dpif_linux_recv(), so it can be local > variable, and dpif::event_offset can be removed. Even though a single datapath is used in the code, it's still structured in such a way that datapath logic is kept in a "dpif_linux" struct. We've talked about restructuring all that ofproto logic in light of all the changes that have gone in recently, and I think it would make more sense to do it then. However, let me know if I'm missing something. Thanks for the feedback. --Justin _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev