diff options
author | Charles Manning <cdhmanning@gmail.com> | 2010-11-30 14:00:00 +1300 |
---|---|---|
committer | Charles Manning <cdhmanning@gmail.com> | 2010-11-30 14:00:00 +1300 |
commit | acf9438692c78de0ca030e5408790572dbe06500 (patch) | |
tree | c79458eff5d0e7e224bb808744d2127fdcb07e35 /yportenv_single.h | |
parent | 03ddd91b1bd421a53d76ebdce7bc647299c8965d (diff) |
yaffs: Refactor bit counting code
For Linux kernel we use hweight8() and hweight32(). This allows
use of special bit-counting code instructions in processors that
do this.
The yaffs direct we now only use one set of code. There were two.
NB On x86 the yaffs hweight8 code is actually a lot faster
than the sofwtare implementation in Linux kernel.
Signed-off-by: Charles Manning <cdhmanning@gmail.com>
Diffstat (limited to 'yportenv_single.h')
-rw-r--r-- | yportenv_single.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/yportenv_single.h b/yportenv_single.h index 2eae429..8fd0da5 100644 --- a/yportenv_single.h +++ b/yportenv_single.h @@ -29,6 +29,7 @@ #include <linux/fs.h> #include <linux/stat.h> #include <linux/sort.h> +#include <linux/bitops.h> #define YCHAR char #define YUCHAR unsigned char |