Re: [Xen-devel] [PATCH for-4.6 1/2] libxl: fix devd removal path

2015-09-23 Thread Ian Campbell
On Wed, 2015-09-23 at 11:36 +0200, Roger Pau Monné wrote: > El 23/09/15 a les 10.46, Ian Campbell ha escrit: > > On Tue, 2015-09-22 at 18:23 +0200, Roger Pau Monne wrote: > > > > > > -/* Check if event_path ends with "state" and truncate it */ > > > -if (strlen(event_path) <

Re: [Xen-devel] [PATCH for-4.6 1/2] libxl: fix devd removal path

2015-09-23 Thread Ian Campbell
On Tue, 2015-09-22 at 18:23 +0200, Roger Pau Monne wrote: > > -/* Check if event_path ends with "state" and truncate it */ > -if (strlen(event_path) < strlen("state")) > +/* Check if event_path ends with "state" or "online" and truncate it. */ > +if (strlen(event_path) <

Re: [Xen-devel] [PATCH for-4.6 1/2] libxl: fix devd removal path

2015-09-23 Thread Roger Pau Monné
El 23/09/15 a les 10.46, Ian Campbell ha escrit: > On Tue, 2015-09-22 at 18:23 +0200, Roger Pau Monne wrote: >> >> -/* Check if event_path ends with "state" and truncate it */ >> -if (strlen(event_path) < strlen("state")) >> +/* Check if event_path ends with "state" or "online" and

[Xen-devel] [PATCH for-4.6 1/2] libxl: fix devd removal path

2015-09-22 Thread Roger Pau Monne
The current flow of the devd helper (in charge of launching hotplug scripts inside of driver domains) is to wait for the device backend to switch to state 6 (XenbusStateClosed) and then remove it. This is not correct, since a domain can reconnect it's PV devices as many times as it wants. In

Re: [Xen-devel] [PATCH for-4.6 1/2] libxl: fix devd removal path

2015-09-22 Thread Ian Jackson
Roger Pau Monne writes ("[PATCH for-4.6 1/2] libxl: fix devd removal path"): > The current flow of the devd helper (in charge of launching hotplug scripts > inside of driver domains) is to wait for the device backend to switch to > state 6 (XenbusStateClosed) and then remove it. This is not