]> git.neil.brown.name Git - md.git/commitdiff
sfc: constify pci_error_handlers structures
authorJulia Lawall <julia.lawall@lip6.fr>
Sat, 14 Nov 2015 10:06:57 +0000 (11:06 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 16 Nov 2015 20:07:29 +0000 (15:07 -0500)
This pci_error_handlers structure is never modified, like all the other
pci_error_handlers structures, so declare it as const.

Done with the help of Coccinelle.

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/sfc/efx.c

index d288f1c928de611455e44b515972b172340e4686..a3c42a376741f9c86179ca0fae5889203b9f16d5 100644 (file)
@@ -3422,7 +3422,7 @@ out:
  * with our request for slot reset the mmio_enabled callback will never be
  * called, and the link_reset callback is not used by AER or EEH mechanisms.
  */
-static struct pci_error_handlers efx_err_handlers = {
+static const struct pci_error_handlers efx_err_handlers = {
        .error_detected = efx_io_error_detected,
        .slot_reset     = efx_io_slot_reset,
        .resume         = efx_io_resume,