search for: disk_nam

Displaying 20 results from an estimated 194 matches for "disk_nam".

Did you mean: disk_name
2012 Apr 10
3
[PATCH] virtio_blk: Add help function to format mass of disks
...ix, strlen(prefix)); + + return 0; +} + static int __devinit virtblk_probe(struct virtio_device *vdev) { struct virtio_blk *vblk; @@ -442,18 +467,7 @@ static int __devinit virtblk_probe(struct virtio_device *vdev) q->queuedata = vblk; - if (index < 26) { - sprintf(vblk->disk->disk_name, "vd%c", 'a' + index % 26); - } else if (index < (26 + 1) * 26) { - sprintf(vblk->disk->disk_name, "vd%c%c", - 'a' + index / 26 - 1, 'a' + index % 26); - } else { - const unsigned int m1 = (index / 26 - 1) / 26 - 1; - const unsigned int m2...
2012 Apr 10
3
[PATCH] virtio_blk: Add help function to format mass of disks
...ix, strlen(prefix)); + + return 0; +} + static int __devinit virtblk_probe(struct virtio_device *vdev) { struct virtio_blk *vblk; @@ -442,18 +467,7 @@ static int __devinit virtblk_probe(struct virtio_device *vdev) q->queuedata = vblk; - if (index < 26) { - sprintf(vblk->disk->disk_name, "vd%c", 'a' + index % 26); - } else if (index < (26 + 1) * 26) { - sprintf(vblk->disk->disk_name, "vd%c%c", - 'a' + index / 26 - 1, 'a' + index % 26); - } else { - const unsigned int m1 = (index / 26 - 1) / 26 - 1; - const unsigned int m2...
2019 May 10
2
[PATCH v8 3/6] libnvdimm: add dax_dev sync flag
...insertions(+), 6 deletions(-) [..] > diff --git a/drivers/md/dm.c b/drivers/md/dm.c > index 043f0761e4a0..ee007b75d9fd 100644 > --- a/drivers/md/dm.c > +++ b/drivers/md/dm.c > @@ -1969,7 +1969,8 @@ static struct mapped_device *alloc_dev(int minor) > sprintf(md->disk->disk_name, "dm-%d", minor); > > if (IS_ENABLED(CONFIG_DAX_DRIVER)) { > - dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops); > + dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops, > +...
2019 May 10
2
[PATCH v8 3/6] libnvdimm: add dax_dev sync flag
...insertions(+), 6 deletions(-) [..] > diff --git a/drivers/md/dm.c b/drivers/md/dm.c > index 043f0761e4a0..ee007b75d9fd 100644 > --- a/drivers/md/dm.c > +++ b/drivers/md/dm.c > @@ -1969,7 +1969,8 @@ static struct mapped_device *alloc_dev(int minor) > sprintf(md->disk->disk_name, "dm-%d", minor); > > if (IS_ENABLED(CONFIG_DAX_DRIVER)) { > - dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops); > + dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops, > +...
2008 Mar 20
1
How to get device name with device id?
Hi all, I want to open a device(/dev/sda1, /dev/hda2 etc) in which my file exists. I've used 'stat' system call to get the device id. But now I want the device name from this id(st_dev). How to get that one? Or Do you have any other method to know the device name where my file resides? Thanks Bollywood, fun, friendship, sports and more. You name it, we have it on
2012 Mar 30
10
[PATCH 0/4] block: move sd_format_disk_name() into block core as disk_name_format()
This patch series renames "sd_format_disk_name()" to "disk_name_format()" and moves it into block core. So that who needs formatting disk name can use it, instead of duplicating these similar help functions. Ren Mingxin (4): block: add function disk_name_format() into block core scsi: replace sd_format_disk_name() to disk...
2012 Mar 30
10
[PATCH 0/4] block: move sd_format_disk_name() into block core as disk_name_format()
This patch series renames "sd_format_disk_name()" to "disk_name_format()" and moves it into block core. So that who needs formatting disk name can use it, instead of duplicating these similar help functions. Ren Mingxin (4): block: add function disk_name_format() into block core scsi: replace sd_format_disk_name() to disk...
2019 May 11
2
[PATCH v8 3/6] libnvdimm: add dax_dev sync flag
...a/drivers/md/dm.c b/drivers/md/dm.c > > > index 043f0761e4a0..ee007b75d9fd 100644 > > > --- a/drivers/md/dm.c > > > +++ b/drivers/md/dm.c > > > @@ -1969,7 +1969,8 @@ static struct mapped_device *alloc_dev(int minor) > > > sprintf(md->disk->disk_name, "dm-%d", minor); > > > > > > if (IS_ENABLED(CONFIG_DAX_DRIVER)) { > > > - dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops); > > > + dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_o...
2014 Jan 29
2
Status of R/W UFS
...39;guestmount' still an impossibility? From everything I've found, it seems to be something that is not possible at the moment. I was just wondering if that has changed or if there are plans to change that? Here is the issue I'm experiencing: ~# guestmount --rw -a ${disk_path}/${disk_name} -m /dev/sda4 /tmp/freebsd-master libguestfs: error: mount_options: /dev/vda4 on /: mount: wrong fs type, bad option, bad superblock on /dev/vda4, missing codepage or helper program, or other error In some cases useful info is found in syslog - try dmesg | tail or so gue...
2012 Apr 11
0
[PATCH v2] virtio_blk: Add help function to format mass of disks
...ix, strlen(prefix)); + + return 0; +} + static int __devinit virtblk_probe(struct virtio_device *vdev) { struct virtio_blk *vblk; @@ -442,18 +466,7 @@ static int __devinit virtblk_probe(struct virtio_device *vdev) q->queuedata = vblk; - if (index < 26) { - sprintf(vblk->disk->disk_name, "vd%c", 'a' + index % 26); - } else if (index < (26 + 1) * 26) { - sprintf(vblk->disk->disk_name, "vd%c%c", - 'a' + index / 26 - 1, 'a' + index % 26); - } else { - const unsigned int m1 = (index / 26 - 1) / 26 - 1; - const unsigned int m2...
2012 Apr 11
0
[PATCH v2] virtio_blk: Add help function to format mass of disks
...ix, strlen(prefix)); + + return 0; +} + static int __devinit virtblk_probe(struct virtio_device *vdev) { struct virtio_blk *vblk; @@ -442,18 +466,7 @@ static int __devinit virtblk_probe(struct virtio_device *vdev) q->queuedata = vblk; - if (index < 26) { - sprintf(vblk->disk->disk_name, "vd%c", 'a' + index % 26); - } else if (index < (26 + 1) * 26) { - sprintf(vblk->disk->disk_name, "vd%c%c", - 'a' + index / 26 - 1, 'a' + index % 26); - } else { - const unsigned int m1 = (index / 26 - 1) / 26 - 1; - const unsigned int m2...
2019 Apr 10
0
[PATCH v5 3/6] libnvdimm: add dax_dev sync flag
...DAXDEV_SYNC, &dax_dev->flags); + return dax_dev; err_dev: diff --git a/drivers/md/dm.c b/drivers/md/dm.c index 68d24056d0b1..534e12ca6329 100644 --- a/drivers/md/dm.c +++ b/drivers/md/dm.c @@ -1965,7 +1965,7 @@ static struct mapped_device *alloc_dev(int minor) sprintf(md->disk->disk_name, "dm-%d", minor); if (IS_ENABLED(CONFIG_DAX_DRIVER)) { - dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops); + dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops, true); if (!dax_dev) goto bad; } diff --git a/drivers/nvdimm/pmem.c b/drivers...
2019 Apr 26
0
[PATCH v7 3/6] libnvdimm: add dax_dev sync flag
...DAXDEV_SYNC, &dax_dev->flags); + return dax_dev; err_dev: diff --git a/drivers/md/dm.c b/drivers/md/dm.c index 68d24056d0b1..dd5266fb5471 100644 --- a/drivers/md/dm.c +++ b/drivers/md/dm.c @@ -1965,7 +1965,8 @@ static struct mapped_device *alloc_dev(int minor) sprintf(md->disk->disk_name, "dm-%d", minor); if (IS_ENABLED(CONFIG_DAX_DRIVER)) { - dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops); + dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops, + DAXDEV_F_SYNC); if (!dax_dev) goto bad; } diff --git a/drivers/nvdimm...
2014 Mar 15
1
[PATCH] virtio-blk: make the queue depth the max supportable by the hypervisor
...t; } > >+ virtio_mq_reg.queue_depth = queue_depth > 0 ? queue_depth : >+ (vblk->vq->num_free / 2); > virtio_mq_reg.cmd_size = > sizeof(struct virtblk_req) + > sizeof(struct scatterlist) * sg_elems; >+ virtblk_name_format("vd", index, vblk->disk->disk_name, >DISK_NAME_LEN); >+ pr_info("%s: using queue depth %d\n", vblk->disk->disk_name, >+ virtio_mq_reg.queue_depth); Isn't that visible from sysfs? > > q = vblk->disk->queue = blk_mq_init_queue(&virtio_mq_reg, vblk); > if (!q) { >@@ -565,8 +573,6...
2014 Mar 15
1
[PATCH] virtio-blk: make the queue depth the max supportable by the hypervisor
...t; } > >+ virtio_mq_reg.queue_depth = queue_depth > 0 ? queue_depth : >+ (vblk->vq->num_free / 2); > virtio_mq_reg.cmd_size = > sizeof(struct virtblk_req) + > sizeof(struct scatterlist) * sg_elems; >+ virtblk_name_format("vd", index, vblk->disk->disk_name, >DISK_NAME_LEN); >+ pr_info("%s: using queue depth %d\n", vblk->disk->disk_name, >+ virtio_mq_reg.queue_depth); Isn't that visible from sysfs? > > q = vblk->disk->queue = blk_mq_init_queue(&virtio_mq_reg, vblk); > if (!q) { >@@ -565,8 +573,6...
2019 May 10
0
[PATCH v8 3/6] libnvdimm: add dax_dev sync flag
...DAXDEV_SYNC, &dax_dev->flags); + return dax_dev; err_dev: diff --git a/drivers/md/dm.c b/drivers/md/dm.c index 043f0761e4a0..ee007b75d9fd 100644 --- a/drivers/md/dm.c +++ b/drivers/md/dm.c @@ -1969,7 +1969,8 @@ static struct mapped_device *alloc_dev(int minor) sprintf(md->disk->disk_name, "dm-%d", minor); if (IS_ENABLED(CONFIG_DAX_DRIVER)) { - dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops); + dax_dev = alloc_dax(md, md->disk->disk_name, &dm_dax_ops, + DAXDEV_F_SYNC); if (!dax_dev) goto bad; } diff --git a/drivers/nvdim...
2014 Mar 14
4
[PATCH] virtio-blk: Initialize blkqueue depth from virtqueue size
virtio-blk set the default queue depth to 64 requests, which was insufficient for high-IOPS devices. Instead set the blk-queue depth to the device's virtqueue depth divided by two (each I/O requires at least two VQ entries). Signed-off-by: Venkatesh Srinivas <venkateshs at google.com> --- drivers/block/virtio_blk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git
2014 Mar 14
4
[PATCH] virtio-blk: Initialize blkqueue depth from virtqueue size
virtio-blk set the default queue depth to 64 requests, which was insufficient for high-IOPS devices. Instead set the blk-queue depth to the device's virtqueue depth divided by two (each I/O requires at least two VQ entries). Signed-off-by: Venkatesh Srinivas <venkateshs at google.com> --- drivers/block/virtio_blk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git
2016 Aug 17
0
[PATCH 15/15] block: Add FIXME comment to handle device_add_disk error
...b/arch/xtensa/platforms/iss/simdisk.c index 6a3d8c3..b9a1a37 100644 --- a/arch/xtensa/platforms/iss/simdisk.c +++ b/arch/xtensa/platforms/iss/simdisk.c @@ -288,6 +288,7 @@ static int __init simdisk_setup(struct simdisk *dev, int which, dev->gd->private_data = dev; snprintf(dev->gd->disk_name, 32, "simdisk%d", which); set_capacity(dev->gd, 0); + /* FIXME: handle error. */ device_add_disk(NULL, dev->gd, NULL); dev->procfile = proc_create_data(tmp, 0644, procdir, &fops, dev); diff --git a/drivers/block/DAC960.c b/drivers/block/DAC960.c index abaab30..f6121d...
2012 Mar 28
2
[PATCH] virtio_blk: add helper function to support mass of disks naming
On Wed, Mar 28, 2012 at 02:54:43PM +0800, Ren Mingxin wrote: > Hi, > > The current virtblk's naming algorithm just supports 26^3 > disks. If there are mass of virtblks(exceeding 26^3), there > will be disks with the same name. > > According to "sd_format_disk_name()", I add function > "virtblk_name_format()" for virtblk to support mass of > disks. > > Signed-off-by: Ren Mingxin <renmx at cn.fujitsu.com> Nod. This is basically what 3e1a7ff8a0a7b948f2684930166954f9e8e776fe did. Except, maybe we should move this function into...