]> git.hungrycats.org Git - linux/commit
[PATCH] Remove redundant AND from swp_type()
authorMarcelo Tosatti <marcelo.tosatti@cyclades.com>
Wed, 20 Oct 2004 01:40:03 +0000 (18:40 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Wed, 20 Oct 2004 01:40:03 +0000 (18:40 -0700)
commit6902800445f4bfd224e82c7c3df74e48e925c001
tree7995103d0f1ad923c1937efee90fa7f948676a14
parent66ee38629134735537adb9c1a2fef83b418656f6
[PATCH] Remove redundant AND from swp_type()

There is a useless AND in swp_type() function.

We just shifted right SWP_TYPE_SHIFT() bits the value from the swp_entry_t,
and then we AND it with "(1 << 5) - 1" (which is a mask corresponding to
the number of bits used by "type").

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
include/linux/swapops.h