mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 10:31:46 +09:00
media: i2c: imx586: fix check sensor id error
Signed-off-by: Yuefu Su <yuefu.su@rock-chips.com> Change-Id: I124a0134e813ea5a1b725d345ab9dc14cabedad7
This commit is contained in:
@@ -2309,7 +2309,7 @@ static int imx586_check_sensor_id(struct imx586 *imx586,
|
||||
ret |= imx586_read_reg(client, IMX586_REG_CHIP_ID_L,
|
||||
IMX586_REG_VALUE_08BIT, ®_L);
|
||||
id = ((reg_H << 8) & 0xff00) | (reg_L & 0xff);
|
||||
if (!(reg_H == (CHIP_ID >> 8) || reg_L == (CHIP_ID & 0xff))) {
|
||||
if (!(reg_H == (CHIP_ID >> 8) && reg_L == (CHIP_ID & 0xff))) {
|
||||
dev_err(dev, "Unexpected sensor id(%06x), ret(%d)\n", id, ret);
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user