lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 20 Nov 2014 23:55:54 -0800
From:	Joe Perches <>
To:	Hariprasad Shenai <>
Subject: Re: [PATCH net-next 1/5] RDMA/cxgb4: Cleanup Filter related
 macros/register defines

On Fri, 2014-11-21 at 12:52 +0530, Hariprasad Shenai wrote:
> This patch cleanups all filter related macros/register defines that are defined
> in t4fw_api.h and the affected files.

Is there any real value in the FW_FILTER_WR_ prefix?
Does it need to be so long?

Perhaps it'd be nicer to read if
_S was _SHIFT
_M was _MASK
_V was whatever it's supposed to represent (_SET?)
_G was _GET

> +#define FW_FILTER_WR_TID_S      12
> +#define FW_FILTER_WR_TID_M      0xfffff
> +#define FW_FILTER_WR_TID_V(x)   ((x) << FW_FILTER_WR_TID_S)
> +#define FW_FILTER_WR_TID_G(x)   \

Why aren't the _V defines masked then shifted?

#define FW_FILTER_WR_<foo>_V(x)				\
	(((x) & FW_FILTER_<foo>_M) << FW_FILTER_<foo>_S)

To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to
More majordomo info at

Powered by blists - more mailing lists