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] [thread-next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.61.0612052238320.18570@yvahk01.tjqt.qr>
Date:	Tue, 5 Dec 2006 22:40:21 +0100 (MET)
From:	Jan Engelhardt <jengelh@...ux01.gwdg.de>
To:	"Josef 'Jeff' Sipek" <jsipek@...sunysb.edu>
cc:	linux-kernel@...r.kernel.org, torvalds@...l.org, akpm@...l.org,
	hch@...radead.org, viro@....linux.org.uk,
	linux-fsdevel@...r.kernel.org, mhalcrow@...ibm.com
Subject: Re: [PATCH 24/35] Unionfs: Readdir state



>+	/* Round it up to the next highest power of two. */
>+	mallocsize--;
>+	mallocsize |= mallocsize >> 1;
>+	mallocsize |= mallocsize >> 2;
>+	mallocsize |= mallocsize >> 4;
>+	mallocsize |= mallocsize >> 8;
>+	mallocsize |= mallocsize >> 16;
>+	mallocsize++;

Interesting idea how to do it. This could be made a kernel-wide function and
be used by other subsystems (they sure do have find-next-power-of-two too). But
that another time another patch.


	-`J'
-- 
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ