Displaying 20 results from an estimated 43 matches for "virtio_ccw_set_transport_rev".
2014 Dec 04
1
[PATCH RFC 2/3] virtio_ccw: legacy: don't negotiate rev 1/features
...he host. */
> features->index = 1;
> ccw->cmd_code = CCW_CMD_READ_FEAT;
> @@ -1182,9 +1185,13 @@ static int virtio_ccw_online(struct ccw_device *cdev)
> vcdev->vdev.id.vendor = cdev->id.cu_type;
> vcdev->vdev.id.device = cdev->id.cu_model;
>
> - ret = virtio_ccw_set_transport_rev(vcdev);
> - if (ret)
> - goto out_free;
> + if (virtio_device_is_legacy_only(vcdev->vdev.id)) {
Inverted logic?
> + ret = virtio_ccw_set_transport_rev(vcdev);
> + if (ret)
> + goto out_free;
> + } else {
> + vcdev->revision = 0;
> + }
>
> ret = regi...
2014 Dec 04
1
[PATCH RFC 2/3] virtio_ccw: legacy: don't negotiate rev 1/features
...he host. */
> features->index = 1;
> ccw->cmd_code = CCW_CMD_READ_FEAT;
> @@ -1182,9 +1185,13 @@ static int virtio_ccw_online(struct ccw_device *cdev)
> vcdev->vdev.id.vendor = cdev->id.cu_type;
> vcdev->vdev.id.device = cdev->id.cu_model;
>
> - ret = virtio_ccw_set_transport_rev(vcdev);
> - if (ret)
> - goto out_free;
> + if (virtio_device_is_legacy_only(vcdev->vdev.id)) {
Inverted logic?
> + ret = virtio_ccw_set_transport_rev(vcdev);
> + if (ret)
> + goto out_free;
> + } else {
> + vcdev->revision = 0;
> + }
>
> ret = regi...
2020 May 26
3
[PATCH] s390/virtio: remove unused pm callbacks
...device *cdev)
-{
- struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
-
- return virtio_device_freeze(&vcdev->vdev);
-}
-
-static int virtio_ccw_restore(struct ccw_device *cdev)
-{
- struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
- int ret;
-
- ret = virtio_ccw_set_transport_rev(vcdev);
- if (ret)
- return ret;
-
- return virtio_device_restore(&vcdev->vdev);
-}
-#endif
-
static struct ccw_driver virtio_ccw_driver = {
.driver = {
.owner = THIS_MODULE,
@@ -1405,11 +1384,6 @@ static struct ccw_driver virtio_ccw_driver = {
.set_online = virtio_ccw_online,
.no...
2020 May 26
3
[PATCH] s390/virtio: remove unused pm callbacks
...device *cdev)
-{
- struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
-
- return virtio_device_freeze(&vcdev->vdev);
-}
-
-static int virtio_ccw_restore(struct ccw_device *cdev)
-{
- struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
- int ret;
-
- ret = virtio_ccw_set_transport_rev(vcdev);
- if (ret)
- return ret;
-
- return virtio_device_restore(&vcdev->vdev);
-}
-#endif
-
static struct ccw_driver virtio_ccw_driver = {
.driver = {
.owner = THIS_MODULE,
@@ -1405,11 +1384,6 @@ static struct ccw_driver virtio_ccw_driver = {
.set_online = virtio_ccw_online,
.no...
2014 Dec 04
5
[PATCH RFC 1/3] virtio: add API to detect legacy devices
transports need to be able to detect legacy-only
devices (ATM balloon only) to use legacy path
to drive them.
Add a core API to do just that.
The implementation just blacklists balloon:
not too pretty, but let's not over-engineer.
Signed-off-by: Michael S. Tsirkin <mst at redhat.com>
---
include/linux/virtio.h | 2 ++
drivers/virtio/virtio.c | 6 ++++++
2 files changed, 8
2014 Dec 04
5
[PATCH RFC 1/3] virtio: add API to detect legacy devices
transports need to be able to detect legacy-only
devices (ATM balloon only) to use legacy path
to drive them.
Add a core API to do just that.
The implementation just blacklists balloon:
not too pretty, but let's not over-engineer.
Signed-off-by: Michael S. Tsirkin <mst at redhat.com>
---
include/linux/virtio.h | 2 ++
drivers/virtio/virtio.c | 6 ++++++
2 files changed, 8
2018 Feb 12
2
[PULL v2 1/1] virtio/s390: implement PM operations for virtio_ccw
...= dev_get_drvdata(&cdev->dev);
> +
> + return virtio_device_freeze(&vcdev->vdev);
> +}
> +
> +static int virtio_ccw_restore(struct ccw_device *cdev)
> +{
> + struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
> + int ret;
> +
> + ret = virtio_ccw_set_transport_rev(vcdev);
> + if (ret)
> + return ret;
> +
> + return virtio_device_restore(&vcdev->vdev);
> +}
> +#endif
> +
> static struct ccw_driver virtio_ccw_driver = {
> .driver = {
> .owner = THIS_MODULE,
> @@ -1324,6 +1348,11 @@ static struct ccw_driver virtio_...
2014 Dec 04
0
[PATCH RFC 2/3] virtio_ccw: legacy: don't negotiate rev 1/features
...nd half of the feature bits from the host. */
features->index = 1;
ccw->cmd_code = CCW_CMD_READ_FEAT;
@@ -1182,9 +1185,13 @@ static int virtio_ccw_online(struct ccw_device *cdev)
vcdev->vdev.id.vendor = cdev->id.cu_type;
vcdev->vdev.id.device = cdev->id.cu_model;
- ret = virtio_ccw_set_transport_rev(vcdev);
- if (ret)
- goto out_free;
+ if (virtio_device_is_legacy_only(vcdev->vdev.id)) {
+ ret = virtio_ccw_set_transport_rev(vcdev);
+ if (ret)
+ goto out_free;
+ } else {
+ vcdev->revision = 0;
+ }
ret = register_virtio_device(&vcdev->vdev);
if (ret) {
--
MST
2014 Dec 04
0
[PATCH RFC 2/3] virtio_ccw: legacy: don't negotiate rev 1/features
...nd half of the feature bits from the host. */
features->index = 1;
ccw->cmd_code = CCW_CMD_READ_FEAT;
@@ -1182,9 +1185,13 @@ static int virtio_ccw_online(struct ccw_device *cdev)
vcdev->vdev.id.vendor = cdev->id.cu_type;
vcdev->vdev.id.device = cdev->id.cu_model;
- ret = virtio_ccw_set_transport_rev(vcdev);
- if (ret)
- goto out_free;
+ if (virtio_device_is_legacy_only(vcdev->vdev.id)) {
+ ret = virtio_ccw_set_transport_rev(vcdev);
+ if (ret)
+ goto out_free;
+ } else {
+ vcdev->revision = 0;
+ }
ret = register_virtio_device(&vcdev->vdev);
if (ret) {
--
MST
2018 Feb 12
2
[PULL v2 1/1] virtio/s390: implement PM operations for virtio_ccw
...= dev_get_drvdata(&cdev->dev);
> +
> + return virtio_device_freeze(&vcdev->vdev);
> +}
> +
> +static int virtio_ccw_restore(struct ccw_device *cdev)
> +{
> + struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
> + int ret;
> +
> + ret = virtio_ccw_set_transport_rev(vcdev);
> + if (ret)
> + return ret;
> +
> + return virtio_device_restore(&vcdev->vdev);
> +}
> +#endif
> +
> static struct ccw_driver virtio_ccw_driver = {
> .driver = {
> .owner = THIS_MODULE,
> @@ -1324,6 +1348,11 @@ static struct ccw_driver virtio_...
2014 Oct 07
0
[PATCH RFC 09/11] KVM: s390: Set virtio-ccw transport revision
...CW_DOING_READ_VQ_CONF:
case VIRTIO_CCW_DOING_SET_IND_ADAPTER:
+ case VIRTIO_CCW_DOING_SET_VIRTIO_REV:
vcdev->curr_io &= ~activity;
wake_up(&vcdev->wait_q);
break;
@@ -1053,6 +1066,51 @@ static int virtio_ccw_offline(struct ccw_device *cdev)
return 0;
}
+static int virtio_ccw_set_transport_rev(struct virtio_ccw_device *vcdev)
+{
+ struct virtio_rev_info *rev;
+ struct ccw1 *ccw;
+ int ret;
+
+ ccw = kzalloc(sizeof(*ccw), GFP_DMA | GFP_KERNEL);
+ if (!ccw)
+ return -ENOMEM;
+ rev = kzalloc(sizeof(*rev), GFP_DMA | GFP_KERNEL);
+ if (!rev) {
+ kfree(ccw);
+ return -ENOMEM;
+ }
+
+ /* Set...
2017 Dec 18
2
[PULL v2 0/1] s390/virtio update
The following changes since commit 20677394b78ed4c4baa09c9a1bcfdf24d2b09fe4:
Merge branch 'vhost' into vhost-next (2017-12-18 08:21:38 +0200)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux.git tags/virtio-s390-20171218-v2
for you to fetch changes up to 352d303fa99330e5d197afcc28b5270734e5c541:
virtio/s390: implement PM
2017 Dec 18
2
[PULL v2 0/1] s390/virtio update
The following changes since commit 20677394b78ed4c4baa09c9a1bcfdf24d2b09fe4:
Merge branch 'vhost' into vhost-next (2017-12-18 08:21:38 +0200)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux.git tags/virtio-s390-20171218-v2
for you to fetch changes up to 352d303fa99330e5d197afcc28b5270734e5c541:
virtio/s390: implement PM
2017 Dec 07
3
[PATCH 0/1] suspend/resume for virtio_ccw
With this patch I can suspend/resume a KVM guest.
[root at test ~]# cd /sys/power/
[root at test power]# echo test_resume > disk
[root at test power]# lscss
Device Subchan. DevType CU Type Use PIM PAM POM CHPIDs
----------------------------------------------------------------------
0.0.0003 0.0.0000 0000/00 3832/03 yes 80 80 ff 00000000 00000000
0.0.0000 0.0.0001
2017 Dec 07
3
[PATCH 0/1] suspend/resume for virtio_ccw
With this patch I can suspend/resume a KVM guest.
[root at test ~]# cd /sys/power/
[root at test power]# echo test_resume > disk
[root at test power]# lscss
Device Subchan. DevType CU Type Use PIM PAM POM CHPIDs
----------------------------------------------------------------------
0.0.0003 0.0.0000 0000/00 3832/03 yes 80 80 ff 00000000 00000000
0.0.0000 0.0.0001
2017 Dec 07
0
[PATCH 1/1] virtio/s390: implement PM operations for virtio_ccw
...device *cdev)
+{
+ struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
+
+ return virtio_device_freeze(&vcdev->vdev);
+}
+
+static int virtio_ccw_restore(struct ccw_device *cdev)
+{
+ struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
+ int ret;
+
+ ret = virtio_ccw_set_transport_rev(vcdev);
+ if (ret)
+ return ret;
+
+ return virtio_device_restore(&vcdev->vdev);
+}
+
static struct ccw_driver virtio_ccw_driver = {
.driver = {
.owner = THIS_MODULE,
@@ -1324,6 +1346,9 @@ static struct ccw_driver virtio_ccw_driver = {
.set_online = virtio_ccw_online,
.notify = vi...
2017 Dec 18
0
[PULL v2 1/1] virtio/s390: implement PM operations for virtio_ccw
...device *cdev)
+{
+ struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
+
+ return virtio_device_freeze(&vcdev->vdev);
+}
+
+static int virtio_ccw_restore(struct ccw_device *cdev)
+{
+ struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
+ int ret;
+
+ ret = virtio_ccw_set_transport_rev(vcdev);
+ if (ret)
+ return ret;
+
+ return virtio_device_restore(&vcdev->vdev);
+}
+#endif
+
static struct ccw_driver virtio_ccw_driver = {
.driver = {
.owner = THIS_MODULE,
@@ -1324,6 +1348,11 @@ static struct ccw_driver virtio_ccw_driver = {
.set_online = virtio_ccw_online,
.no...
2018 Feb 14
0
[PULL v2 1/1] virtio/s390: implement PM operations for virtio_ccw
...> > + return virtio_device_freeze(&vcdev->vdev);
> > +}
> > +
> > +static int virtio_ccw_restore(struct ccw_device *cdev)
> > +{
> > + struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
> > + int ret;
> > +
> > + ret = virtio_ccw_set_transport_rev(vcdev);
> > + if (ret)
> > + return ret;
> > +
> > + return virtio_device_restore(&vcdev->vdev);
> > +}
> > +#endif
> > +
> > static struct ccw_driver virtio_ccw_driver = {
> > .driver = {
> > .owner = THIS_MODULE,
> >...
2020 Jun 04
0
[PATCH] s390/virtio: remove unused pm callbacks
...= dev_get_drvdata(&cdev->dev);
> -
> - return virtio_device_freeze(&vcdev->vdev);
> -}
> -
> -static int virtio_ccw_restore(struct ccw_device *cdev)
> -{
> - struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
> - int ret;
> -
> - ret = virtio_ccw_set_transport_rev(vcdev);
> - if (ret)
> - return ret;
> -
> - return virtio_device_restore(&vcdev->vdev);
> -}
> -#endif
> -
> static struct ccw_driver virtio_ccw_driver = {
> .driver = {
> .owner = THIS_MODULE,
> @@ -1405,11 +1384,6 @@ static struct ccw_driver virtio_...
2020 Jun 05
1
[PATCH] s390/virtio: remove unused pm callbacks
...> > - return virtio_device_freeze(&vcdev->vdev);
> > -}
> > -
> > -static int virtio_ccw_restore(struct ccw_device *cdev)
> > -{
> > - struct virtio_ccw_device *vcdev = dev_get_drvdata(&cdev->dev);
> > - int ret;
> > -
> > - ret = virtio_ccw_set_transport_rev(vcdev);
> > - if (ret)
> > - return ret;
> > -
> > - return virtio_device_restore(&vcdev->vdev);
> > -}
> > -#endif
> > -
> > static struct ccw_driver virtio_ccw_driver = {
> > .driver = {
> > .owner = THIS_MODULE,
> >...