[SCSI] lpfc 8.2.2 : Error messages and debugfs updates
[safe/jmp/linux-2.6] / drivers / scsi / lpfc / lpfc_init.c
index 350522c..07bd0dc 100644 (file)
@@ -1570,9 +1570,6 @@ lpfc_create_port(struct lpfc_hba *phba, int instance, struct fc_vport *fc_vport)
        if (error)
                goto out_put_shost;
 
-       if (!shost->shost_classdev.kobj.dentry)
-               goto out_put_shost;
-
        list_add_tail(&vport->listentry, &phba->port_list);
        return vport;
 
@@ -1720,7 +1717,7 @@ lpfc_pci_probe_one(struct pci_dev *pdev, const struct pci_device_id *pid)
        struct lpfc_iocbq *iocbq_entry = NULL, *iocbq_next = NULL;
        struct Scsi_Host  *shost = NULL;
        unsigned long bar0map_len, bar2map_len;
-       int error = -ENODEV, retval;
+       int error = -ENODEV;
        int i;
        uint16_t iotag;
 
@@ -1771,10 +1768,7 @@ lpfc_pci_probe_one(struct pci_dev *pdev, const struct pci_device_id *pid)
        phba->fabric_block_timer.data = (unsigned long) phba;
 
        pci_set_master(pdev);
-       retval = pci_set_mwi(pdev);
-       if (retval)
-               dev_printk(KERN_WARNING, &pdev->dev,
-                          "Warning: pci_set_mwi returned %d\n", retval);
+       pci_try_set_mwi(pdev);
 
        if (pci_set_dma_mask(phba->pcidev, DMA_64BIT_MASK) != 0)
                if (pci_set_dma_mask(phba->pcidev, DMA_32BIT_MASK) != 0)
@@ -1836,7 +1830,7 @@ lpfc_pci_probe_one(struct pci_dev *pdev, const struct pci_device_id *pid)
        /* Initialize and populate the iocb list per host.  */
        INIT_LIST_HEAD(&phba->lpfc_iocb_list);
        for (i = 0; i < LPFC_IOCB_LIST_CNT; i++) {
-               iocbq_entry = kmalloc(sizeof(struct lpfc_iocbq), GFP_KERNEL);
+               iocbq_entry = kzalloc(sizeof(struct lpfc_iocbq), GFP_KERNEL);
                if (iocbq_entry == NULL) {
                        printk(KERN_ERR "%s: only allocated %d iocbs of "
                                "expected %d count. Unloading driver.\n",
@@ -1845,7 +1839,6 @@ lpfc_pci_probe_one(struct pci_dev *pdev, const struct pci_device_id *pid)
                        goto out_free_iocbq;
                }
 
-               memset(iocbq_entry, 0, sizeof(struct lpfc_iocbq));
                iotag = lpfc_sli_next_iotag(phba, iocbq_entry);
                if (iotag == 0) {
                        kfree (iocbq_entry);