aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Wilcox <matthew.r.wilcox@intel.com>2011-02-01 12:49:38 -0500
committerMatthew Wilcox <matthew.r.wilcox@intel.com>2011-11-04 15:52:54 -0400
commit388f037f4e7f0a24bac6b1a24f144f5d939f58cf (patch)
treed51387afa2ad24644943a3a6add9b657e6698a77
parent5911f20039ce59d7e7834f0c42151cf759b6f786 (diff)
NVMe: Move sysfs entries to the right place
Because I wasn't setting driverfs_dev, the devices were showing up under /sys/devices/virtual/block. Now they appear underneath the PCI device which they belong to. Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
-rw-r--r--drivers/block/nvme.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/block/nvme.c b/drivers/block/nvme.c
index e3d921577b9..744db3877c4 100644
--- a/drivers/block/nvme.c
+++ b/drivers/block/nvme.c
@@ -889,6 +889,7 @@ static struct nvme_ns *nvme_alloc_ns(struct nvme_dev *dev, int index,
889 disk->fops = &nvme_fops; 889 disk->fops = &nvme_fops;
890 disk->private_data = ns; 890 disk->private_data = ns;
891 disk->queue = ns->queue; 891 disk->queue = ns->queue;
892 disk->driverfs_dev = &dev->pci_dev->dev;
892 sprintf(disk->disk_name, "nvme%dn%d", dev->instance, index); 893 sprintf(disk->disk_name, "nvme%dn%d", dev->instance, index);
893 set_capacity(disk, le64_to_cpup(&id->nsze) << (ns->lba_shift - 9)); 894 set_capacity(disk, le64_to_cpup(&id->nsze) << (ns->lba_shift - 9));
894 895