Exactly… this is 1 year ago. 1 year is a long time. and by the way…, who cares whether USB returns to a working state? The issue here is to save lots of battery and lots of heating. If I need the USB, L5 is already a winner in how fast it reboots.
If people have a working suspend with problems just with the USB this must be merged. It is more important than USB (since you can always reboot and disable suspend if needed).
So if you want an incoming call to wake the phone (many people would! @antonis) then you want a USB device to be able to wake the phone. I’m not really across the internals though. There may be multiple USB buses, with different behaviours.
The i.MX 8M Quad only has 2 USB buses, which can both run at either USB 2.0 or 3.0. One bus is for the USB-C port and the test points, and it is using USB 3.0. The other bus is for the microSD card and cellular modem and is using USB 2.0. The USB is provided by Synopsys and it uses the dwc3 driver.
It looks like Purism can work around this problem by unloading the USB driver before suspend with ` rmmod dwc3 and then reenabling it with modprobe -l dwc3 after resume. However, the bigger problem is that they still haven’t figured out how to suspend the BM818 cellular modem and still haven’t figured out how to make the RS9116 WiFi and BM818 modem to wake up the system when a phone call is received (see the links in the FAQ). Judging from the comments in the bug reports, it doesn’t look like these issues have received a lot of attention from the dev team. It’s hard for me to judge how quickly they can be solved, but they don’t look like easy issues to me.
That’s because that’s not the problem at all, just a matter of correct regulator configuration to not turn the modem off during suspend. The thing that would have to be done first is creating a branch of the ATF where both suspend and devfreq could work at the same time and this is the main thing blocking suspend to ram at the moment. With that in place there are several smaller issues like the dwc3 thing that will have to be debugged one by one.
I was testing today Suspend to Ram on Librem 5 it work really good, the modem woke up from deep sleep on 3 tones of the call.
It seems that Modem wake up with 4G only, but at moment there is issues with call under 4G for missing VoLTE so to fix this issues with STR we need to put the modem on all Signal on Phosh config. Like 2G-3G-4G.
I am pretty sure that oFono 1.33 has a hack for permit call under 4G without going back to 3G, so L5 it using MM.
SMS, Calls, Vol + - , power button, all this wake up the L5.
I used the terminal to put the L5 on Suspend, but also there is a button on posh to enable.
@weirdnerd : I not tested yet the battery, but i believe it is 2% on suspended, compared to 8% per hours on inactive mode.
Suspend isn’t ready and it’s not enabled yet. What changed is that with the latest kernel there’s actually a chance that it may work if you trigger is manually (previously it was guaranteed to not wake up after suspending). It can be tested with echo mem | sudo tee /sys/power/state.
Sorry for the late reply, yeah as @dos say you need new kernel plus new librem5-base packages to get it work, i think may be this 2 packages will be available to byzantium very soon.
Also i want to clarify something about Suspend to Ram and modem on my test, the Screen turn ON on the first dial-tone of the Call but is not Ring because Phosh still getting ready to start ringing, so the L5 start ring from suspend on the third dial-tone of the Caller.
Is it expected to wake up after suspend only via modem? I have the latest kernel and librem5-base but only screen wakes up if I press power or volume buttons, nothing else works. I have some packages from Debian unstable/experimental.