RE: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-31 Thread Dexuan Cui
> From: Michael Kelley (EOSG) > Sent: Thursday, May 31, 2018 09:41 > > > > IMO we can disable the per-channel tasklet to exclude the race: > > This way, when we exit the loop, we're sure hv_pci_onchannelcallback() can > > not run anymore. What do you think of this? > > I've stared at this and the

RE: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-31 Thread Michael Kelley (EOSG)
> From: Dexuan Cui > Sent: Tuesday, May 29, 2018 12:58 PM > Subject: RE: [PATCH] PCI: hv: Do not wait forever on a device that has > disappeared > > > From: Michael Kelley (EOSG) > > Sent: Monday, May 28, 2018 17:19 > > > > While this patch solves the im

RE: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-29 Thread Dexuan Cui
> From: Andy Shevchenko > Sent: Tuesday, May 29, 2018 14:21 > On Thu, May 24, 2018 at 12:12 AM, Dexuan Cui > wrote: > > > > Before the guest finishes the device initialization, the device can be > > removed anytime by the host, and after that the host won't respond to > > the guest's request, so

Re: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-29 Thread Andy Shevchenko
On Thu, May 24, 2018 at 12:12 AM, Dexuan Cui wrote: > > Before the guest finishes the device initialization, the device can be > removed anytime by the host, and after that the host won't respond to > the guest's request, so the guest should be prepared to handle this > case. > + while (tru

RE: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-29 Thread Dexuan Cui
> From: Michael Kelley (EOSG) > Sent: Monday, May 28, 2018 17:19 > > While this patch solves the immediate problem of getting hung waiting > for a response from Hyper-V that will never come, there's another scenario > to look at that I think introduces a race. Suppose the guest VM issues a > vmbu

RE: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-28 Thread Michael Kelley (EOSG)
> > Before the guest finishes the device initialization, the device can be > removed anytime by the host, and after that the host won't respond to > the guest's request, so the guest should be prepared to handle this > case. > > Signed-off-by: Dexuan Cui > Cc: Stephen Hemminger > Cc: K. Y. Srin

Re: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-25 Thread Lorenzo Pieralisi
On Wed, May 23, 2018 at 09:12:01PM +, Dexuan Cui wrote: > > Before the guest finishes the device initialization, the device can be > removed anytime by the host, and after that the host won't respond to > the guest's request, so the guest should be prepared to handle this > case. > > Signed-o

RE: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-25 Thread Haiyang Zhang
pfle.de' ; > 'a...@canonical.com' ; 'jasow...@redhat.com' > > Cc: 'linux-ker...@vger.kernel.org' ; 'driverdev- > de...@linuxdriverproject.org' ; > Haiyang Zhang ; 'vkuzn...@redhat.com' > ; 'marcelo.ce...@canonical

Re: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-25 Thread Lorenzo Pieralisi
On Thu, May 24, 2018 at 11:55:35PM +, Dexuan Cui wrote: > > From: Lorenzo Pieralisi > > Sent: Thursday, May 24, 2018 05:41 > > On Wed, May 23, 2018 at 09:12:01PM +, Dexuan Cui wrote: > > > > > > Before the guest finishes the device initialization, the device can be > > > removed anytime by

RE: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-24 Thread Dexuan Cui
> From: Lorenzo Pieralisi > Sent: Thursday, May 24, 2018 05:41 > On Wed, May 23, 2018 at 09:12:01PM +, Dexuan Cui wrote: > > > > Before the guest finishes the device initialization, the device can be > > removed anytime by the host, and after that the host won't respond to > > the guest's requ

Re: [PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-24 Thread Lorenzo Pieralisi
On Wed, May 23, 2018 at 09:12:01PM +, Dexuan Cui wrote: > > Before the guest finishes the device initialization, the device can be > removed anytime by the host, and after that the host won't respond to > the guest's request, so the guest should be prepared to handle this > case. > > Signed-o

[PATCH] PCI: hv: Do not wait forever on a device that has disappeared

2018-05-23 Thread Dexuan Cui
Before the guest finishes the device initialization, the device can be removed anytime by the host, and after that the host won't respond to the guest's request, so the guest should be prepared to handle this case. Signed-off-by: Dexuan Cui Cc: Stephen Hemminger Cc: K. Y. Srinivasan --- drive