USB SS mode wakeup from SMS \ call

Hello

currently I am using the wp76xx + legato API to enable USBSS -

LE_ASSERT_OK(le_pm_Relax(r));

device goes to suspend

then I initiate a call, device wakes - up as expected

but, when finishing the call the device does not go back to sleep, how can I go back to sleep ?

Can you check /sys/power/wake_lock ?

that was the first thing I did :slight_smile:
the file behaves as expected, meaning empty when clearing the wakelock via API and have a value when “taking” the wake-lock

how ever the system does not enter and exit suspend to RAM as expected

I don’t see problem on WP76 Fw12.
During sleep mode (i.e. remove the USB cable), if I dial a phone call to the module, I can see the RING message.
Later if I drop the voice call, it goes to sleep mode automatically.

Could you list the active wakeup sources that are preventing the system to go to sleep:
awk '{print $6 "\t" $1}' /sys/kernel/debug/wakeup_sources | grep -v "^0"

I have found the reason

I had a background application that has used data connection to send data via MQTT

when I do not stop it I get:

awk ‘{print $6 “\t” $1}’ /sys/kernel/debug/wakeup_sources

| grep -v “^0”

active_since name

92803 UNIX

92483 UNIX

18 36

and system fails to go into USB-SS mode

if I stop it I get:

awk ‘{print $6 “\t” $1}’ /sys/kernel/debug/wakeup_sources

| grep -v “^0”

active_since name

12 20

and device enters USB SS mode