PCI / PM: constify pci_platform_pm_ops structure
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> Acked-by: Bjorn Helgaas <bhelgaas@google.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:

committed by
Rafael J. Wysocki

parent
527e9316f8
commit
299f2ffed3
@@ -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)
|
||||
|
Reference in New Issue
Block a user