diff options
author | Bjoern A. Zeeb <bz@FreeBSD.org> | 2022-02-09 11:43:33 +0000 |
---|---|---|
committer | Bjoern A. Zeeb <bz@FreeBSD.org> | 2022-02-14 00:12:09 +0000 |
commit | d17b78aa142d7c63490c7a2c3f202ef99fffad70 (patch) | |
tree | a1e7e6be49c986fcb2783637ec5ad7685425d694 | |
parent | 2e818fbcfc03f9416593d5fe5bc860c1829f5366 (diff) | |
download | src-d17b78aa142d7c63490c7a2c3f202ef99fffad70.tar.gz src-d17b78aa142d7c63490c7a2c3f202ef99fffad70.zip |
LinuxKPI: add __ffs64()
Add __ffs64() to linux/bitops.h needed by a driver.
Reviewed by: hselasky
MFC after: 3 days
Differential Revision: https://reviews.freebsd.org/D34225
-rw-r--r-- | sys/compat/linuxkpi/common/include/linux/bitops.h | 6 |
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 262e6b9b110f..b6c54b2e6858 100644 --- a/sys/compat/linuxkpi/common/include/linux/bitops.h +++ b/sys/compat/linuxkpi/common/include/linux/bitops.h @@ -86,6 +86,12 @@ __ffsl(long mask) return (ffsl(mask) - 1); } +static inline unsigned long +__ffs64(uint64_t mask) +{ + return (ffsll(mask) - 1); +} + static inline int __flsl(long mask) { |