Subject: Re: [Patch RFC 01/10 v2] mlx4_en: mlx4_en header file

From: Roland Dreier <[email-masked]>
Date: Wed, 20 Aug 2008 09:46:00 -0700

> +enum {
 > +	MLX4_EN_FLAG_MSI_X      = 1 << 1,
 > +	MLX4_EN_FLAG_HIGH_DMA   = 1 << 2,
 > +	MLX4_EN_FLAG_FW_RUNNING = 1 << 3
 > +};

I can't find anywhere that any of these flags are used?

 > +#ifdef MLX4_EN_PREFETCH
 > +	#define PREFETCH(x)	prefetch(x)
 > +#else
 > +	#define PREFETCH(x)	do {} while (0)
 > +#endif

Probably better to figure out if you want to prefetch or not rather than
having this compile-time option.  Probably not, given that HW
prefetchers keep getting better.

 > +#define ROUNDUP_LOG2(x)		ilog2(roundup_pow_of_two(x))

<linux/log2.h> calls this order_base_2()

 > +#define XNOR(x, y)		(!(x) == !(y))

I think I said this before, but given that you only use this once, it
would be clearer to just open-code it there.

 - R.