search for: mdev_bus_compat_class

Displaying 13 results from an estimated 13 matches for "mdev_bus_compat_class".

2019 Sep 17
1
[RFC PATCH 2/4] mdev: introduce helper to set per device dma ops
...mdev/mdev_core.c > @@ -13,6 +13,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); > + Why does mdev need to be in...
2019 Sep 17
1
[RFC PATCH 1/2] mdev: device id support
...t; + u8 id) > { > int ret; > struct mdev_parent *parent; > @@ -175,6 +178,7 @@ int mdev_register_device(struct device *dev, const > struct mdev_parent_ops *ops) > > parent->dev = dev; > parent->ops = ops; > + parent->device_id = id; > > if (!mdev_bus_compat_class) { > mdev_bus_compat_class = > class_compat_register("mdev_bus"); > @@ -208,7 +212,13 @@ int mdev_register_device(struct device *dev, const > struct mdev_parent_ops *ops) > put_device(dev); > return ret; > } > -EXPORT_SYMBOL(mdev_register_device); > + &...
2019 Sep 12
0
[RFC PATCH 1/2] mdev: device id support
...ct device *dev, + const struct mdev_parent_ops *ops, + u8 id) { int ret; struct mdev_parent *parent; @@ -175,6 +178,7 @@ int mdev_register_device(struct device *dev, const struct mdev_parent_ops *ops) parent->dev = dev; parent->ops = ops; + parent->device_id = id; if (!mdev_bus_compat_class) { mdev_bus_compat_class = class_compat_register("mdev_bus"); @@ -208,7 +212,13 @@ int mdev_register_device(struct device *dev, const struct mdev_parent_ops *ops) put_device(dev); return ret; } -EXPORT_SYMBOL(mdev_register_device); + +int mdev_register_vfio_device(struct device *...
2019 Sep 23
0
[PATCH 1/6] mdev: class id support
...dev, + const struct mdev_parent_ops *ops, + u8 class_id) { int ret; struct mdev_parent *parent; @@ -175,6 +178,7 @@ int mdev_register_device(struct device *dev, const struct mdev_parent_ops *ops) parent->dev = dev; parent->ops = ops; + parent->class_id = class_id; if (!mdev_bus_compat_class) { mdev_bus_compat_class = class_compat_register("mdev_bus"); @@ -208,7 +212,13 @@ int mdev_register_device(struct device *dev, const struct mdev_parent_ops *ops) put_device(dev); return ret; } -EXPORT_SYMBOL(mdev_register_device); + +int mdev_register_vfio_device(struct device *...
2019 Sep 10
0
[RFC PATCH 2/4] mdev: introduce helper to set per device dma ops
...ers/vfio/mdev/mdev_core.c +++ b/drivers/vfio/mdev/mdev_core.c @@ -13,6 +13,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 mde...
2019 Sep 24
0
[PATCH 1/6] mdev: class id support
...>> struct mdev_parent *parent; >> @@ -175,6 +178,7 @@ int mdev_register_device(struct device *dev, const >> struct mdev_parent_ops *ops) >> >> parent->dev = dev; >> parent->ops = ops; >> + parent->class_id = class_id; >> >> if (!mdev_bus_compat_class) { >> mdev_bus_compat_class = >> class_compat_register("mdev_bus"); >> @@ -208,7 +212,13 @@ int mdev_register_device(struct device *dev, const >> struct mdev_parent_ops *ops) >> put_device(dev); >> return ret; >> } >> -EXPORT_SYMBOL...
2019 Sep 23
1
[PATCH 1/6] mdev: class id support
...class should be on the resulting device itself. That also suggests that at the parent we cannot have a single device_ops, the ops used will depend on the type of device created. Perhaps that means we need vfio_ops alongside virtio_ops, rather than a common device_ops. Thanks, Alex > if (!mdev_bus_compat_class) { > mdev_bus_compat_class = class_compat_register("mdev_bus"); > @@ -208,7 +212,13 @@ int mdev_register_device(struct device *dev, const struct mdev_parent_ops *ops) > put_device(dev); > return ret; > } > -EXPORT_SYMBOL(mdev_register_device); > + > +int m...
2019 Sep 12
9
[RFC PATCH 0/2] Mdev: support mutiple kinds of devices
Hi all: During the development of virtio-mdev[1]. I find that mdev needs to be extended to support devices other than vfio mdev device. So this series tries to extend the mdev to be able to differ from different devices by: - device id and matching for mdev bus - device speicfic callbacks and move vfio callbacks there Sent for early reivew, compile test only! Thanks [1]
2019 Sep 12
9
[RFC PATCH 0/2] Mdev: support mutiple kinds of devices
Hi all: During the development of virtio-mdev[1]. I find that mdev needs to be extended to support devices other than vfio mdev device. So this series tries to extend the mdev to be able to differ from different devices by: - device id and matching for mdev bus - device speicfic callbacks and move vfio callbacks there Sent for early reivew, compile test only! Thanks [1]
2019 Sep 23
14
[PATCH 0/6] 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 Sep 23
14
[PATCH 0/6] 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 Sep 20
8
[RFC PATCH V2 0/6] 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 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