diff options
| author | Mitch Williams <mitch.a.williams@intel.com> | 2014-02-11 03:27:52 -0500 |
|---|---|---|
| committer | Jeff Kirsher <jeffrey.t.kirsher@intel.com> | 2014-03-19 20:17:20 -0400 |
| commit | 30a500e21831ec3fb050da3ab8bb4c6facf23ef0 (patch) | |
| tree | 1d05c750a6b7f13cf555905d99e53fee24772ffd | |
| parent | 96d477045388c03a03041c382f19e122046c0afd (diff) | |
i40evf: use min_t
Checkpatch complained in an earlier patch about using min(), but that
change would have been completely unrelated to the point of that patch.
So fix it here.
Change-ID: I2cd87b39cfd406850d283b88f259757a6bcd14cd
Signed-off-by: Mitch Williams <mitch.a.williams@intel.com>
Signed-off-by: Catherine Sullivan <catherine.sullivan@intel.com>
Tested-by: Sibai Li <sibai.li@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
| -rw-r--r-- | drivers/net/ethernet/intel/i40evf/i40evf_main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/intel/i40evf/i40evf_main.c b/drivers/net/ethernet/intel/i40evf/i40evf_main.c index ffda5657fe02..5575ee779497 100644 --- a/drivers/net/ethernet/intel/i40evf/i40evf_main.c +++ b/drivers/net/ethernet/intel/i40evf/i40evf_main.c | |||
| @@ -1140,8 +1140,8 @@ static int i40evf_set_interrupt_capability(struct i40evf_adapter *adapter) | |||
| 1140 | * than CPU's. So let's be conservative and only ask for | 1140 | * than CPU's. So let's be conservative and only ask for |
| 1141 | * (roughly) twice the number of vectors as there are CPU's. | 1141 | * (roughly) twice the number of vectors as there are CPU's. |
| 1142 | */ | 1142 | */ |
| 1143 | v_budget = min(pairs, (int)(num_online_cpus() * 2)) + NONQ_VECS; | 1143 | v_budget = min_t(int, pairs, (int)(num_online_cpus() * 2)) + NONQ_VECS; |
| 1144 | v_budget = min(v_budget, (int)adapter->vf_res->max_vectors); | 1144 | v_budget = min_t(int, v_budget, (int)adapter->vf_res->max_vectors); |
| 1145 | 1145 | ||
| 1146 | /* A failure in MSI-X entry allocation isn't fatal, but it does | 1146 | /* A failure in MSI-X entry allocation isn't fatal, but it does |
| 1147 | * mean we disable MSI-X capabilities of the adapter. | 1147 | * mean we disable MSI-X capabilities of the adapter. |
