lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 4 Nov 2019 11:32:21 +0100
From:   "Rafael J. Wysocki" <rafael@...nel.org>
To:     Bjorn Helgaas <helgaas@...nel.org>
Cc:     Linux PCI <linux-pci@...r.kernel.org>,
        "Rafael J . Wysocki" <rafael.j.wysocki@...el.com>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Linux PM <linux-pm@...r.kernel.org>,
        Bjorn Helgaas <bhelgaas@...gle.com>,
        Stefano Stabellini <sstabellini@...nel.org>,
        KarimAllah Ahmed <karahmed@...zon.de>
Subject: Re: [PATCH 4/6] xen-platform: Convert to generic power management

On Fri, Nov 1, 2019 at 9:46 PM Bjorn Helgaas <helgaas@...nel.org> wrote:
>
> From: Bjorn Helgaas <bhelgaas@...gle.com>
>
> Convert xen-platform from the legacy PCI power management callbacks to the
> generic operations.  This is one step towards removing support for the
> legacy PCI callbacks.
>
> The generic .resume_noirq() operation is called by pci_pm_resume_noirq() at
> the same point the legacy PCI .resume_early() callback was, so this patch
> should not change the xen-platform behavior.
>
> Signed-off-by: Bjorn Helgaas <bhelgaas@...gle.com>
> Cc: Stefano Stabellini <sstabellini@...nel.org>
> Cc: KarimAllah Ahmed <karahmed@...zon.de>

Good idea:

Acked-by: Rafael J. Wysocki <rafael.j.wysocki@...el.com>

> ---
>  drivers/xen/platform-pci.c | 10 +++++++---
>  1 file changed, 7 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/xen/platform-pci.c b/drivers/xen/platform-pci.c
> index 5e30602fdbad..e06e8769eb84 100644
> --- a/drivers/xen/platform-pci.c
> +++ b/drivers/xen/platform-pci.c
> @@ -168,13 +168,17 @@ static const struct pci_device_id platform_pci_tbl[] = {
>         {0,}
>  };
>
> +static struct dev_pm_ops platform_pm_ops = {
> +       .resume_noirq =   platform_pci_resume,
> +};
> +
>  static struct pci_driver platform_driver = {
>         .name =           DRV_NAME,
>         .probe =          platform_pci_probe,
>         .id_table =       platform_pci_tbl,
> -#ifdef CONFIG_PM
> -       .resume_early =   platform_pci_resume,
> -#endif
> +       .driver = {
> +               .pm =     &platform_pm_ops,
> +       },
>  };
>
>  builtin_pci_driver(platform_driver);
> --
> 2.24.0.rc1.363.gb1bccd3e3d-goog
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ