From: Dan Williams Date: Sat, 26 Mar 2011 23:30:06 +0000 (-0700) Subject: isci: reorder init to cleanup unneeded declarations X-Git-Tag: upstream/snapshot3+hdmi~9737^2~1^2~191 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f942f32ea05eff727c41e1a1112cab305b836377;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git isci: reorder init to cleanup unneeded declarations Just move isci_pci_driver below the function definitions and delete the declarations. A couple other whitespace fixups, and unused symbol deletions. Reported-by: Christoph Hellwig Signed-off-by: Dan Williams --- diff --git a/drivers/scsi/isci/init.c b/drivers/scsi/isci/init.c index 1b04b9c..5e63ae6 100644 --- a/drivers/scsi/isci/init.c +++ b/drivers/scsi/isci/init.c @@ -84,23 +84,8 @@ static DEFINE_PCI_DEVICE_TABLE(isci_id_table) = { {} }; -struct isci_firmware *isci_firmware; - -static int __devinit isci_pci_probe( - struct pci_dev *pdev, - const struct pci_device_id *device_id_p); - -static void __devexit isci_pci_remove(struct pci_dev *pdev); - MODULE_DEVICE_TABLE(pci, isci_id_table); -static struct pci_driver isci_pci_driver = { - .name = DRV_NAME, - .id_table = isci_id_table, - .probe = isci_pci_probe, - .remove = __devexit_p(isci_pci_remove), -}; - /* linux isci specific settings */ #if defined(CONFIG_PBG_HBA_A0) @@ -339,7 +324,7 @@ static int num_controllers(struct pci_dev *pdev) */ resource_size_t scu_bar_size = pci_resource_len(pdev, SCI_SCU_BAR*2); resource_size_t smu_bar_size = pci_resource_len(pdev, SCI_SMU_BAR*2); - + if (scu_bar_size >= SCI_SCU_BAR_SIZE*SCI_MAX_CONTROLLERS && smu_bar_size >= SCI_SMU_BAR_SIZE*SCI_MAX_CONTROLLERS) return SCI_MAX_CONTROLLERS; @@ -484,7 +469,7 @@ static void check_si_rev(struct pci_dev *pdev) dev_info(&pdev->dev, "driver configured for %s silicon (rev: %d)\n", isci_si_rev == ISCI_SI_REVA0 ? "A0" : isci_si_rev == ISCI_SI_REVA2 ? "A2" : "B0", pdev->revision); - + } static int __devinit isci_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id) @@ -573,6 +558,13 @@ static void __devexit isci_pci_remove(struct pci_dev *pdev) } } +static struct pci_driver isci_pci_driver = { + .name = DRV_NAME, + .id_table = isci_id_table, + .probe = isci_pci_probe, + .remove = __devexit_p(isci_pci_remove), +}; + static __init int isci_init(void) { int err;