]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commitdiff
qlcnic: Fix sparse warnings.
authorRajesh Borundia <rajesh.borundia@qlogic.com>
Tue, 2 Apr 2013 05:34:42 +0000 (05:34 +0000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 2 Apr 2013 18:27:11 +0000 (14:27 -0400)
warning: 'pf_info.max_tx_ques' may be used uninitialized in this function
[-Wmaybe-uninitialized]

Signed-off-by: Rajesh Borundia <rajesh.borundia@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qlcnic/qlcnic_sriov_pf.c

index d6ac7dcef1e42d340b3ac30e769fa469173f478d..bed505606a2d31c36d0f64ff694a20f98a156da4 100644 (file)
@@ -156,6 +156,7 @@ static int qlcnic_sriov_get_pf_info(struct qlcnic_adapter *adapter,
        npar_info->max_local_ipv6_addrs = LSW(cmd.rsp.arg[8]);
        npar_info->max_remote_ipv6_addrs = MSW(cmd.rsp.arg[8]);
 
+       qlcnic_sriov_pf_set_ff_max_res(adapter, npar_info);
        dev_info(&adapter->pdev->dev,
                 "\n\ttotal_pf: %d,\n"
                 "\n\ttotal_rss_engines: %d max_vports: %d max_tx_ques %d,\n"
@@ -376,8 +377,6 @@ static int qlcnic_sriov_pf_init(struct qlcnic_adapter *adapter)
        if (err)
                goto delete_vport;
 
-       qlcnic_sriov_pf_set_ff_max_res(adapter, &pf_info);
-
        err = qlcnic_get_nic_info(adapter, &nic_info, func);
        if (err)
                goto delete_vport;