BIO_TYPE_MASK
mask = type & BIO_TYPE_MASK;
if (newval > BIO_TYPE_MASK)
for (i = id + 1; i <= BIO_TYPE_MASK; ++i) {