sar: update the driver of aw9610x to v0.9.3

The firmware of aw96103 and aw96105 is same,
remove the firmware vesion check for the compatibility.

Change-Id: Ie460a853836da3de88d35066c0b5a5d90f2002f0
Signed-off-by: zhangh12 <zhangh12@motorola.com>
Reviewed-on: https://gerrit.mot.com/2189877
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
This commit is contained in:
zhangh12 2022-02-14 15:47:15 +08:00 • committed by Hong Zhang
commit cd79aa00d9

View file

@ -40,7 +40,7 @@
#include "base.h"
#define AW9610X_I2C_NAME "aw9610x_sar"
#define AW9610X_DRIVER_VERSION "v0.1.9"
#define AW9610X_DRIVER_VERSION "v0.1.9.3"
#define AW_READ_CHIPID_RETRIES (5)
#define AW_I2C_RETRIES (5)
@ -692,15 +692,6 @@ aw9610x_cfg_all_loaded(const struct firmware *cont, void *context)
return;
}
ret = strcmp(aw9610x->chip_name, aw_bin->header_info[0].chip_type);
if (ret != 0) {
LOG_ERR("chip name(%s) incompatible with chip type(%s)",aw9610x->chip_name, aw_bin->header_info[0].chip_type);
kfree(aw_bin);
release_firmware(cont);
return;
}
aw9610x_bin_valid_loaded(aw9610x, aw_bin);
kfree(aw_bin);
release_firmware(cont);
@ -773,8 +764,6 @@ static int32_t aw9610x_init_irq_handle(struct aw9610x *aw9610x)
{
uint8_t cnt = 20;
uint32_t reg_data;
uint32_t trim0 = 0;
uint32_t trim1 = 0;
LOG_DBG("enter");
@ -782,12 +771,6 @@ static int32_t aw9610x_init_irq_handle(struct aw9610x *aw9610x)
aw9610x_i2c_read(aw9610x, REG_HOSTIRQSRC, &reg_data);
aw9610x->first_irq_flag = reg_data & 0x01;
if (aw9610x->first_irq_flag == 1) {
aw9610x_i2c_read(aw9610x, REG_EEDA0, &trim0);
aw9610x_i2c_read(aw9610x, REG_EEDA1, &trim1);
if ((trim0 + trim1) == 0) {
LOG_ERR("aw9610x trim error");
return -AW_TRIM_ERROR;
}
LOG_DBG("cnt = %d", cnt);
return AW_SAR_SUCCESS;
}
@ -1790,7 +1773,7 @@ static int32_t aw9610x_parse_dt(struct device *dev, struct aw9610x *aw9610x,
return -AW_MULTIPLE_SAR_FAILED;
} else {
LOG_INFO("sar num = %d", aw9610x->sar_num);
}
}
val = of_property_read_u32(np, "aw9610x,channel_number", &aw9610x->aw_channel_number);
if (val != 0) {
LOG_ERR("aw_channel_number failed!");
@ -1966,7 +1949,7 @@ static int32_t aw9610x_version_init(struct aw9610x *aw9610x)
aw9610x->chip_name[8] = '\0';
LOG_INFO("the IC is = %s", aw9610x->chip_name);
LOG_INFO("REG_FIRMVERSION = 0x%x", firmvers);
return AW_SAR_SUCCESS;
}