With a beagleboard image created from bernard + meta-demo (dvhart/bbxm branch) I noticed that during startup apmd reports: ------------ Starting advanced power management daemon: No APM support in kernel (failed.) ------------ Kernel version is 2.6.37.3-yocto-standard+. bernard revision used to build was 82af8b9fb6d6d1439943fd15b8a75c0e663e4a45 (although it was not a from-scratch build).
Tossing this onto the beagleboard 1.1 pile.
I think the solution here is to remove apmd. I could be wrong - but this seems to be common even on the Angstrom distribution, while "echo mem > /sys/power/state" does start the suspend process (which currently fails, but...). I'm not sure what the requirements are for apmd to work and when one should expect to use apmd rather than the sys interface.
From what I can gather apmd is mostly obsoleted by acpid, which is mostly obsoleted by the various power management daemons of modern desktops. I don't know what we need to do with oe-core in general, but for the Yocto beagleboard image I'd just suggest dropping apmd altogether.
I also suggest to drop this package. apmd prints " No APM support in kernel" when it accesses "/proc/apm". The file "/proc/apm" is created in drivers/char/apm-emulation.c and it contains such "AC line status" and "Battery status" information. But beagleboard doesn't have battery and so apmd can't provide useful information. If we don't drop this package from beagleboard machine, we can add CONFIG_APM_EMULATION option to the kernel config to avoid this message.
I went ahead and submitted the change to remove this from the board.
Logging the email discussions on this change. >> On arm it used to be the case that this was the only way to expose user >> > > interface to suspend/resume the machine. Its not so much about their >> > > being hardware present for it as the whole kernel side was emulation of >> > > the user space notification part. >> > > >> > > Has something changed in recent kernels in this area? > > > > I won't claim to be an expert here .. but I haven't used apmd > > on many machines in quite a while. Assuming suspend_ops is > > implemented, it is typically just something ike this: > > > > echo mem > /sys/power/state > > > > or > > > > echo standby > /sys/power/state > > > > With a wakeup via the rtc, or whatever the board offers. I'm > > cc'ing Liming on this, since he's been poking at the board recently > > and may have more hands on information to share. > > > > If we ARE removing this capability, then we'll take the other option > > that we had for this case and enable the emulation. I have a suspicion that certain parts of the sato code do assume /dev/apm_bios device emulation is present to get userspace notification of suspend/resume events which the above doesn't provide last I checked. Likely this isn't an issue and I think that code in sato (matchbox panel app iirc) is toggled by the MACHINE_FEATURES but its certainly worth keeping in mind...
Liming: can we look into Richard's concerns and see what does/doesn't work with the change removed. It could be better to just add the emulation support. I'm thinking that we should just do this versus dropping APM. Also. Check the other meta layers for the beagleboard, there's no sense reinventing anything here.
http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=f5cddf955d7f8a2bf3a3fadf26219a4ddcdf6279
Verified with 20110908 build. Tree/Branch: stage/master_under_test Poky Commit:5fa508a717da07ef7352e4ac385ac276156aedec The apm daemon can start without errors. ############ root@beagleboard:~# ps aux|grep apmd root 35 0.0 0.0 0 0 ? S 15:57 0:00 [kapmd] root 17889 0.0 0.1 1656 368 ? Ss 16:46 0:00 /usr/sbin/apmd -P /etc/apm/apmd_proxy --proxy-timeout 30 root 17902 0.0 0.2 2180 532 ttyO2 S+ 16:48 0:00 grep apmd ##############