提交 15a0fbbc 编写于 作者: D Dan Williams 提交者: Christoph Hellwig

ses: generate KOBJ_CHANGE on enclosure attach

In support of a /dev/disk/by-slot populated with data from the enclosure
and ses modules udev needs notification when the new interface
files/links are available.  Otherwise, any udev rules specified for the
disk cannot assume that the enclosure topology has settled.
Signed-off-by: NDan Williams <dan.j.williams@intel.com>
Signed-off-by: NSong Liu <songliubraving@fb.com>
Reviewed-by: NJens Axboe <axboe@fb.com>
Reviewed-by: NHannes Reinecke <hare@suse.de>
Signed-off-by: NChristoph Hellwig <hch@lst.de>
上级 ed09dcc8
......@@ -349,7 +349,8 @@ static int ses_enclosure_find_by_addr(struct enclosure_device *edev,
if (scomp->addr != efd->addr)
continue;
enclosure_add_device(edev, i, efd->dev);
if (enclosure_add_device(edev, i, efd->dev) == 0)
kobject_uevent(&efd->dev->kobj, KOBJ_CHANGE);
return 1;
}
return 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册