linux/security
Christian Göttsche 7969ba5776 selinux: simplify avtab slot calculation
Instead of dividing by 8 and then performing log2 by hand, use a more
readable calculation.

The behavior of rounddown_pow_of_two() for an input of 0 is undefined,
so handle that case and small values manually to achieve the same
results.

Signed-off-by: Christian Göttsche <cgzones@googlemail.com>
Reviewed-by: Stephen Smalley <stephen.smalley.work@gmail.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
2023-09-13 13:46:57 -04:00
..
2023-08-30 09:07:09 -07:00
2023-08-30 09:16:56 -07:00
2023-04-27 16:52:33 -07:00
2023-05-25 17:52:15 -04:00
2023-08-30 09:07:09 -07:00