How does sleep really work in the Android kernel?

I’ve been wondering about this for a while, but couldn’t find anything about it. What exactly happens after the screen turns off? Does the kernel actually suspend and halt the CPU? If so, how are notifications received while sleeping? Is there a coprocessor involved?

I’m curious. It would be great if someone could point me towards some articles or videos about this.

@[email protected] @[email protected] @[email protected] @[email protected] #android #linux #kernel #sleep #suspend

  • @WhoRoger
    link
    41 year ago

    Amateur here, can only convey what I remember from reading. In sleep mode the the cpu wakes up regularly to do things that are needed for background services and connectivity.

    Now, “regularly” may still mean hundreds of times a second between milliseconds of sleep. These wake cycles are also synchronised with other parts of the system, especially networking.

    Similarly, cpu will sleep even if the phone is awake but not very active, but will wake more frequently.