From: Bjorn Helgaas <helgaas@kernel.org>
To: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: Julia Lawall <Julia.Lawall@lip6.fr>,
Bjorn Helgaas <bhelgaas@google.com>,
linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org,
linux-pci@vger.kernel.org, linux-acpi@vger.kernel.org,
Len Brown <lenb@kernel.org>
Subject: Re: [PATCH] PCI: constify pci_platform_pm_ops structure
Date: Mon, 07 Dec 2015 16:06:49 +0000 [thread overview]
Message-ID: <20151207160649.GG7994@localhost> (raw)
In-Reply-To: <1556686.IXJIjFBvQx@vostro.rjw.lan>
On Mon, Dec 07, 2015 at 02:41:34AM +0100, Rafael J. Wysocki wrote:
> On Sunday, December 06, 2015 05:33:45 PM Julia Lawall wrote:
> > The pci_platform_pm_ops structure is never modified, so declare it as
> > const.
> >
> > Done with the help of Coccinelle.
> >
> > Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
>
> OK
>
> Bjorn, do you want me to handle this one?
Sure, sounds good to me.
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
> > ---
> > drivers/pci/pci-acpi.c | 2 +-
> > drivers/pci/pci.c | 4 ++--
> > drivers/pci/pci.h | 2 +-
> > 3 files changed, 4 insertions(+), 4 deletions(-)
> >
> > diff --git a/drivers/pci/pci-acpi.c b/drivers/pci/pci-acpi.c
> > index a32ba75..8400f80 100644
> > --- a/drivers/pci/pci-acpi.c
> > +++ b/drivers/pci/pci-acpi.c
> > @@ -529,7 +529,7 @@ static bool acpi_pci_need_resume(struct pci_dev *dev)
> > return !!adev->power.flags.dsw_present;
> > }
> >
> > -static struct pci_platform_pm_ops acpi_pci_platform_pm = {
> > +static const struct pci_platform_pm_ops acpi_pci_platform_pm = {
> > .is_manageable = acpi_pci_power_manageable,
> > .set_state = acpi_pci_set_power_state,
> > .choose_state = acpi_pci_choose_state,
> > diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
> > index 314db8c..d1a7105 100644
> > --- a/drivers/pci/pci.c
> > +++ b/drivers/pci/pci.c
> > @@ -527,9 +527,9 @@ static void pci_restore_bars(struct pci_dev *dev)
> > pci_update_resource(dev, i);
> > }
> >
> > -static struct pci_platform_pm_ops *pci_platform_pm;
> > +static const struct pci_platform_pm_ops *pci_platform_pm;
> >
> > -int pci_set_platform_pm(struct pci_platform_pm_ops *ops)
> > +int pci_set_platform_pm(const struct pci_platform_pm_ops *ops)
> > {
> > if (!ops->is_manageable || !ops->set_state || !ops->choose_state
> > || !ops->sleep_wake)
> > diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h
> > index d390fc1..f6f151a 100644
> > --- a/drivers/pci/pci.h
> > +++ b/drivers/pci/pci.h
> > @@ -68,7 +68,7 @@ struct pci_platform_pm_ops {
> > bool (*need_resume)(struct pci_dev *dev);
> > };
> >
> > -int pci_set_platform_pm(struct pci_platform_pm_ops *ops);
> > +int pci_set_platform_pm(const struct pci_platform_pm_ops *ops);
> > void pci_update_current_state(struct pci_dev *dev, pci_power_t state);
> > void pci_power_up(struct pci_dev *dev);
> > void pci_disable_enabled_device(struct pci_dev *dev);
> >
> > --
> > To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
> > the body of a message to majordomo@vger.kernel.org
> > More majordomo info at http://vger.kernel.org/majordomo-info.html
>
> --
> I speak only for myself.
> Rafael J. Wysocki, Intel Open Source Technology Center.
> --
> To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
WARNING: multiple messages have this Message-ID (diff)
From: Bjorn Helgaas <helgaas@kernel.org>
To: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: Julia Lawall <Julia.Lawall@lip6.fr>,
Bjorn Helgaas <bhelgaas@google.com>,
linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org,
linux-pci@vger.kernel.org, linux-acpi@vger.kernel.org,
Len Brown <lenb@kernel.org>
Subject: Re: [PATCH] PCI: constify pci_platform_pm_ops structure
Date: Mon, 7 Dec 2015 10:06:49 -0600 [thread overview]
Message-ID: <20151207160649.GG7994@localhost> (raw)
In-Reply-To: <1556686.IXJIjFBvQx@vostro.rjw.lan>
On Mon, Dec 07, 2015 at 02:41:34AM +0100, Rafael J. Wysocki wrote:
> On Sunday, December 06, 2015 05:33:45 PM Julia Lawall wrote:
> > The pci_platform_pm_ops structure is never modified, so declare it as
> > const.
> >
> > Done with the help of Coccinelle.
> >
> > Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
>
> OK
>
> Bjorn, do you want me to handle this one?
Sure, sounds good to me.
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
> > ---
> > drivers/pci/pci-acpi.c | 2 +-
> > drivers/pci/pci.c | 4 ++--
> > drivers/pci/pci.h | 2 +-
> > 3 files changed, 4 insertions(+), 4 deletions(-)
> >
> > diff --git a/drivers/pci/pci-acpi.c b/drivers/pci/pci-acpi.c
> > index a32ba75..8400f80 100644
> > --- a/drivers/pci/pci-acpi.c
> > +++ b/drivers/pci/pci-acpi.c
> > @@ -529,7 +529,7 @@ static bool acpi_pci_need_resume(struct pci_dev *dev)
> > return !!adev->power.flags.dsw_present;
> > }
> >
> > -static struct pci_platform_pm_ops acpi_pci_platform_pm = {
> > +static const struct pci_platform_pm_ops acpi_pci_platform_pm = {
> > .is_manageable = acpi_pci_power_manageable,
> > .set_state = acpi_pci_set_power_state,
> > .choose_state = acpi_pci_choose_state,
> > diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
> > index 314db8c..d1a7105 100644
> > --- a/drivers/pci/pci.c
> > +++ b/drivers/pci/pci.c
> > @@ -527,9 +527,9 @@ static void pci_restore_bars(struct pci_dev *dev)
> > pci_update_resource(dev, i);
> > }
> >
> > -static struct pci_platform_pm_ops *pci_platform_pm;
> > +static const struct pci_platform_pm_ops *pci_platform_pm;
> >
> > -int pci_set_platform_pm(struct pci_platform_pm_ops *ops)
> > +int pci_set_platform_pm(const struct pci_platform_pm_ops *ops)
> > {
> > if (!ops->is_manageable || !ops->set_state || !ops->choose_state
> > || !ops->sleep_wake)
> > diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h
> > index d390fc1..f6f151a 100644
> > --- a/drivers/pci/pci.h
> > +++ b/drivers/pci/pci.h
> > @@ -68,7 +68,7 @@ struct pci_platform_pm_ops {
> > bool (*need_resume)(struct pci_dev *dev);
> > };
> >
> > -int pci_set_platform_pm(struct pci_platform_pm_ops *ops);
> > +int pci_set_platform_pm(const struct pci_platform_pm_ops *ops);
> > void pci_update_current_state(struct pci_dev *dev, pci_power_t state);
> > void pci_power_up(struct pci_dev *dev);
> > void pci_disable_enabled_device(struct pci_dev *dev);
> >
> > --
> > To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
> > the body of a message to majordomo@vger.kernel.org
> > More majordomo info at http://vger.kernel.org/majordomo-info.html
>
> --
> I speak only for myself.
> Rafael J. Wysocki, Intel Open Source Technology Center.
> --
> To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2015-12-07 16:06 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-06 16:33 [PATCH] PCI: constify pci_platform_pm_ops structure Julia Lawall
2015-12-06 16:33 ` Julia Lawall
2015-12-07 1:41 ` Rafael J. Wysocki
2015-12-07 1:41 ` Rafael J. Wysocki
2015-12-07 16:06 ` Bjorn Helgaas [this message]
2015-12-07 16:06 ` Bjorn Helgaas
2015-12-09 0:51 ` Rafael J. Wysocki
2015-12-09 1:21 ` Rafael J. Wysocki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20151207160649.GG7994@localhost \
--to=helgaas@kernel.org \
--cc=Julia.Lawall@lip6.fr \
--cc=bhelgaas@google.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=rjw@rjwysocki.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.