Re: [ovs-dev] [PATCH 1/3] netdev-dummy: add appctl netdev-dummy/conn-state command

2014-06-09 Thread Andy Zhou
On Sun, Jun 8, 2014 at 1:32 PM, Jarno Rajahalme wrote: > > > Sent from my iPhone > > On Jun 8, 2014, at 12:32 AM, Andy Zhou wrote: > >>> What needs locking here? Could the locking be moved closer into the new >>> function? >> >> >> The conn member is declared with OVS_GUARDED in netdev_dummy. T

Re: [ovs-dev] [PATCH 1/3] netdev-dummy: add appctl netdev-dummy/conn-state command

2014-06-08 Thread Jarno Rajahalme
Sent from my iPhone On Jun 8, 2014, at 12:32 AM, Andy Zhou wrote: >> What needs locking here? Could the locking be moved closer into the new >> function? > > > The conn member is declared with OVS_GUARDED in netdev_dummy. This is > to make sure > the mutex is held before accessing conn. A

Re: [ovs-dev] [PATCH 1/3] netdev-dummy: add appctl netdev-dummy/conn-state command

2014-06-08 Thread Andy Zhou
> > "connected" Thanks, will fix. > >> +CONN_STATE_UNKNOWN,/* No relavent information. */ >> +}; >> + >> struct dummy_packet_pconn { >> struct pstream *pstream; >> struct dummy_packet_stream *streams; >> @@ -561,6 +568,24 @@ dummy_packet_conn_send(struct dummy_packet_conn *conn

Re: [ovs-dev] [PATCH 1/3] netdev-dummy: add appctl netdev-dummy/conn-state command

2014-06-06 Thread Jarno Rajahalme
See comments below, Jarno > On Jun 6, 2014, at 4:34 PM, Andy Zhou wrote: > > Using without any parameter, this command list the connection > state of all netdev-dummy devices that are configured as passive > listeners. > > Optionally, the name of the netdev-dummy device can be supplied > as

[ovs-dev] [PATCH 1/3] netdev-dummy: add appctl netdev-dummy/conn-state command

2014-06-06 Thread Andy Zhou
Using without any parameter, this command list the connection state of all netdev-dummy devices that are configured as passive listeners. Optionally, the name of the netdev-dummy device can be supplied as a parameter. The states will be displayed as: "connected": The listening socket has been co