Merge "input: sensors: modify the apds9930 light sensor algorithms"

This commit is contained in:
Linux Build Service Account 2014-10-29 16:58:05 -07:00 committed by Gerrit - the friendly Code Review server
commit 6cff3a9601

View file

@ -705,15 +705,9 @@ static int LuxCalculation(struct i2c_client *client, int ch0data, int ch1data)
return -1; /* don't report first, change gain may help */
}
if (data->als_reduce) {
luxValue = ((IAC * apds993x_ga * APDS993X_DF) / 100) * 65 / 10 /
((apds993x_als_integration_tb[data->als_atime_index] /
100) * apds993x_als_again_tb[data->als_again_index]);
} else {
luxValue = ((IAC * apds993x_ga * APDS993X_DF) /100) /
((apds993x_als_integration_tb[data->als_atime_index] /
100) * apds993x_als_again_tb[data->als_again_index]);
}
luxValue = ((IAC * apds993x_ga * APDS993X_DF) / 100) * 65 / 10 /
((apds993x_als_integration_tb[data->als_atime_index] /
100) * apds993x_als_again_tb[data->als_again_index]);
return luxValue;
}