Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mfd: ntxec: Change return type of ntxec_reg8 from __be16 to u16

Register values in NTXEC are big-endian on the I2C bus, but the regmap
subsystem handles the conversion between CPU-endian and big-endian data
internally. ntxec_reg8 should thus return u16, not __be16.

Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Jonathan Neuschäfer <j.neuschaefer@gmx.net>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Link: https://lore.kernel.org/r/20211218152553.744615-1-j.neuschaefer@gmx.net

authored by

Jonathan Neuschäfer and committed by
Lee Jones
b92e3016 7620ad0b

+1 -1
+1 -1
include/linux/mfd/ntxec.h
··· 26 26 * This convenience function converts an 8-bit value to 16-bit for use in the 27 27 * second kind of register. 28 28 */ 29 - static inline __be16 ntxec_reg8(u8 value) 29 + static inline u16 ntxec_reg8(u8 value) 30 30 { 31 31 return value << 8; 32 32 }