diff options
author | Takashi Iwai <tiwai@suse.de> | 2015-10-23 06:56:56 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2015-10-23 06:56:56 +0200 |
commit | b9b6e4ac2da74995cb7ac9394854a5fd563014c2 (patch) | |
tree | 9a8db7b1f46d6542f9af2c87989cdafc3487a2c1 /arch/tile/include/asm/word-at-a-time.h | |
parent | d289619a219dd01e255d7b5e30f9171b25efea48 (diff) | |
parent | f69eccc4b248ce53b1b830034babd0a795d5763c (diff) |
Merge tag 'asoc-fix-v4.3-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linussound-4.3-rc7
ASoC: Fixes for v4.3
A bunch of driver fixes plus one core fix which fixes problems with
misreporting values from _SX controls following a recent refactoring.
This had gone unnoticed as such controls are quite rare.
Diffstat (limited to 'arch/tile/include/asm/word-at-a-time.h')
-rw-r--r-- | arch/tile/include/asm/word-at-a-time.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/arch/tile/include/asm/word-at-a-time.h b/arch/tile/include/asm/word-at-a-time.h index 9e5ce0d7b292..b66a693c2c34 100644 --- a/arch/tile/include/asm/word-at-a-time.h +++ b/arch/tile/include/asm/word-at-a-time.h @@ -6,7 +6,7 @@ struct word_at_a_time { /* unused */ }; #define WORD_AT_A_TIME_CONSTANTS {} -/* Generate 0x01 byte values for non-zero bytes using a SIMD instruction. */ +/* Generate 0x01 byte values for zero bytes using a SIMD instruction. */ static inline unsigned long has_zero(unsigned long val, unsigned long *data, const struct word_at_a_time *c) { @@ -33,4 +33,10 @@ static inline long find_zero(unsigned long mask) #endif } +#ifdef __BIG_ENDIAN +#define zero_bytemask(mask) (~1ul << (63 - __builtin_clzl(mask))) +#else +#define zero_bytemask(mask) ((2ul << __builtin_ctzl(mask)) - 1) +#endif + #endif /* _ASM_WORD_AT_A_TIME_H */ |