search for: rproc_add_virtio_dev

Displaying 16 results from an estimated 16 matches for "rproc_add_virtio_dev".

2017 Dec 20
1
[PATCH v4 4/4] virtio_remoteproc: don't kfree device on register failure
...1 insertions(+), 2 deletions(-) > > diff --git a/drivers/remoteproc/remoteproc_virtio.c b/drivers/remoteproc/remoteproc_virtio.c > index 2946348..1073ea3 100644 > --- a/drivers/remoteproc/remoteproc_virtio.c > +++ b/drivers/remoteproc/remoteproc_virtio.c > @@ -304,7 +304,7 @@ int rproc_add_virtio_dev(struct rproc_vdev *rvdev, int id) > { > struct rproc *rproc = rvdev->rproc; > struct device *dev = &rproc->dev; > - struct virtio_device *vdev = &rvdev->vdev; > + struct virtio_device *vdev = &rvdev->vdev, *reg_dev = NULL; > int ret; > > vd...
2017 Dec 20
0
[PATCH v4 4/4] virtio_remoteproc: don't kfree device on register failure
...+++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/drivers/remoteproc/remoteproc_virtio.c b/drivers/remoteproc/remoteproc_virtio.c index 2946348..1073ea3 100644 --- a/drivers/remoteproc/remoteproc_virtio.c +++ b/drivers/remoteproc/remoteproc_virtio.c @@ -304,7 +304,7 @@ int rproc_add_virtio_dev(struct rproc_vdev *rvdev, int id) { struct rproc *rproc = rvdev->rproc; struct device *dev = &rproc->dev; - struct virtio_device *vdev = &rvdev->vdev; + struct virtio_device *vdev = &rvdev->vdev, *reg_dev = NULL; int ret; vdev->id.device = id, @@ -326,15 +326,2...
2017 Dec 21
2
[PATCH v5 4/4] virtio_remoteproc: correct put_device virtio_device.dev
...irtio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/remoteproc/remoteproc_virtio.c b/drivers/remoteproc/remoteproc_virtio.c index 2946348..b0633fd 100644 --- a/drivers/remoteproc/remoteproc_virtio.c +++ b/drivers/remoteproc/remoteproc_virtio.c @@ -327,7 +327,7 @@ int rproc_add_virtio_dev(struct rproc_vdev *rvdev, int id) ret = register_virtio_device(vdev); if (ret) { - put_device(&rproc->dev); + put_device(&vdev->dev); dev_err(dev, "failed to register vdev: %d\n", ret); goto out; } -- 2.9.4
2017 Dec 20
8
[PATCH v4 0/4] use put_device to cleanup resource
Hi, The main change is split device_register into 2 sperate calls: device_initalize() and device_add, and then the caller can use put_device safety when fail to register_virtio_device. v3->v4: * split device_register into device_initialize and devicea_add that the caller can always use put_device when fail to register virtio device. v2->v3: * virtio: add new helper do get
2017 Dec 20
8
[PATCH v4 0/4] use put_device to cleanup resource
Hi, The main change is split device_register into 2 sperate calls: device_initalize() and device_add, and then the caller can use put_device safety when fail to register_virtio_device. v3->v4: * split device_register into device_initialize and devicea_add that the caller can always use put_device when fail to register virtio device. v2->v3: * virtio: add new helper do get
2017 Dec 11
6
[PATCH 0/3] fix cleanup for fail to register_virtio_device
This series fix the cleanup for the caller of register_virtio_device, the main work is use put_device instead of kfree. weiping zhang (3): virtio_pci: use put_device instead of kfree virtio: use put_device instead of kfree virtio: put reference count of virtio_device.dev drivers/misc/mic/vop/vop_main.c | 16 +++++++++------- drivers/remoteproc/remoteproc_virtio.c | 2 +-
2017 Dec 11
6
[PATCH 0/3] fix cleanup for fail to register_virtio_device
This series fix the cleanup for the caller of register_virtio_device, the main work is use put_device instead of kfree. weiping zhang (3): virtio_pci: use put_device instead of kfree virtio: use put_device instead of kfree virtio: put reference count of virtio_device.dev drivers/misc/mic/vop/vop_main.c | 16 +++++++++------- drivers/remoteproc/remoteproc_virtio.c | 2 +-
2017 Dec 11
0
[PATCH 3/3] virtio: put reference count of virtio_device.dev
...irtio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/remoteproc/remoteproc_virtio.c b/drivers/remoteproc/remoteproc_virtio.c index 2946348..b0633fd 100644 --- a/drivers/remoteproc/remoteproc_virtio.c +++ b/drivers/remoteproc/remoteproc_virtio.c @@ -327,7 +327,7 @@ int rproc_add_virtio_dev(struct rproc_vdev *rvdev, int id) ret = register_virtio_device(vdev); if (ret) { - put_device(&rproc->dev); + put_device(&vdev->dev); dev_err(dev, "failed to register vdev: %d\n", ret); goto out; } -- 2.9.4
2017 Dec 12
5
[PATCH v2 0/3] fix cleanup for fail to register_virtio_device
This series fix the cleanup for the caller of register_virtio_device, the main work is use put_device instead of kfree. V1->V2: * virtio_pci: add comments for the reason use put_device * virtio vop: also use put_device in in _vop_remove_device() weiping zhang (3): virtio_pci: use put_device instead of kfree virtio: use put_device instead of kfree virtio: put reference count of
2017 Dec 12
5
[PATCH v2 0/3] fix cleanup for fail to register_virtio_device
This series fix the cleanup for the caller of register_virtio_device, the main work is use put_device instead of kfree. V1->V2: * virtio_pci: add comments for the reason use put_device * virtio vop: also use put_device in in _vop_remove_device() weiping zhang (3): virtio_pci: use put_device instead of kfree virtio: use put_device instead of kfree virtio: put reference count of
2017 Dec 17
6
[PATCH v3 0/5] proper cleanup if fail to register_virtio_device
Hi, Patch1 add a helper to get virtio_device's status which will be used later. Patch2~4: check virtio_device's status is RTIO_CONFIG_S_ACKNOWLEDGE or not, if so use put_device otherwise use kfree. Patch5: add comments for virtio_register_device help caller do a proper cleanup if got failure. weiping zhang (5): virtio: add helper virtio_get_status virtio_pci: don't kfree device
2017 Dec 17
6
[PATCH v3 0/5] proper cleanup if fail to register_virtio_device
Hi, Patch1 add a helper to get virtio_device's status which will be used later. Patch2~4: check virtio_device's status is RTIO_CONFIG_S_ACKNOWLEDGE or not, if so use put_device otherwise use kfree. Patch5: add comments for virtio_register_device help caller do a proper cleanup if got failure. weiping zhang (5): virtio: add helper virtio_get_status virtio_pci: don't kfree device
2013 Apr 09
1
[PATCHv2 virtio-next] remoteproc: Add support for host virtio rings (vringh)
...proc_virtio_vringh_ops = { + .find_vrhs = rproc_virtio_find_vrhs, + .del_vrhs = rproc_virtio_del_vrhs, +}; + static const struct virtio_config_ops rproc_virtio_config_ops = { .get_features = rproc_virtio_get_features, .finalize_features = rproc_virtio_finalize_features, @@ -270,6 +467,7 @@ int rproc_add_virtio_dev(struct rproc_vdev *rvdev, int id) vdev->id.device = id, vdev->config = &rproc_virtio_config_ops, + vdev->vringh_config = &rproc_virtio_vringh_ops; vdev->dev.parent = dev; vdev->dev.release = rproc_vdev_release; diff --git a/include/linux/remoteproc.h b/include/lin...
2013 Apr 09
1
[PATCHv2 virtio-next] remoteproc: Add support for host virtio rings (vringh)
...proc_virtio_vringh_ops = { + .find_vrhs = rproc_virtio_find_vrhs, + .del_vrhs = rproc_virtio_del_vrhs, +}; + static const struct virtio_config_ops rproc_virtio_config_ops = { .get_features = rproc_virtio_get_features, .finalize_features = rproc_virtio_finalize_features, @@ -270,6 +467,7 @@ int rproc_add_virtio_dev(struct rproc_vdev *rvdev, int id) vdev->id.device = id, vdev->config = &rproc_virtio_config_ops, + vdev->vringh_config = &rproc_virtio_vringh_ops; vdev->dev.parent = dev; vdev->dev.release = rproc_vdev_release; diff --git a/include/linux/remoteproc.h b/include/lin...
2013 Mar 15
2
[PATCH 0/2] remoteproc : support for host virtio
From: Erwan Yvin <erwan.yvin at stericsson.com> This driver depends on Rusty's new host virtio ring implementation, so this patch-set is based on the vringh branch in Rusty's git. with the vringh wrapper patch on top. They do not apply cleanly on top of the remoteproc virtio config patches from Sjur, but it merges fine. CAIF will use this new host virtio ring implementation. Ido,
2013 Mar 15
2
[PATCH 0/2] remoteproc : support for host virtio
From: Erwan Yvin <erwan.yvin at stericsson.com> This driver depends on Rusty's new host virtio ring implementation, so this patch-set is based on the vringh branch in Rusty's git. with the vringh wrapper patch on top. They do not apply cleanly on top of the remoteproc virtio config patches from Sjur, but it merges fine. CAIF will use this new host virtio ring implementation. Ido,