summaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorJames Bottomley <James.Bottomley@HansenPartnership.com>2009-08-01 00:43:59 +0000
committerJames Bottomley <James.Bottomley@suse.de>2009-08-22 17:52:14 -0500
commit21fab1d0595eacf781705ec3509012a28f298245 (patch)
tree825d307407b1705d79dc72f5e50a1bd339f7e356 /drivers/misc
parent43d8eb9cfd0aea93be32181c64e18191b69c211c (diff)
downloadop-kernel-dev-21fab1d0595eacf781705ec3509012a28f298245.zip
op-kernel-dev-21fab1d0595eacf781705ec3509012a28f298245.tar.gz
[SCSI] ses: update enclosure data on hot add
Now that hot add works correctly, if a new device is added, we're still operating on stale enclosure data, so fix that by updating the enclosure diagnostic pages when we get notified of a device hot add Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/enclosure.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/misc/enclosure.c b/drivers/misc/enclosure.c
index 850706a..7b03930 100644
--- a/drivers/misc/enclosure.c
+++ b/drivers/misc/enclosure.c
@@ -315,6 +315,9 @@ int enclosure_add_device(struct enclosure_device *edev, int component,
cdev = &edev->component[component];
+ if (cdev->dev == dev)
+ return -EEXIST;
+
if (cdev->dev)
enclosure_remove_links(cdev);
OpenPOWER on IntegriCloud