Re: [PATCH] virtio-blk: Generate uevent after attribute available

2016-09-03 Thread Fam Zheng
On Sat, 09/03 01:56, Michael S. Tsirkin wrote: > On Wed, Jun 29, 2016 at 09:24:15AM +0800, Fam Zheng wrote: > > On Tue, 06/28 04:45, Christoph Hellwig wrote: > > > On Tue, Jun 28, 2016 at 10:39:15AM +0800, Fam Zheng wrote: > > > > Userspace listens to the KOBJ_ADD uevent generated in add_disk. At t

Re: [PATCH] virtio-blk: Generate uevent after attribute available

2016-09-02 Thread Michael S. Tsirkin
On Wed, Jun 29, 2016 at 09:24:15AM +0800, Fam Zheng wrote: > On Tue, 06/28 04:45, Christoph Hellwig wrote: > > On Tue, Jun 28, 2016 at 10:39:15AM +0800, Fam Zheng wrote: > > > Userspace listens to the KOBJ_ADD uevent generated in add_disk. At that > > > point we haven't created the serial attribute

Re: [PATCH] virtio-blk: Generate uevent after attribute available

2016-06-28 Thread Fam Zheng
On Tue, 06/28 04:45, Christoph Hellwig wrote: > On Tue, Jun 28, 2016 at 10:39:15AM +0800, Fam Zheng wrote: > > Userspace listens to the KOBJ_ADD uevent generated in add_disk. At that > > point we haven't created the serial attribute file, therefore depending > > on how fast udev reacts, the /dev/di

Re: [PATCH] virtio-blk: Generate uevent after attribute available

2016-06-28 Thread Christoph Hellwig
On Tue, Jun 28, 2016 at 10:39:15AM +0800, Fam Zheng wrote: > Userspace listens to the KOBJ_ADD uevent generated in add_disk. At that > point we haven't created the serial attribute file, therefore depending > on how fast udev reacts, the /dev/disk/by-id/ entry doesn't always get > created. > > Thi

[PATCH] virtio-blk: Generate uevent after attribute available

2016-06-27 Thread Fam Zheng
Userspace listens to the KOBJ_ADD uevent generated in add_disk. At that point we haven't created the serial attribute file, therefore depending on how fast udev reacts, the /dev/disk/by-id/ entry doesn't always get created. This race condition can be easily reproduced by hot plugging a number of v