mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-14 16:46:15 -04:00
msm: camera: eeprom: Correct EEPROM Read return
EEPROM Read using QUP I2C returns the number of bytes read from the EEPROM, While CCI/SPI returns zero value. Return Error only when if the value is less than zero. CRs-Fixed: 2617882 External Impact: No Change-Id: I9a9674366c10de4efce779f75dd36b293838c47b Signed-off-by: Shankar Ravi <rshankar@codeaurora.org>
This commit is contained in:
parent
5619d4e93e
commit
624a05a102
1 changed files with 2 additions and 2 deletions
|
|
@ -1,6 +1,6 @@
|
|||
// SPDX-License-Identifier: GPL-2.0-only
|
||||
/*
|
||||
* Copyright (c) 2017-2019, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2017-2020, The Linux Foundation. All rights reserved.
|
||||
*/
|
||||
|
||||
#include <linux/module.h>
|
||||
|
|
@ -108,7 +108,7 @@ static int cam_eeprom_read_memory(struct cam_eeprom_ctrl_t *e_ctrl,
|
|||
emap[j].mem.addr_type,
|
||||
emap[j].mem.data_type,
|
||||
emap[j].mem.valid_size);
|
||||
if (rc) {
|
||||
if (rc < 0) {
|
||||
CAM_ERR(CAM_EEPROM, "read failed rc %d",
|
||||
rc);
|
||||
return rc;
|
||||
|
|
|
|||
Loading…
Reference in a new issue