Loading drivers/input/sensors/smi130/smi130_acc.c +6 −5 Original line number Diff line number Diff line Loading @@ -1325,7 +1325,7 @@ #define SMI_ACC2X2_SET_BITSLICE(regvar, bitname, val)\ ((regvar & ~bitname##__MSK) | ((val<<bitname##__POS)&bitname##__MSK)) #define CHECK_CHIP_ID_TIME_MAX 5 #define CHECK_CHIP_ID_TIME_MAX 1 #define SMI_ACC255_CHIP_ID 0XFA #define SMI_ACC250E_CHIP_ID 0XF9 #define SMI_ACC222E_CHIP_ID 0XF8 Loading @@ -1339,7 +1339,7 @@ #define MAX_FIFO_F_LEVEL 32 #define MAX_FIFO_F_BYTES 6 #define SMI_ACC_MAX_RETRY_I2C_XFER (100) #define SMI_ACC_MAX_RETRY_I2C_XFER (2) #ifdef CONFIG_DOUBLE_TAP #define DEFAULT_TAP_JUDGE_PERIOD 1000 /* default judge in 1 second */ Loading Loading @@ -1898,8 +1898,9 @@ static int smi130_acc_check_chip_id(struct i2c_client *client, while (read_count++ < CHECK_CHIP_ID_TIME_MAX) { if (smi130_acc_smbus_read_byte(client, SMI_ACC2X2_CHIP_ID_REG, &chip_id) < 0) { PERR("Bosch Sensortec Device not found\n\n" PERR("Bosch Sensortec Device not found\n" "i2c bus read error, read chip_id:%d\n", chip_id); err = -ENODEV; continue; } else { for (i = 0; i < smi130_acc_sensor_type_count; i++) { Loading @@ -1907,7 +1908,7 @@ static int smi130_acc_check_chip_id(struct i2c_client *client, data->sensor_type = sensor_type_map[i].sensor_type; data->chip_id = chip_id; PINFO("Bosch Sensortec Device detected,\n\n" PINFO("Bosch Sensortec Device detected\n" " HW IC name: %s\n", sensor_type_map[i].sensor_name); return err; Loading @@ -1917,7 +1918,7 @@ static int smi130_acc_check_chip_id(struct i2c_client *client, return err; else { if (read_count == CHECK_CHIP_ID_TIME_MAX) { PERR("Failed! Bosch Sensortec Device\n\n" PERR("Failed! Bosch Sensortec Device\n" " not found, mismatch chip_id:%d\n", chip_id); err = -ENODEV; Loading drivers/input/sensors/smi130/smi130_gyro_driver.c +2 −2 Original line number Diff line number Diff line Loading @@ -151,7 +151,7 @@ #define SENSOR_NAME "smi130_gyro" #define SMI130_GYRO_ENABLE_INT1 1 #define SENSOR_CHIP_ID_SMI_GYRO (0x0f) #define CHECK_CHIP_ID_TIME_MAX 5 #define CHECK_CHIP_ID_TIME_MAX 1 #define DRIVER_VERSION "0.0.53.0" #define SMI_GYRO_USE_FIFO 1 #define SMI_GYRO_USE_BASIC_I2C_FUNC 1 Loading @@ -163,7 +163,7 @@ #define SMI_GYRO_I2C_WRITE_DELAY_TIME 1 /* generic */ #define SMI_GYRO_MAX_RETRY_I2C_XFER (100) #define SMI_GYRO_MAX_RETRY_I2C_XFER (2) #define SMI_GYRO_MAX_RETRY_WAKEUP (5) #define SMI_GYRO_MAX_RETRY_WAIT_DRDY (100) Loading Loading
drivers/input/sensors/smi130/smi130_acc.c +6 −5 Original line number Diff line number Diff line Loading @@ -1325,7 +1325,7 @@ #define SMI_ACC2X2_SET_BITSLICE(regvar, bitname, val)\ ((regvar & ~bitname##__MSK) | ((val<<bitname##__POS)&bitname##__MSK)) #define CHECK_CHIP_ID_TIME_MAX 5 #define CHECK_CHIP_ID_TIME_MAX 1 #define SMI_ACC255_CHIP_ID 0XFA #define SMI_ACC250E_CHIP_ID 0XF9 #define SMI_ACC222E_CHIP_ID 0XF8 Loading @@ -1339,7 +1339,7 @@ #define MAX_FIFO_F_LEVEL 32 #define MAX_FIFO_F_BYTES 6 #define SMI_ACC_MAX_RETRY_I2C_XFER (100) #define SMI_ACC_MAX_RETRY_I2C_XFER (2) #ifdef CONFIG_DOUBLE_TAP #define DEFAULT_TAP_JUDGE_PERIOD 1000 /* default judge in 1 second */ Loading Loading @@ -1898,8 +1898,9 @@ static int smi130_acc_check_chip_id(struct i2c_client *client, while (read_count++ < CHECK_CHIP_ID_TIME_MAX) { if (smi130_acc_smbus_read_byte(client, SMI_ACC2X2_CHIP_ID_REG, &chip_id) < 0) { PERR("Bosch Sensortec Device not found\n\n" PERR("Bosch Sensortec Device not found\n" "i2c bus read error, read chip_id:%d\n", chip_id); err = -ENODEV; continue; } else { for (i = 0; i < smi130_acc_sensor_type_count; i++) { Loading @@ -1907,7 +1908,7 @@ static int smi130_acc_check_chip_id(struct i2c_client *client, data->sensor_type = sensor_type_map[i].sensor_type; data->chip_id = chip_id; PINFO("Bosch Sensortec Device detected,\n\n" PINFO("Bosch Sensortec Device detected\n" " HW IC name: %s\n", sensor_type_map[i].sensor_name); return err; Loading @@ -1917,7 +1918,7 @@ static int smi130_acc_check_chip_id(struct i2c_client *client, return err; else { if (read_count == CHECK_CHIP_ID_TIME_MAX) { PERR("Failed! Bosch Sensortec Device\n\n" PERR("Failed! Bosch Sensortec Device\n" " not found, mismatch chip_id:%d\n", chip_id); err = -ENODEV; Loading
drivers/input/sensors/smi130/smi130_gyro_driver.c +2 −2 Original line number Diff line number Diff line Loading @@ -151,7 +151,7 @@ #define SENSOR_NAME "smi130_gyro" #define SMI130_GYRO_ENABLE_INT1 1 #define SENSOR_CHIP_ID_SMI_GYRO (0x0f) #define CHECK_CHIP_ID_TIME_MAX 5 #define CHECK_CHIP_ID_TIME_MAX 1 #define DRIVER_VERSION "0.0.53.0" #define SMI_GYRO_USE_FIFO 1 #define SMI_GYRO_USE_BASIC_I2C_FUNC 1 Loading @@ -163,7 +163,7 @@ #define SMI_GYRO_I2C_WRITE_DELAY_TIME 1 /* generic */ #define SMI_GYRO_MAX_RETRY_I2C_XFER (100) #define SMI_GYRO_MAX_RETRY_I2C_XFER (2) #define SMI_GYRO_MAX_RETRY_WAKEUP (5) #define SMI_GYRO_MAX_RETRY_WAIT_DRDY (100) Loading