| .. | .. |
|---|
| 154 | 154 | /* |
|---|
| 155 | 155 | * csio_dfs_destroy - Destroys per-hw debugfs. |
|---|
| 156 | 156 | */ |
|---|
| 157 | | -static int |
|---|
| 157 | +static void |
|---|
| 158 | 158 | csio_dfs_destroy(struct csio_hw *hw) |
|---|
| 159 | 159 | { |
|---|
| 160 | | - if (hw->debugfs_root) |
|---|
| 161 | | - debugfs_remove_recursive(hw->debugfs_root); |
|---|
| 162 | | - |
|---|
| 163 | | - return 0; |
|---|
| 160 | + debugfs_remove_recursive(hw->debugfs_root); |
|---|
| 164 | 161 | } |
|---|
| 165 | 162 | |
|---|
| 166 | 163 | /* |
|---|
| 167 | 164 | * csio_dfs_init - Debug filesystem initialization for the module. |
|---|
| 168 | 165 | * |
|---|
| 169 | 166 | */ |
|---|
| 170 | | -static int |
|---|
| 167 | +static void |
|---|
| 171 | 168 | csio_dfs_init(void) |
|---|
| 172 | 169 | { |
|---|
| 173 | 170 | csio_debugfs_root = debugfs_create_dir(KBUILD_MODNAME, NULL); |
|---|
| 174 | | - if (!csio_debugfs_root) |
|---|
| 175 | | - pr_warn("Could not create debugfs entry, continuing\n"); |
|---|
| 176 | | - |
|---|
| 177 | | - return 0; |
|---|
| 178 | 171 | } |
|---|
| 179 | 172 | |
|---|
| 180 | 173 | /* |
|---|
| .. | .. |
|---|
| 210 | 203 | pci_set_master(pdev); |
|---|
| 211 | 204 | pci_try_set_mwi(pdev); |
|---|
| 212 | 205 | |
|---|
| 213 | | - if (!pci_set_dma_mask(pdev, DMA_BIT_MASK(64))) { |
|---|
| 214 | | - pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(64)); |
|---|
| 215 | | - } else if (!pci_set_dma_mask(pdev, DMA_BIT_MASK(32))) { |
|---|
| 216 | | - pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(32)); |
|---|
| 217 | | - } else { |
|---|
| 206 | + rv = dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(64)); |
|---|
| 207 | + if (rv) |
|---|
| 208 | + rv = dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32)); |
|---|
| 209 | + if (rv) { |
|---|
| 210 | + rv = -ENODEV; |
|---|
| 218 | 211 | dev_err(&pdev->dev, "No suitable DMA available.\n"); |
|---|
| 219 | 212 | goto err_release_regions; |
|---|
| 220 | 213 | } |
|---|
| .. | .. |
|---|
| 258 | 251 | csio_hw_exit_workers(struct csio_hw *hw) |
|---|
| 259 | 252 | { |
|---|
| 260 | 253 | cancel_work_sync(&hw->evtq_work); |
|---|
| 261 | | - flush_scheduled_work(); |
|---|
| 262 | 254 | } |
|---|
| 263 | 255 | |
|---|
| 264 | 256 | static int |
|---|
| .. | .. |
|---|
| 537 | 529 | goto err_free_hw; |
|---|
| 538 | 530 | |
|---|
| 539 | 531 | /* Get the start address of registers from BAR 0 */ |
|---|
| 540 | | - hw->regstart = ioremap_nocache(pci_resource_start(pdev, 0), |
|---|
| 532 | + hw->regstart = ioremap(pci_resource_start(pdev, 0), |
|---|
| 541 | 533 | pci_resource_len(pdev, 0)); |
|---|
| 542 | 534 | if (!hw->regstart) { |
|---|
| 543 | 535 | csio_err(hw, "Could not map BAR 0, regstart = %p\n", |
|---|
| .. | .. |
|---|
| 590 | 582 | * @hw: The HW module. |
|---|
| 591 | 583 | * @dev: The device associated with this invocation. |
|---|
| 592 | 584 | * @probe: Called from probe context or not? |
|---|
| 593 | | - * @os_pln: Parent lnode if any. |
|---|
| 585 | + * @pln: Parent lnode if any. |
|---|
| 594 | 586 | * |
|---|
| 595 | 587 | * Allocates lnode structure via scsi_host_alloc, initializes |
|---|
| 596 | 588 | * shost, initializes lnode module and registers with SCSI ML |
|---|
| .. | .. |
|---|
| 1102 | 1094 | pci_set_master(pdev); |
|---|
| 1103 | 1095 | pci_restore_state(pdev); |
|---|
| 1104 | 1096 | pci_save_state(pdev); |
|---|
| 1105 | | - pci_cleanup_aer_uncorrect_error_status(pdev); |
|---|
| 1106 | 1097 | |
|---|
| 1107 | 1098 | /* Bring HW s/m to ready state. |
|---|
| 1108 | 1099 | * but don't resume IOs. |
|---|