Prevent the thread unsafe operation during the user switching

- Prevent accessing a variable that controls brightness
  at the same time through different threads.

Bug: 267255661
Bug: 262663423
Test: Manual
Change-Id: I7ffeb83e664e058a9b3e9f4f8a59d65936c43a6b
(cherry picked from commit 9e345b6844e468e23f8205bc5b0c13ec75e5442e)
1 file changed