search for: mdev_list_lock

Displaying 20 results from an estimated 56 matches for "mdev_list_lock".

2019 Sep 10
1
[RFC PATCH 4/4] docs: Sample driver to demonstrate how to implement virtio-mdev framework
...ruct virtio_mdev_callback *cbs; > + void *buffer; > + u32 queue_sel; > + u32 driver_features_sel; > + u32 driver_features[2]; > + u32 device_features_sel; > + u32 status; > + u32 generation; > + u32 num; > + struct list_head next; > +}; > + > +static struct mutex mdev_list_lock; > +static struct list_head mdev_devices_list; > + > +static void mvnet_queue_ready(struct mvnet_state *mvnet, unsigned idx) > +{ > + struct mvnet_virtqueue *vq = &mvnet->vqs[idx]; > + int ret; > + > + vq->desc_addr = (u64)vq->desc_addr_hi << 32 | vq->d...
2019 Nov 05
0
[PATCH V8 6/6] docs: sample driver to demonstrate how to implement virtio-mdev framework
...each mdev device */ +struct mvnet_state { + struct mvnet_virtqueue vqs[2]; + struct work_struct work; + spinlock_t lock; + struct mdev_device *mdev; + struct virtio_net_config config; + void *buffer; + u32 status; + u32 generation; + u64 features; + struct list_head next; +}; + +static struct mutex mdev_list_lock; +static struct list_head mdev_devices_list; + +static void mvnet_queue_ready(struct mvnet_state *mvnet, unsigned int idx) +{ + struct mvnet_virtqueue *vq = &mvnet->vqs[idx]; + int ret; + + ret = vringh_init_kern(&vq->vring, mvnet_features, MVNET_QUEUE_MAX, + false, (struct v...
2019 Sep 10
0
[RFC PATCH 4/4] docs: Sample driver to demonstrate how to implement virtio-mdev framework
...t mdev_device *mdev; + struct virtio_net_config config; + struct virtio_mdev_callback *cbs; + void *buffer; + u32 queue_sel; + u32 driver_features_sel; + u32 driver_features[2]; + u32 device_features_sel; + u32 status; + u32 generation; + u32 num; + struct list_head next; +}; + +static struct mutex mdev_list_lock; +static struct list_head mdev_devices_list; + +static void mvnet_queue_ready(struct mvnet_state *mvnet, unsigned idx) +{ + struct mvnet_virtqueue *vq = &mvnet->vqs[idx]; + int ret; + + vq->desc_addr = (u64)vq->desc_addr_hi << 32 | vq->desc_addr_lo; + vq->device_addr = (u64...
2019 Oct 30
0
[PATCH V6 6/6] docs: sample driver to demonstrate how to implement virtio-mdev framework
...each mdev device */ +struct mvnet_state { + struct mvnet_virtqueue vqs[2]; + struct work_struct work; + spinlock_t lock; + struct mdev_device *mdev; + struct virtio_net_config config; + void *buffer; + u32 status; + u32 generation; + u64 features; + struct list_head next; +}; + +static struct mutex mdev_list_lock; +static struct list_head mdev_devices_list; + +static void mvnet_queue_ready(struct mvnet_state *mvnet, unsigned int idx) +{ + struct mvnet_virtqueue *vq = &mvnet->vqs[idx]; + int ret; + + ret = vringh_init_kern(&vq->vring, mvnet_features, MVNET_QUEUE_MAX, + false, (struct v...
2019 Nov 07
0
[PATCH V11 6/6] docs: sample driver to demonstrate how to implement virtio-mdev framework
...ct mvnet_virtqueue vqs[2]; + struct work_struct work; + /* spinlock to synchronize virtqueue state */ + spinlock_t lock; + struct mdev_device *mdev; + struct virtio_net_config config; + void *buffer; + u32 status; + u32 generation; + u64 features; + struct list_head next; +}; + +static struct mutex mdev_list_lock; +static struct list_head mdev_devices_list; + +static void mvnet_queue_ready(struct mvnet_state *mvnet, unsigned int idx) +{ + struct mvnet_virtqueue *vq = &mvnet->vqs[idx]; + int ret; + + ret = vringh_init_kern(&vq->vring, mvnet_features, MVNET_QUEUE_MAX, + false, (struct v...
2019 Nov 06
0
[PATCH V9 6/6] docs: sample driver to demonstrate how to implement virtio-mdev framework
...ct mvnet_virtqueue vqs[2]; + struct work_struct work; + /* spinlock to synchronize virtqueue state */ + spinlock_t lock; + struct mdev_device *mdev; + struct virtio_net_config config; + void *buffer; + u32 status; + u32 generation; + u64 features; + struct list_head next; +}; + +static struct mutex mdev_list_lock; +static struct list_head mdev_devices_list; + +static void mvnet_queue_ready(struct mvnet_state *mvnet, unsigned int idx) +{ + struct mvnet_virtqueue *vq = &mvnet->vqs[idx]; + int ret; + + ret = vringh_init_kern(&vq->vring, mvnet_features, MVNET_QUEUE_MAX, + false, (struct v...
2019 Nov 06
0
[PATCH V10 6/6] docs: sample driver to demonstrate how to implement virtio-mdev framework
...ct mvnet_virtqueue vqs[2]; + struct work_struct work; + /* spinlock to synchronize virtqueue state */ + spinlock_t lock; + struct mdev_device *mdev; + struct virtio_net_config config; + void *buffer; + u32 status; + u32 generation; + u64 features; + struct list_head next; +}; + +static struct mutex mdev_list_lock; +static struct list_head mdev_devices_list; + +static void mvnet_queue_ready(struct mvnet_state *mvnet, unsigned int idx) +{ + struct mvnet_virtqueue *vq = &mvnet->vqs[idx]; + int ret; + + ret = vringh_init_kern(&vq->vring, mvnet_features, MVNET_QUEUE_MAX, + false, (struct v...
2019 Nov 07
2
[PATCH V10 6/6] docs: sample driver to demonstrate how to implement virtio-mdev framework
.../* spinlock to synchronize virtqueue state */ > + spinlock_t lock; > + struct mdev_device *mdev; > + struct virtio_net_config config; > + void *buffer; > + u32 status; > + u32 generation; > + u64 features; > + struct list_head next; > +}; > + > +static struct mutex mdev_list_lock; > +static struct list_head mdev_devices_list; > + > +static void mvnet_queue_ready(struct mvnet_state *mvnet, unsigned int idx) > +{ > + struct mvnet_virtqueue *vq = &mvnet->vqs[idx]; > + int ret; > + > + ret = vringh_init_kern(&vq->vring, mvnet_features, MVNE...
2019 Nov 07
2
[PATCH V10 6/6] docs: sample driver to demonstrate how to implement virtio-mdev framework
.../* spinlock to synchronize virtqueue state */ > + spinlock_t lock; > + struct mdev_device *mdev; > + struct virtio_net_config config; > + void *buffer; > + u32 status; > + u32 generation; > + u64 features; > + struct list_head next; > +}; > + > +static struct mutex mdev_list_lock; > +static struct list_head mdev_devices_list; > + > +static void mvnet_queue_ready(struct mvnet_state *mvnet, unsigned int idx) > +{ > + struct mvnet_virtqueue *vq = &mvnet->vqs[idx]; > + int ret; > + > + ret = vringh_init_kern(&vq->vring, mvnet_features, MVNE...
2019 Sep 17
1
[RFC PATCH 2/4] mdev: introduce helper to set per device dma ops
...nclude <linux/sysfs.h> > #include <linux/mdev.h> > +#include <linux/dma-mapping.h> > > #include "mdev_private.h" > > @@ -27,6 +28,12 @@ static struct class_compat *mdev_bus_compat_class; > static LIST_HEAD(mdev_list); > static DEFINE_MUTEX(mdev_list_lock); > > +void mdev_set_dma_ops(struct mdev_device *mdev, struct dma_map_ops *ops) > +{ > + set_dma_ops(&mdev->dev, ops); > +} > +EXPORT_SYMBOL(mdev_set_dma_ops); > + Why does mdev need to be involved here? Your sample driver in 4/4 calls this from its create callback,...
2019 Sep 10
8
[RFC PATCH 0/4] mdev based hardware virtio offloading support
Hi all: There are hardware that can do virtio datapath offloading while having its own control path. This path tries to implement a mdev based unified API to support using kernel virtio driver to drive those devices. This is done by introducing a new mdev transport for virtio (virtio_mdev) and register itself as a new kind of mdev driver. Then it provides a unified way for kernel virtio driver to
2019 Nov 06
9
[PATCH V10 0/6] mdev based hardware virtio offloading support
Hi all: There are hardwares that can do virtio datapath offloading while having its own control path. This path tries to implement a mdev based unified API to support using kernel virtio driver to drive those devices. This is done by introducing a new mdev transport for virtio (virtio_mdev) and register itself as a new kind of mdev driver. Then it provides a unified way for kernel virtio driver
2019 Sep 10
0
[RFC PATCH 2/4] mdev: introduce helper to set per device dma ops
...,7 @@ #include <linux/uuid.h> #include <linux/sysfs.h> #include <linux/mdev.h> +#include <linux/dma-mapping.h> #include "mdev_private.h" @@ -27,6 +28,12 @@ static struct class_compat *mdev_bus_compat_class; static LIST_HEAD(mdev_list); static DEFINE_MUTEX(mdev_list_lock); +void mdev_set_dma_ops(struct mdev_device *mdev, struct dma_map_ops *ops) +{ + set_dma_ops(&mdev->dev, ops); +} +EXPORT_SYMBOL(mdev_set_dma_ops); + struct device *mdev_parent_dev(struct mdev_device *mdev) { return mdev->parent->dev; diff --git a/include/linux/mdev.h b/include/l...
2019 Oct 30
8
[PATCH V6 0/6] mdev based hardware virtio offloading support
Hi all: There are hardwares that can do virtio datapath offloading while having its own control path. This path tries to implement a mdev based unified API to support using kernel virtio driver to drive those devices. This is done by introducing a new mdev transport for virtio (virtio_mdev) and register itself as a new kind of mdev driver. Then it provides a unified way for kernel virtio driver
2019 Oct 23
10
[PATCH V5 0/6] mdev based hardware virtio offloading support
Hi all: There are hardwares that can do virtio datapath offloading while having its own control path. This path tries to implement a mdev based unified API to support using kernel virtio driver to drive those devices. This is done by introducing a new mdev transport for virtio (virtio_mdev) and register itself as a new kind of mdev driver. Then it provides a unified way for kernel virtio driver
2019 Oct 23
10
[PATCH V5 0/6] mdev based hardware virtio offloading support
Hi all: There are hardwares that can do virtio datapath offloading while having its own control path. This path tries to implement a mdev based unified API to support using kernel virtio driver to drive those devices. This is done by introducing a new mdev transport for virtio (virtio_mdev) and register itself as a new kind of mdev driver. Then it provides a unified way for kernel virtio driver
2019 Nov 07
9
[PATCH V11 0/6] mdev based hardware virtio offloading support
Hi all: There are hardwares that can do virtio datapath offloading while having its own control path. This path tries to implement a mdev based unified API to support using kernel virtio driver to drive those devices. This is done by introducing a new mdev transport for virtio (virtio_mdev) and register itself as a new kind of mdev driver. Then it provides a unified way for kernel virtio driver
2019 Oct 11
17
[PATCH V3 0/7] mdev based hardware virtio offloading support
Hi all: There are hardware that can do virtio datapath offloading while having its own control path. This path tries to implement a mdev based unified API to support using kernel virtio driver to drive those devices. This is done by introducing a new mdev transport for virtio (virtio_mdev) and register itself as a new kind of mdev driver. Then it provides a unified way for kernel virtio driver to
2019 Oct 11
17
[PATCH V3 0/7] mdev based hardware virtio offloading support
Hi all: There are hardware that can do virtio datapath offloading while having its own control path. This path tries to implement a mdev based unified API to support using kernel virtio driver to drive those devices. This is done by introducing a new mdev transport for virtio (virtio_mdev) and register itself as a new kind of mdev driver. Then it provides a unified way for kernel virtio driver to
2019 Nov 06
11
[PATCH V9 0/6] mdev based hardware virtio offloading support
Hi all: There are hardwares that can do virtio datapath offloading while having its own control path. This path tries to implement a mdev based unified API to support using kernel virtio driver to drive those devices. This is done by introducing a new mdev transport for virtio (virtio_mdev) and register itself as a new kind of mdev driver. Then it provides a unified way for kernel virtio driver