search for: dev_count

Displaying 12 results from an estimated 12 matches for "dev_count".

2015 Mar 27
1
Channel Device virConnectListAllNodeDevices
...<address type='virtio-serial' controller='0' bus='0' port='3'/> </channel> I am expecting virConnectListAllNodeDevices to have the device in its output. But I don't see it there. Is it the right function to call ? virNodeDevicePtr* devices; int dev_count = virConnectListAllNodeDevices(conn, &devices, 0); std::cout << "Devices: " << dev_count << std::endl; for(virNodeDevicePtr* device = devices; device < devices+dev_count; ++device){ std::cout << virNodeDeviceGetName(*device) << std::endl; } retu...
2009 Sep 14
2
[PATCH node-image] add livecd-iso-to-iscsi script to support iscsi root booting setup
...et\n" + bus = dbus.SystemBus () + hal_obj = bus.get_object ('org.freedesktop.Hal', '/org/freedesktop/Hal/Manager') + hal = dbus.Interface (hal_obj, 'org.freedesktop.Hal.Manager') + udis = hal.FindDeviceByCapability ('storage') + dev_dict = {} + dev_count = 1 + for udi in udis: + dev_obj = bus.get_object ('org.freedesktop.Hal', udi) + dev = dbus.Interface (dev_obj, 'org.freedesktop.Hal.Device') + dev_bus=dev.GetProperty ('storage.bus') + dev_name=dev.GetProperty ('block.device') +...
2019 Sep 05
0
[PATCH 17/18] virtiofs: Remove TODO to quiesce/end_requests
We now stop queues and drain all the pending requests from all virtqueues. So this is not a TODO anymore. Got rid of incrementing fc->dev_count as well. It did not seem meaningful for virtio_fs. Signed-off-by: Vivek Goyal <vgoyal at redhat.com> --- fs/fuse/virtio_fs.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/fs/fuse/virtio_fs.c b/fs/fuse/virtio_fs.c index c483482185b6..eadaea6eb8e2 100644 --- a/fs/fuse/virtio_fs.c +++ b...
2019 Sep 05
0
[PATCH 11/18] virtiofs: stop and drain queues after sending DESTROY
.../fuse/virtio_fs.c +++ b/fs/fuse/virtio_fs.c @@ -180,9 +180,6 @@ static void virtio_fs_free_devs(struct virtio_fs *fs) if (!fsvq->fud) continue; - flush_work(&fsvq->done_work); - flush_delayed_work(&fsvq->dispatch_work); - /* TODO need to quiesce/end_requests/decrement dev_count */ fuse_dev_free(fsvq->fud); fsvq->fud = NULL; @@ -994,6 +991,8 @@ static int virtio_fs_fill_super(struct super_block *sb) atomic_inc(&fc->dev_count); } + /* Previous unmount will stop all queues. Start these again */ + virtio_fs_start_all_queues(fs); fuse_send_init(fc,...
2009 Dec 21
0
[PATCH] btrfsctl: scan device and exit without using ioctl
...; +#include "volumes.h" #ifdef __CHECKER__ #define BLKGETSIZE64 0 @@ -88,6 +90,30 @@ static int open_file_or_dir(const char *fname) } return fd; } + +int btrfs_scan_file (const char *path) +{ + int ret = -1; + struct btrfs_fs_devices *fs_devices = NULL; + u64 dev_count = 0; + int fd = -1; + + fd = open (path, O_RDONLY); + if (fd < 0) { + fprintf (stderr, "failed to open %s: %s\n", + path, strerror (errno)); + } else { + + ret = btrfs_scan_one_device (fd, path, &fs_d...
2019 Sep 05
38
[PATCH 00/18] virtiofs: Fix various races and cleanups round 1
Hi, Michael Tsirkin pointed out issues w.r.t various locking related TODO items and races w.r.t device removal. In this first round of cleanups, I have taken care of most pressing issues. These patches apply on top of following. git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse.git#virtiofs-v4 I have tested these patches with mount/umount and device removal using qemu monitor. For
2019 Sep 06
1
[PATCH v4 15/16] virtio-fs: add virtiofs filesystem
...> > + > > > + if (!fsvq->fud) > > > + continue; > > > + > > > + flush_work(&fsvq->done_work); > > > + flush_delayed_work(&fsvq->dispatch_work); > > > + > > > + /* TODO need to quiesce/end_requests/decrement dev_count */ > > > > Indeed. Won't this crash if we don't? > > Took care of this as well. > > [..] > > > +static void virtio_fs_hiprio_dispatch_work(struct work_struct *work) > > > +{ > > > + struct virtio_fs_forget *forget; > > > + struc...
2009 Oct 14
4
Refactor ovirt-node-image code base for inclusion in Fedora
Main reason for refactor is no ovirt-node-image binary image allowed in fedora. Removed ks files, now in ovirt-node-recipe, which is subpackage of ovirt-node. Removed tools, these are now in ovirt-node-recipe which is subpackage of ovirt-node.
2009 Oct 14
8
Refactor ovirt-node code base for inclusion in Fedora
Main reason for refactor is no ovirt-node-image binary image allowed in fedora. Moves tools and kickstart files form ovirt-node-image to subpackage ovirt-node-recipe. Removes old sub packages form ovirt-node, stateless, logos, selinux. Modifies init scripts to meet Fedora packaging guidelines: added status, reload, and lockfile, rhbz: 514221 Added License file.
2019 Sep 03
4
[PATCH v4 15/16] virtio-fs: add virtiofs filesystem
...fs->nvqs; i++) { > + struct virtio_fs_vq *fsvq = &fs->vqs[i]; > + > + if (!fsvq->fud) > + continue; > + > + flush_work(&fsvq->done_work); > + flush_delayed_work(&fsvq->dispatch_work); > + > + /* TODO need to quiesce/end_requests/decrement dev_count */ Indeed. Won't this crash if we don't? > + fuse_dev_free(fsvq->fud); > + fsvq->fud = NULL; > + } > +} > + > +/* Read filesystem name from virtio config into fs->tag (must kfree()). */ > +static int virtio_fs_read_tag(struct virtio_device *vdev, struct vir...
2019 Sep 03
4
[PATCH v4 15/16] virtio-fs: add virtiofs filesystem
...fs->nvqs; i++) { > + struct virtio_fs_vq *fsvq = &fs->vqs[i]; > + > + if (!fsvq->fud) > + continue; > + > + flush_work(&fsvq->done_work); > + flush_delayed_work(&fsvq->dispatch_work); > + > + /* TODO need to quiesce/end_requests/decrement dev_count */ Indeed. Won't this crash if we don't? > + fuse_dev_free(fsvq->fud); > + fsvq->fud = NULL; > + } > +} > + > +/* Read filesystem name from virtio config into fs->tag (must kfree()). */ > +static int virtio_fs_read_tag(struct virtio_device *vdev, struct vir...
2019 Sep 05
0
[PATCH v4 15/16] virtio-fs: add virtiofs filesystem
...o_fs_vq *fsvq = &fs->vqs[i]; > > + > > + if (!fsvq->fud) > > + continue; > > + > > + flush_work(&fsvq->done_work); > > + flush_delayed_work(&fsvq->dispatch_work); > > + > > + /* TODO need to quiesce/end_requests/decrement dev_count */ > > Indeed. Won't this crash if we don't? Took care of this as well. [..] > > +static void virtio_fs_hiprio_dispatch_work(struct work_struct *work) > > +{ > > + struct virtio_fs_forget *forget; > > + struct virtio_fs_vq *fsvq = container_of(work, struct v...