aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/crypto/cavium/nitrox/nitrox_main.c
diff options
context:
space:
mode:
authorHerbert Xu <herbert@gondor.apana.org.au>2020-11-06 17:53:52 +1100
committerHerbert Xu <herbert@gondor.apana.org.au>2020-11-13 20:38:45 +1100
commitcd078cb6a0f2e360b073b34f78a53b9410fa3e7a (patch)
tree9070937bb3e44c6f6f4b7d4f59349f7b328e13b9 /drivers/crypto/cavium/nitrox/nitrox_main.c
parentcrypto: qat - replace pci with PCI in comments (diff)
downloadlinux-dev-cd078cb6a0f2e360b073b34f78a53b9410fa3e7a.tar.xz
linux-dev-cd078cb6a0f2e360b073b34f78a53b9410fa3e7a.zip
crypto: cavium/nitrox - Fix sparse warnings
This patch fixes all the sparse warnings in cavium/nitrox: - Fix endianness warnings by adding the correct markers to unions. - Add missing header inclusions for prototypes. - Move nitrox_sriov_configure prototype into the isr header file. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/cavium/nitrox/nitrox_main.c')
-rw-r--r--drivers/crypto/cavium/nitrox/nitrox_main.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/drivers/crypto/cavium/nitrox/nitrox_main.c b/drivers/crypto/cavium/nitrox/nitrox_main.c
index 9d14be97e381..facc8e6bc580 100644
--- a/drivers/crypto/cavium/nitrox/nitrox_main.c
+++ b/drivers/crypto/cavium/nitrox/nitrox_main.c
@@ -49,15 +49,6 @@ static unsigned int qlen = DEFAULT_CMD_QLEN;
module_param(qlen, uint, 0644);
MODULE_PARM_DESC(qlen, "Command queue length - default 2048");
-#ifdef CONFIG_PCI_IOV
-int nitrox_sriov_configure(struct pci_dev *pdev, int num_vfs);
-#else
-int nitrox_sriov_configure(struct pci_dev *pdev, int num_vfs)
-{
- return 0;
-}
-#endif
-
/**
* struct ucode - Firmware Header
* @id: microcode ID
@@ -555,10 +546,8 @@ static void nitrox_remove(struct pci_dev *pdev)
nitrox_remove_from_devlist(ndev);
-#ifdef CONFIG_PCI_IOV
/* disable SR-IOV */
nitrox_sriov_configure(pdev, 0);
-#endif
nitrox_crypto_unregister();
nitrox_debugfs_exit(ndev);
nitrox_pf_sw_cleanup(ndev);
@@ -584,9 +573,7 @@ static struct pci_driver nitrox_driver = {
.probe = nitrox_probe,
.remove = nitrox_remove,
.shutdown = nitrox_shutdown,
-#ifdef CONFIG_PCI_IOV
.sriov_configure = nitrox_sriov_configure,
-#endif
};
module_pci_driver(nitrox_driver);