]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/net/mlx4/main.c
mlx4_core: Fix warning from min()
[linux-2.6-omap-h63xx.git] / drivers / net / mlx4 / main.c
index 710c79e7a2db244b567b485db51abf0978f04253..6ef2490d5c3e11e3327d88c5ddcfd7a3a2328826 100644 (file)
@@ -912,8 +912,8 @@ static void mlx4_enable_msi_x(struct mlx4_dev *dev)
        int i;
 
        if (msi_x) {
-               nreq = min(dev->caps.num_eqs - dev->caps.reserved_eqs,
-                          num_possible_cpus() + 1);
+               nreq = min_t(int, dev->caps.num_eqs - dev->caps.reserved_eqs,
+                            num_possible_cpus() + 1);
                entries = kcalloc(nreq, sizeof *entries, GFP_KERNEL);
                if (!entries)
                        goto no_msi;