search for: virtio_pci_pm_ops

Displaying 20 results from an estimated 65 matches for "virtio_pci_pm_ops".

2014 Sep 05
2
[PATCH] virtio: pci: Use SIMPLE_DEV_PM_OPS macro
...--git a/drivers/virtio/virtio_pci.c b/drivers/virtio/virtio_pci.c index 3d1463c6b120..c5fbdb4023d1 100644 --- a/drivers/virtio/virtio_pci.c +++ b/drivers/virtio/virtio_pci.c @@ -810,20 +810,17 @@ static int virtio_pci_restore(struct device *dev) return ret; } - -static const struct dev_pm_ops virtio_pci_pm_ops = { - SET_SYSTEM_SLEEP_PM_OPS(virtio_pci_freeze, virtio_pci_restore) -}; #endif +static SIMPLE_DEV_PM_OPS(virtio_pci_pm_ops, virtio_pci_freeze, + virtio_pci_restore); + static struct pci_driver virtio_pci_driver = { .name = "virtio-pci", .id_table = virtio_pci_id_table, .pro...
2014 Sep 05
2
[PATCH] virtio: pci: Use SIMPLE_DEV_PM_OPS macro
...--git a/drivers/virtio/virtio_pci.c b/drivers/virtio/virtio_pci.c index 3d1463c6b120..c5fbdb4023d1 100644 --- a/drivers/virtio/virtio_pci.c +++ b/drivers/virtio/virtio_pci.c @@ -810,20 +810,17 @@ static int virtio_pci_restore(struct device *dev) return ret; } - -static const struct dev_pm_ops virtio_pci_pm_ops = { - SET_SYSTEM_SLEEP_PM_OPS(virtio_pci_freeze, virtio_pci_restore) -}; #endif +static SIMPLE_DEV_PM_OPS(virtio_pci_pm_ops, virtio_pci_freeze, + virtio_pci_restore); + static struct pci_driver virtio_pci_driver = { .name = "virtio-pci", .id_table = virtio_pci_id_table, .pro...
2014 Sep 17
2
[PATCH] virtio: pci: Use SIMPLE_DEV_PM_OPS macro
..._fn, \ .freeze = suspend_fn, \ .thaw = resume_fn, \ .poweroff = suspend_fn, \ .restore = resume_fn, #else #define SET_SYSTEM_SLEEP_PM_OPS(suspend_fn, resume_fn) #endif So, when CONFIG_PM_SLEEP is NOT enabled, SIMPLE_DEV_PM_OPS can be changed as below. The members of virtio_pci_pm_ops can be NULL. Thus, there is no build error, when CONFIG_PM_SLEEP=n. However, if you want, I will just change SET_SYSTEM_SLEEP_PM_OPS into SIMPLE_DEV_PM_OPS macro, without any change about '#ifdef CONFIG_PM_SLEEP' guards. const struct dev_pm_ops virtio_pci_pm_ops = { }; static struct pci_...
2014 Sep 17
2
[PATCH] virtio: pci: Use SIMPLE_DEV_PM_OPS macro
..._fn, \ .freeze = suspend_fn, \ .thaw = resume_fn, \ .poweroff = suspend_fn, \ .restore = resume_fn, #else #define SET_SYSTEM_SLEEP_PM_OPS(suspend_fn, resume_fn) #endif So, when CONFIG_PM_SLEEP is NOT enabled, SIMPLE_DEV_PM_OPS can be changed as below. The members of virtio_pci_pm_ops can be NULL. Thus, there is no build error, when CONFIG_PM_SLEEP=n. However, if you want, I will just change SET_SYSTEM_SLEEP_PM_OPS into SIMPLE_DEV_PM_OPS macro, without any change about '#ifdef CONFIG_PM_SLEEP' guards. const struct dev_pm_ops virtio_pci_pm_ops = { }; static struct pci_...
2014 Sep 09
0
[PATCH] virtio: pci: Use SIMPLE_DEV_PM_OPS macro
...s/virtio/virtio_pci.c > index 3d1463c6b120..c5fbdb4023d1 100644 > --- a/drivers/virtio/virtio_pci.c > +++ b/drivers/virtio/virtio_pci.c > @@ -810,20 +810,17 @@ static int virtio_pci_restore(struct device *dev) > > return ret; > } > - > -static const struct dev_pm_ops virtio_pci_pm_ops = { > - SET_SYSTEM_SLEEP_PM_OPS(virtio_pci_freeze, virtio_pci_restore) > -}; > #endif > > +static SIMPLE_DEV_PM_OPS(virtio_pci_pm_ops, virtio_pci_freeze, > + virtio_pci_restore); > + > static struct pci_driver virtio_pci_driver = { > .name = "virtio-pci&quo...
2014 Dec 15
8
[PATCH 0/6] virtio 1.0 fixups, tweaks
Fixes a couple of minor compliance issues in new virtio 1.0 code. Plus, adds a couple of minor cleanups - not bugfixes, but seem safe enough for 3.19. Michael S. Tsirkin (6): virtio: set VIRTIO_CONFIG_S_FEATURES_OK on restore virtio_config: fix virtio_cread_bytes virtio_pci_common.h: drop VIRTIO_PCI_NO_LEGACY virtio_pci: move probe to common file virtio_pci: add VIRTIO_PCI_NO_LEGACY
2014 Dec 15
8
[PATCH 0/6] virtio 1.0 fixups, tweaks
Fixes a couple of minor compliance issues in new virtio 1.0 code. Plus, adds a couple of minor cleanups - not bugfixes, but seem safe enough for 3.19. Michael S. Tsirkin (6): virtio: set VIRTIO_CONFIG_S_FEATURES_OK on restore virtio_config: fix virtio_cread_bytes virtio_pci_common.h: drop VIRTIO_PCI_NO_LEGACY virtio_pci: move probe to common file virtio_pci: add VIRTIO_PCI_NO_LEGACY
2014 Nov 09
1
[PATCH] virtio-pci: Reset device on shutdown
...ct virtio_pci_device *vp_dev = pci_get_drvdata(pci_dev); @@ -794,6 +802,7 @@ static struct pci_driver virtio_pci_driver = { .id_table = virtio_pci_id_table, .probe = virtio_pci_probe, .remove = virtio_pci_remove, + .shutdown = virtio_pci_shutdown, #ifdef CONFIG_PM_SLEEP .driver.pm = &virtio_pci_pm_ops, #endif -- 1.9.3
2014 Nov 09
1
[PATCH] virtio-pci: Reset device on shutdown
...ct virtio_pci_device *vp_dev = pci_get_drvdata(pci_dev); @@ -794,6 +802,7 @@ static struct pci_driver virtio_pci_driver = { .id_table = virtio_pci_id_table, .probe = virtio_pci_probe, .remove = virtio_pci_remove, + .shutdown = virtio_pci_shutdown, #ifdef CONFIG_PM_SLEEP .driver.pm = &virtio_pci_pm_ops, #endif -- 1.9.3
2012 Mar 29
5
[PATCH 0/5] virtio: S3 support, use PM API macro for init
Hello, Turns out S3 is not different from S4 for virtio devices: the device is assumed to be reset, so the host and guest state are to be assumed to be out of sync upon resume. We handle the S4 case with exactly the same scenario, so just point the suspend/resume routines to the freeze/restore ones. Once that is done, we also use the PM API's macro to initialise the sleep functions. A
2012 Mar 29
5
[PATCH 0/5] virtio: S3 support, use PM API macro for init
Hello, Turns out S3 is not different from S4 for virtio devices: the device is assumed to be reset, so the host and guest state are to be assumed to be out of sync upon resume. We handle the S4 case with exactly the same scenario, so just point the suspend/resume routines to the freeze/restore ones. Once that is done, we also use the PM API's macro to initialise the sleep functions. A
2018 May 30
8
[PATCH] virtio_pci: support enabling VFs
...+ return -ENOENT; + + return sriov_configure(pci_dev, num_vfs); +} + static struct pci_driver virtio_pci_driver = { .name = "virtio-pci", .id_table = virtio_pci_id_table, @@ -596,6 +615,7 @@ static struct pci_driver virtio_pci_driver = { #ifdef CONFIG_PM_SLEEP .driver.pm = &virtio_pci_pm_ops, #endif + .sriov_configure = virtio_pci_sriov_configure, }; module_pci_driver(virtio_pci_driver); diff --git a/drivers/virtio/virtio_pci_modern.c b/drivers/virtio/virtio_pci_modern.c index 2555d80f6eec..07571daccfec 100644 --- a/drivers/virtio/virtio_pci_modern.c +++ b/drivers/virtio/virtio_pc...
2018 May 30
8
[PATCH] virtio_pci: support enabling VFs
...+ return -ENOENT; + + return sriov_configure(pci_dev, num_vfs); +} + static struct pci_driver virtio_pci_driver = { .name = "virtio-pci", .id_table = virtio_pci_id_table, @@ -596,6 +615,7 @@ static struct pci_driver virtio_pci_driver = { #ifdef CONFIG_PM_SLEEP .driver.pm = &virtio_pci_pm_ops, #endif + .sriov_configure = virtio_pci_sriov_configure, }; module_pci_driver(virtio_pci_driver); diff --git a/drivers/virtio/virtio_pci_modern.c b/drivers/virtio/virtio_pci_modern.c index 2555d80f6eec..07571daccfec 100644 --- a/drivers/virtio/virtio_pci_modern.c +++ b/drivers/virtio/virtio_pc...
2014 Dec 08
0
[PATCH v2 08/10] virtio_pci: split out legacy device support
...the affinity for per vq vector + * - OR over all affinities for shared MSI + * - ignore the affinity request if we're using INTX + */ +int vp_set_vq_affinity(struct virtqueue *vq, int cpu); +void virtio_pci_release_dev(struct device *); + +#ifdef CONFIG_PM_SLEEP +extern const struct dev_pm_ops virtio_pci_pm_ops; +#endif + +#endif diff --git a/drivers/virtio/virtio_pci.c b/drivers/virtio/virtio_pci.c index c8ca3f7..d73ceec 100644 --- a/drivers/virtio/virtio_pci.c +++ b/drivers/virtio/virtio_pci.c @@ -14,179 +14,10 @@ * */ -#include <linux/module.h> -#include <linux/list.h> -#include <l...
2014 Dec 08
0
[PATCH v2 08/10] virtio_pci: split out legacy device support
...the affinity for per vq vector + * - OR over all affinities for shared MSI + * - ignore the affinity request if we're using INTX + */ +int vp_set_vq_affinity(struct virtqueue *vq, int cpu); +void virtio_pci_release_dev(struct device *); + +#ifdef CONFIG_PM_SLEEP +extern const struct dev_pm_ops virtio_pci_pm_ops; +#endif + +#endif diff --git a/drivers/virtio/virtio_pci.c b/drivers/virtio/virtio_pci.c index c8ca3f7..d73ceec 100644 --- a/drivers/virtio/virtio_pci.c +++ b/drivers/virtio/virtio_pci.c @@ -14,179 +14,10 @@ * */ -#include <linux/module.h> -#include <linux/list.h> -#include <l...
2018 Jun 01
2
[PATCH v3] virtio_pci: support enabling VFs
...v, num_vfs); + if (ret < 0) + return ret; + + return num_vfs; +} + static struct pci_driver virtio_pci_driver = { .name = "virtio-pci", .id_table = virtio_pci_id_table, @@ -596,6 +625,7 @@ static struct pci_driver virtio_pci_driver = { #ifdef CONFIG_PM_SLEEP .driver.pm = &virtio_pci_pm_ops, #endif + .sriov_configure = virtio_pci_sriov_configure, }; module_pci_driver(virtio_pci_driver); diff --git a/drivers/virtio/virtio_pci_modern.c b/drivers/virtio/virtio_pci_modern.c index 2555d80f6eec..07571daccfec 100644 --- a/drivers/virtio/virtio_pci_modern.c +++ b/drivers/virtio/virtio_pc...
2018 Jun 01
2
[PATCH v3] virtio_pci: support enabling VFs
...v, num_vfs); + if (ret < 0) + return ret; + + return num_vfs; +} + static struct pci_driver virtio_pci_driver = { .name = "virtio-pci", .id_table = virtio_pci_id_table, @@ -596,6 +625,7 @@ static struct pci_driver virtio_pci_driver = { #ifdef CONFIG_PM_SLEEP .driver.pm = &virtio_pci_pm_ops, #endif + .sriov_configure = virtio_pci_sriov_configure, }; module_pci_driver(virtio_pci_driver); diff --git a/drivers/virtio/virtio_pci_modern.c b/drivers/virtio/virtio_pci_modern.c index 2555d80f6eec..07571daccfec 100644 --- a/drivers/virtio/virtio_pci_modern.c +++ b/drivers/virtio/virtio_pc...
2014 Dec 08
0
[PATCH 8/9] virtio_pci: split out legacy device support
...the affinity for per vq vector + * - OR over all affinities for shared MSI + * - ignore the affinity request if we're using INTX + */ +int vp_set_vq_affinity(struct virtqueue *vq, int cpu); +void virtio_pci_release_dev(struct device *); + +#ifdef CONFIG_PM_SLEEP +extern const struct dev_pm_ops virtio_pci_pm_ops; +#endif + +#endif diff --git a/drivers/virtio/virtio_pci.c b/drivers/virtio/virtio_pci.c index c8ca3f7..6c7e186 100644 --- a/drivers/virtio/virtio_pci.c +++ b/drivers/virtio/virtio_pci.c @@ -14,179 +14,10 @@ * */ -#include <linux/module.h> -#include <linux/list.h> -#include <l...
2014 Dec 08
0
[PATCH 8/9] virtio_pci: split out legacy device support
...the affinity for per vq vector + * - OR over all affinities for shared MSI + * - ignore the affinity request if we're using INTX + */ +int vp_set_vq_affinity(struct virtqueue *vq, int cpu); +void virtio_pci_release_dev(struct device *); + +#ifdef CONFIG_PM_SLEEP +extern const struct dev_pm_ops virtio_pci_pm_ops; +#endif + +#endif diff --git a/drivers/virtio/virtio_pci.c b/drivers/virtio/virtio_pci.c index c8ca3f7..6c7e186 100644 --- a/drivers/virtio/virtio_pci.c +++ b/drivers/virtio/virtio_pci.c @@ -14,179 +14,10 @@ * */ -#include <linux/module.h> -#include <linux/list.h> -#include <l...
2018 Jun 01
3
[PATCH v2] virtio_pci: support enabling VFs
...v, num_vfs); + if (ret < 0) + return ret; + + return num_vfs; +} + static struct pci_driver virtio_pci_driver = { .name = "virtio-pci", .id_table = virtio_pci_id_table, @@ -596,6 +625,7 @@ static struct pci_driver virtio_pci_driver = { #ifdef CONFIG_PM_SLEEP .driver.pm = &virtio_pci_pm_ops, #endif + .sriov_configure = virtio_pci_sriov_configure, }; module_pci_driver(virtio_pci_driver); diff --git a/drivers/virtio/virtio_pci_modern.c b/drivers/virtio/virtio_pci_modern.c index 2555d80f6eec..07571daccfec 100644 --- a/drivers/virtio/virtio_pci_modern.c +++ b/drivers/virtio/virtio_pc...