diff options
author | Hans Verkuil <hverkuil-cisco@xs4all.nl> | 2021-01-20 10:27:08 +0100 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+huawei@kernel.org> | 2021-01-27 08:39:30 +0100 |
commit | 5320f4c1fb88cb68320e36e70c05ce52ed3b0927 (patch) | |
tree | b36089f6c801fb2742667adffc460ae7f7df5e79 /drivers/media | |
parent | 7be37332ecfd45a38ea34caa016e066b44bc8115 (diff) |
media: i2c/ov02a10.c: add cast to fix type mismatch
By adding this cast '(__force __le16)' this sparse warning
is fixed:
drivers/media/i2c/ov02a10.c:391:19: warning: cast to restricted __le16
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/i2c/ov02a10.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/i2c/ov02a10.c b/drivers/media/i2c/ov02a10.c index 8683ffd3287a..60b4bc645334 100644 --- a/drivers/media/i2c/ov02a10.c +++ b/drivers/media/i2c/ov02a10.c @@ -388,7 +388,7 @@ static int ov02a10_check_sensor_id(struct ov02a10 *ov02a10) if (ret < 0) return ret; - chip_id = le16_to_cpu(ret); + chip_id = le16_to_cpu((__force __le16)ret); if ((chip_id & OV02A10_ID_MASK) != OV02A10_ID) { dev_err(&client->dev, "unexpected sensor id(0x%04x)\n", chip_id); |