Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1726485 > unrolled thread
| Started by | Vincent Legout <vincent.legout@gandi.net> |
|---|---|
| First post | 2017-09-05 09:40 +0200 |
| Last post | 2017-09-06 17:00 +0200 |
| Articles | 3 — 3 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [Xen-devel] [PATCH] xen-blkfront: emit KOBJ_OFFLINE uevent when detaching device Vincent Legout <vincent.legout@gandi.net> - 2017-09-05 09:40 +0200
Re: [Xen-devel] [PATCH] xen-blkfront: emit KOBJ_OFFLINE uevent when detaching device Juergen Gross <jgross@suse.com> - 2017-09-06 12:20 +0200
Re: [Xen-devel] [PATCH] xen-blkfront: emit KOBJ_OFFLINE uevent when detaching device Roger Pau Monné <roger.pau@citrix.com> - 2017-09-06 17:00 +0200
| From | Vincent Legout <vincent.legout@gandi.net> |
|---|---|
| Date | 2017-09-05 09:40 +0200 |
| Subject | Re: [Xen-devel] [PATCH] xen-blkfront: emit KOBJ_OFFLINE uevent when detaching device |
| Message-ID | <umgCL-8ei-23@gated-at.bofh.it> |
[Multipart message — attachments visible in raw view] — view raw
Hello, Sorry for such a long delay. I'm still interested in having this patch merged. I've tried to make the patch more generic and move it to xenbus as discussed during the Xen summit, but I'm not sure how or if it's possible. Would doing something in xenbus_otherend_changed() make sense? But do we have enough information there? I'd be happy to get any advice, I've re-attached the original patch. On Fri, Jul 07, 2017 at 09:10:53AM +0100, Roger Pau Monné wrote : > On Wed, Jul 05, 2017 at 03:30:00PM +0200, Vincent Legout wrote: > > On Wed, Jul 05, 2017 at 06:53:25AM -0600, Jan Beulich wrote : > > > >>> On 05.07.17 at 14:37, <vincent.legout@gandi.net> wrote: > > > > On Wed, Jul 05, 2017 at 02:17:24AM -0600, Jan Beulich wrote : > > > >> >>> On 05.07.17 at 10:08, <vincent.legout@gandi.net> wrote: > > > >> > Without the patch, blkif_release and xlvbd_release_gendisk are never > > > >> > called, and no call to blk_unregister_queue is made. > > > >> > > > >> But isn't that what needs to be fixed then? The device should be > > > >> removed once its last user goes away (which would be at the time > > > >> the umount is eventually done aiui). > > > > > > > > You mean that block-detach should fail if the device is still mounted? > > > > or find a way to wait until all the users are gone? > > > > > > > > I don't say that's not what should be done, but that's not what I get. > > > > The device is removed after a block-detach, even if still mounted. So > > > > the system is left in an unstable state without the patch. > > > > > > Unstable? I'd expect subsequent I/O to fail for that device, yes, but > > > that's still a stable system. Are you observing anything else? > > > > Yes, that's what I meant by unstable, nothing else. Sorry for the > > confusion. > > IMHO, this should behave in the same exact way as hot-unplugging a USB > drive that's mounted, can you confirm that's correct? I agree. And if I'm not wrong, it currently doesn't behave the same as USB device unplugging. The patch tries to fix that. Thanks, Vincent
[toc] | [next] | [standalone]
| From | Juergen Gross <jgross@suse.com> |
|---|---|
| Date | 2017-09-06 12:20 +0200 |
| Message-ID | <umFB8-hz-19@gated-at.bofh.it> |
| In reply to | #1726485 |
On 05/09/17 09:28, Vincent Legout wrote: > Hello, > > Sorry for such a long delay. I'm still interested in having this patch > merged. > > I've tried to make the patch more generic and move it to xenbus as > discussed during the Xen summit, but I'm not sure how or if it's > possible. Would doing something in xenbus_otherend_changed() make sense? > But do we have enough information there? I'd be happy to get any advice, > I've re-attached the original patch. Maybe you could add a callback to struct xenbus_driver which is called by xenbus_otherend_changed() if available and which will return the missing information (e.g. the kobj). Juergen > > On Fri, Jul 07, 2017 at 09:10:53AM +0100, Roger Pau Monné wrote : >> On Wed, Jul 05, 2017 at 03:30:00PM +0200, Vincent Legout wrote: >>> On Wed, Jul 05, 2017 at 06:53:25AM -0600, Jan Beulich wrote : >>>>>>> On 05.07.17 at 14:37, <vincent.legout@gandi.net> wrote: >>>>> On Wed, Jul 05, 2017 at 02:17:24AM -0600, Jan Beulich wrote : >>>>>>>>> On 05.07.17 at 10:08, <vincent.legout@gandi.net> wrote: >>>>>>> Without the patch, blkif_release and xlvbd_release_gendisk are never >>>>>>> called, and no call to blk_unregister_queue is made. >>>>>> >>>>>> But isn't that what needs to be fixed then? The device should be >>>>>> removed once its last user goes away (which would be at the time >>>>>> the umount is eventually done aiui). >>>>> >>>>> You mean that block-detach should fail if the device is still mounted? >>>>> or find a way to wait until all the users are gone? >>>>> >>>>> I don't say that's not what should be done, but that's not what I get. >>>>> The device is removed after a block-detach, even if still mounted. So >>>>> the system is left in an unstable state without the patch. >>>> >>>> Unstable? I'd expect subsequent I/O to fail for that device, yes, but >>>> that's still a stable system. Are you observing anything else? >>> >>> Yes, that's what I meant by unstable, nothing else. Sorry for the >>> confusion. >> >> IMHO, this should behave in the same exact way as hot-unplugging a USB >> drive that's mounted, can you confirm that's correct? > > I agree. And if I'm not wrong, it currently doesn't behave the same as > USB device unplugging. The patch tries to fix that. > > Thanks, > Vincent >
[toc] | [prev] | [next] | [standalone]
| From | Roger Pau Monné <roger.pau@citrix.com> |
|---|---|
| Date | 2017-09-06 17:00 +0200 |
| Message-ID | <umJY7-3cf-23@gated-at.bofh.it> |
| In reply to | #1727316 |
On Wed, Sep 06, 2017 at 12:18:03PM +0200, Juergen Gross wrote: > On 05/09/17 09:28, Vincent Legout wrote: > > Hello, > > > > Sorry for such a long delay. I'm still interested in having this patch > > merged. > > > > I've tried to make the patch more generic and move it to xenbus as > > discussed during the Xen summit, but I'm not sure how or if it's > > possible. Would doing something in xenbus_otherend_changed() make sense? > > But do we have enough information there? I'd be happy to get any advice, > > I've re-attached the original patch. > > Maybe you could add a callback to struct xenbus_driver which is called > by xenbus_otherend_changed() if available and which will return the > missing information (e.g. the kobj). Hello, I'm still unsure we should call KOBJ_OFFLINE, mostly because I don't see any other block devices doing so. AFAICT it seems to be used only by cpu and memory hotplug. Maybe xenbus should use the device_offline function instead on each device it wants to remove? From my limited Linux bus handling understanding, this seems to be more in line with what ACPI does for example. Thanks, Roger.
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web