[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20140319.140752.701088587181980100.davem@davemloft.net>
Date: Wed, 19 Mar 2014 14:07:52 -0400 (EDT)
From: David Miller <davem@...emloft.net>
To: jeffrey.t.kirsher@...el.com
Cc: mitch.a.williams@...el.com, netdev@...r.kernel.org,
gospo@...hat.com, sassmann@...hat.com, catherine.sullivan@...el.com
Subject: Re: [net-next v2 02/15] i40evf: correctly program RSS HLUT table
From: Jeff Kirsher <jeffrey.t.kirsher@...el.com>
Date: Tue, 18 Mar 2014 20:42:00 -0700
> +#define NEXT_QUEUE(_j) (++_j >= adapter->vsi_res->num_queue_pairs ? _j = 0 : _j)
I would strong recommend breaking the increment out of the test
and using a function rather than a macro:
static int next_queue(struct i40evf_adapter *adapter, int j)
{
j += 1;
return j >= adapter->vsi_res->num_queue_pairs ? 0 : j;
}
..
j = next_queue(adapter, j);
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists