Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit cebf2e6c authored by Chris Kuiper's avatar Chris Kuiper
Browse files

sensorservice: ProximitySensor needs to report correct sensor state.

Calls to ProximitySensor::activate() may repeatedly set enabled=true.
The current logic doesn't account for that. In order to correctly
report the current sensor state, simply use
mSensorDevice.isSensorActive() instead.

Bug: 194878856
Test: 1) Reproduced problem and verified mIsProxActive in "dumpsys
         display" contains the correct value and no more 60/90Hz
         flicker.
      2) Adding local debugs, then mixing making phone calls with
         additional "sensor_test sample -s8 -n5" commands to create
         several Prox clients, and verifying logged flags and
         reference counts.
Change-Id: I2342844ff4e6301a6b9ac8a33dc3e6047fca83ad
parent c63880a5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment