Removes useless (flags | ) KASSERT. The ^ one that actually

does what we want.

Submitted by:	Li Xin delphij@delphij.net
Reviewed by:	rrs
Approved by:	gnn
This commit is contained in:
rrs 2007-01-16 11:40:55 +00:00
parent 088287aea8
commit e614960c33

View File

@ -371,14 +371,9 @@ hashinit_flags(int elements, struct malloc_type *type, u_long *hashmask,
if (elements <= 0)
panic("hashinit: bad elements");
/* Check for valid flags. */
KASSERT((flags | (HASH_WAITOK | HASH_NOWAIT)) ==
(HASH_WAITOK | HASH_NOWAIT),
("Bad flags (0x%x) passed to hashinit_flags", flags));
/* Exactly one of HASH_WAITOK and HASH_NOWAIT must be set. */
KASSERT((flags & HASH_WAITOK) ^ (flags & HASH_NOWAIT),
("Both WAITOK and NOWAIT passed to hashinit_flags"));
("Bad flags (0x%x) passed to hashinit_flags", flags));
for (hashsize = 1; hashsize <= elements; hashsize <<= 1)
continue;