Commit df9d1e8a authored by Linus Torvalds's avatar Linus Torvalds

pci: avoid compiler warning in quirks.c

Introduced by commit 5b889bf2 ("PCI: Fix build if quirks are not
enabled"), which made the pci_dev_reset_methods[] array static and
'const', but didn't then change the code to match, and use a const
pointer when moving it to quirks.c.

Trivially fixed by just adding the required 'const' to the iterator
variable.
Reported-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
Cc: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent c03f6bfc
...@@ -2694,7 +2694,7 @@ static const struct pci_dev_reset_methods pci_dev_reset_methods[] = { ...@@ -2694,7 +2694,7 @@ static const struct pci_dev_reset_methods pci_dev_reset_methods[] = {
int pci_dev_specific_reset(struct pci_dev *dev, int probe) int pci_dev_specific_reset(struct pci_dev *dev, int probe)
{ {
struct pci_dev_reset_methods *i; const struct pci_dev_reset_methods *i;
for (i = pci_dev_reset_methods; i->reset; i++) { for (i = pci_dev_reset_methods; i->reset; i++) {
if ((i->vendor == dev->vendor || if ((i->vendor == dev->vendor ||
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment