lists.openwall.net   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] [day] [month] [year] [list]
Date:	Fri, 24 Aug 2007 04:35:40 +0200
From:	Richard Knutsson <ricknu-0@...dent.ltu.se>
To:	Jiri Slaby <jirislaby@...il.com>
CC:	Andrew Morton <akpm@...ux-foundation.org>,
	linux-kernel@...r.kernel.org, ram.vepa@...erion.com,
	santosh.rastapur@...erion.com, sivakumar.subramani@...erion.com,
	sreenivasa.honnur@...erion.com, netdev@...r.kernel.org
Subject: Re: [PATCH 4/9] s2io, rename BIT macro

Jiri Slaby wrote:
> s2io, rename BIT macro
>
> BIT macro will be global definiton of (1<<x)
>
> Signed-off-by: Jiri Slaby <jirislaby@...il.com>
>
> ---
>   
[snip]
>  			cnt++;
>  			if (cnt == 5)
> diff --git a/drivers/net/s2io.h b/drivers/net/s2io.h
> index 92983ee..448f899 100644
> --- a/drivers/net/s2io.h
> +++ b/drivers/net/s2io.h
> @@ -14,7 +14,7 @@
>  #define _S2IO_H
>  
>  #define TBD 0
> -#define BIT(loc)		(0x8000000000000000ULL >> (loc))
> +#define s2BIT(loc)		(0x8000000000000000ULL >> (loc))
>  #define vBIT(val, loc, sz)	(((u64)val) << (64-loc-sz))
>  #define INV(d)  ((d&0xff)<<24) | (((d>>8)&0xff)<<16) | (((d>>16)&0xff)<<8)| ((d>>24)&0xff)
>  
>   
Sorry for the late response, but would it not be better/easier to use 
BIT() instead (or a global #define LLBIT(nr)  (1ULL << (nr))) and just 
recalculate the values?

Richard Knutsson

-
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