drivers: sensor: max17055: Fix compile error with clang

Since we are writing a register it makes more sense for the type
to be unsigned.  This hopefully address a compile warning we get
with clang:

error: implicit conversion from 'int' to 'int16_t' (aka 'short')
changes value from 32768 to -32768 [-Werror,-Wconstant-conversion]

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
Kumar Gala 2021-06-18 13:10:49 -05:00 committed by Kumar Gala
commit deb689f0f9

View file

@ -42,7 +42,7 @@ static int max17055_reg_read(struct max17055_data *priv, int reg_addr,
}
static int max17055_reg_write(struct max17055_data *priv, int reg_addr,
int16_t val)
uint16_t val)
{
uint8_t i2c_data[2];