power: supply: max17040: Fix ptr to enum cast
clang complains about casting pointers to smaller enum types. Reported-by: kernel test robot <lkp@intel.com> Signed-off-by: Iskren Chernev <iskren.chernev@gmail.com> Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
This commit is contained in:
committed by
Sebastian Reichel
parent
d4fbca833b
commit
7f977e6437
@@ -247,7 +247,7 @@ static int max17040_get_of_data(struct max17040_chip *chip)
|
|||||||
{
|
{
|
||||||
struct device *dev = &chip->client->dev;
|
struct device *dev = &chip->client->dev;
|
||||||
struct chip_data *data = &max17040_family[
|
struct chip_data *data = &max17040_family[
|
||||||
(enum chip_id) of_device_get_match_data(dev)];
|
(uintptr_t) of_device_get_match_data(dev)];
|
||||||
int rcomp_len;
|
int rcomp_len;
|
||||||
u8 rcomp[2];
|
u8 rcomp[2];
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user