Add qlcnic prefix to qlcnic driver module parameters.
Unified · Split
| @@ -34,21 +34,21 @@ static int qlcnic_mac_learn; · 33 unmodified lines | ||
| 34 | 34 | module_param(qlcnic_mac_learn, int, 0444); |
| 35 | 35 | MODULE_PARM_DESC(qlcnic_mac_learn, "Mac Filter (0=disabled, 1=enabled)"); |
| 36 | 36 | |
| 37 | −static int use_msi = 1; | |
| 38 | −module_param(use_msi, int, 0444); | |
| 37 | +static int qlcnic_use_msi = 1; | |
| 39 | 38 | MODULE_PARM_DESC(use_msi, "MSI interrupt (0=disabled, 1=enabled"); |
| 39 | +module_param_named(use_msi, qlcnic_use_msi, int, 0444); | |
| 40 | 40 | |
| 41 | −static int use_msi_x = 1; | |
| 42 | −module_param(use_msi_x, int, 0444); | |
| 41 | +static int qlcnic_use_msi_x = 1; | |
| 43 | 42 | MODULE_PARM_DESC(use_msi_x, "MSI-X interrupt (0=disabled, 1=enabled"); |
| 43 | +module_param_named(use_msi_x, qlcnic_use_msi_x, int, 0444); | |
| 44 | 44 | |
| 45 | −static int auto_fw_reset = 1; | |
| 46 | −module_param(auto_fw_reset, int, 0644); | |
| 45 | +static int qlcnic_auto_fw_reset = 1; | |
| 47 | 46 | MODULE_PARM_DESC(auto_fw_reset, "Auto firmware reset (0=disabled, 1=enabled"); |
| 47 | +module_param_named(auto_fw_reset, qlcnic_auto_fw_reset, int, 0644); | |
| 48 | 48 | |
| 49 | −static int load_fw_file; | |
| 50 | −module_param(load_fw_file, int, 0444); | |
| 49 | +static int qlcnic_load_fw_file; | |
| 51 | 50 | MODULE_PARM_DESC(load_fw_file, "Load firmware from (0=flash, 1=file"); |
| 51 | +module_param_named(load_fw_file, qlcnic_load_fw_file, int, 0444); | |
| 52 | 52 | |
| 53 | 53 | static int qlcnic_config_npars; |
| 54 | 54 | module_param(qlcnic_config_npars, int, 0444); |
| @@ -317,7 +317,7 @@ static void qlcnic_enable_msi_legacy(struct qlcnic_adapter *adapter) · 262 unmodified lines | ||
| 317 | 317 | struct qlcnic_hardware_context *ahw = adapter->ahw; |
| 318 | 318 | struct pci_dev *pdev = adapter->pdev; |
| 319 | 319 | |
| 320 | − if (use_msi && !pci_enable_msi(pdev)) { | |
| 320 | + if (qlcnic_use_msi && !pci_enable_msi(pdev)) { | |
| 321 | 321 | adapter->flags |= QLCNIC_MSI_ENABLED; |
| 322 | 322 | offset = msi_tgt_status[adapter->ahw->pci_func]; |
| 323 | 323 | adapter->tgt_status_reg = qlcnic_get_ioaddr(adapter->ahw, |
| @@ -631,7 +631,7 @@ qlcnic_check_options(struct qlcnic_adapter *adapter) · 307 unmodified lines | ||
| 631 | 631 | adapter->max_rxd = MAX_RCV_DESCRIPTORS_1G; |
| 632 | 632 | } |
| 633 | 633 | |
| 634 | − adapter->ahw->msix_supported = !!use_msi_x; | |
| 634 | + adapter->ahw->msix_supported = !!qlcnic_use_msi_x; | |
| 635 | 635 | |
| 636 | 636 | adapter->num_txd = MAX_CMD_DESCRIPTORS; |
| 637 | 637 | |
| @@ -961,7 +961,7 @@ qlcnic_start_firmware(struct qlcnic_adapter *adapter) · 323 unmodified lines | ||
| 961 | 961 | else if (!err) |
| 962 | 962 | goto check_fw_status; |
| 963 | 963 | |
| 964 | − if (load_fw_file) | |
| 964 | + if (qlcnic_load_fw_file) | |
| 965 | 965 | qlcnic_request_firmware(adapter); |
| 966 | 966 | else { |
| 967 | 967 | err = qlcnic_check_flash_fw_ver(adapter); |
| @@ -2558,7 +2558,7 @@ qlcnic_check_health(struct qlcnic_adapter *adapter) · 1590 unmodified lines | ||
| 2558 | 2558 | if (adapter->need_fw_reset) |
| 2559 | 2559 | goto detach; |
| 2560 | 2560 | |
| 2561 | − if (adapter->ahw->reset_context && auto_fw_reset) { | |
| 2561 | + if (adapter->ahw->reset_context && qlcnic_auto_fw_reset) { | |
| 2562 | 2562 | qlcnic_reset_hw_context(adapter); |
| 2563 | 2563 | adapter->netdev->trans_start = jiffies; |
| 2564 | 2564 | } |
| @@ -2573,7 +2573,7 @@ qlcnic_check_health(struct qlcnic_adapter *adapter) · 8 unmodified lines | ||
| 2573 | 2573 | |
| 2574 | 2574 | qlcnic_dev_request_reset(adapter); |
| 2575 | 2575 | |
| 2576 | − if (auto_fw_reset) | |
| 2576 | + if (qlcnic_auto_fw_reset) | |
| 2577 | 2577 | clear_bit(__QLCNIC_FW_ATTACHED, &adapter->state); |
| 2578 | 2578 | |
| 2579 | 2579 | dev_err(&adapter->pdev->dev, "firmware hang detected\n"); |
| @@ -2598,8 +2598,8 @@ detach: · 18 unmodified lines | ||
| 2598 | 2598 | adapter->dev_state = (state == QLCNIC_DEV_NEED_QUISCENT) ? state : |
| 2599 | 2599 | QLCNIC_DEV_NEED_RESET; |
| 2600 | 2600 | |
| 2601 | − if (auto_fw_reset && | |
| 2602 | − !test_and_set_bit(__QLCNIC_RESETTING, &adapter->state)) { | |
| 2601 | + if (qlcnic_auto_fw_reset && !test_and_set_bit(__QLCNIC_RESETTING, | |
| 2602 | + &adapter->state)) { | |
| 2603 | 2603 | |
| 2604 | 2604 | qlcnic_schedule_work(adapter, qlcnic_detach_work, 0); |
| 2605 | 2605 | QLCDB(adapter, DRV, "fw recovery scheduled.\n"); |
| @@ -2784,7 +2784,7 @@ qlcnicvf_start_firmware(struct qlcnic_adapter *adapter) · 178 unmodified lines | ||
| 2784 | 2784 | |
| 2785 | 2785 | int qlcnic_validate_max_rss(struct net_device *netdev, u8 max_hw, u8 val) |
| 2786 | 2786 | { |
| 2787 | − if (!use_msi_x && !use_msi) { | |
| 2787 | + if (!qlcnic_use_msi_x && !qlcnic_use_msi) { | |
| 2788 | 2788 | netdev_info(netdev, "no msix or msi support, hence no rss\n"); |
| 2789 | 2789 | return -EINVAL; |
| 2790 | 2790 | } |