aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Sébastien Pédron <dumbbell@FreeBSD.org>2026-01-07 21:18:38 +0000
committerJean-Sébastien Pédron <dumbbell@FreeBSD.org>2026-01-07 22:39:04 +0000
commit6c0bcd15e4782ff2e23119a37396d693d09c695d (patch)
tree3d952dddc8b3d011f8b1fc6f638a5519f4f2e712
parent10c6f1f627cd4267f9b95f60a9a30e4609566f8a (diff)
-rw-r--r--sys/compat/linuxkpi/common/include/linux/bitops.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/sys/compat/linuxkpi/common/include/linux/bitops.h b/sys/compat/linuxkpi/common/include/linux/bitops.h
index 969b5e8245e7..ebe9aa120094 100644
--- a/sys/compat/linuxkpi/common/include/linux/bitops.h
+++ b/sys/compat/linuxkpi/common/include/linux/bitops.h
@@ -443,4 +443,10 @@ rol64(uint64_t word, unsigned int shift)
return ((word << (shift & 63)) | (word >> ((-shift) & 63)));
}
+static inline uint32_t
+rol32(uint32_t word, unsigned int shift)
+{
+ return ((word << (shift & 31)) | (word >> ((-shift) & 31)));
+}
+
#endif /* _LINUXKPI_LINUX_BITOPS_H_ */