This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM335x-EVM Linux SDK suspend to RAM broken?

Other Parts Discussed in Thread: LINUXEZSDK-SITARA

The BeagleBone is ostensibly equivalent to the AM335xEVM (it uses the same PSP, etc.).

The procedure for entering Suspend to RAM is documented here:

http://processors.wiki.ti.com/index.php/Sitara_Linux_Training:_Power_Management

Alas, it doesn't work, at least with my test setup:

BeagleBone HW Rev A5
Angstrom-Cloud9-IDE-GNOME-eglibc-ipk-v2012.05-beaglebone-2012.04.22.img.xz loaded to the SD card

uname -a output is: Linux beaglebone 3.2.14 #1 Sat Apr 21 10:00:05 CEST 2012 armv7l GNU/Linux

The above documentation implies that the kernel must be recompiled to enable the Suspend/Resume functionality, although the current am335x-evm_defconfig seems to have the desired settings already.

I've tried both the default kernel and a specially compiled kernel, and both exhibit the same failure mode.

To reproduce, the console commands are simply:

echo none > /sys/power/pm_test
echo mem > /sys/power/state

The "echo none..." is optional unless pm_test has already been set to something else.  "none" is the default value.

The behavior is that Linux locks up and the only method of recovery is to perform a hardware reset.  Contrary to the above link, no Linux system messages are shown.

Turning on some of Linux's PM debugging functionality, some other data points are:

echo devices > /sys/power/pm_test
echo mem > /sys/power/state

[  599.528480]
[  599.528495] CPSW phy found : id is : 0x7c0f1
[  599.530085] PHY 0:01 not found
[  599.541284] Kernel core reported suspend failure

echo platform > /sys/power/pm_test
echo mem > /sys/power/state

[  721.148473]
[  721.148486] CPSW phy found : id is : 0x7c0f1
[  721.150075] PHY 0:01 not found
[  721.161270] Kernel core reported suspend failure

echo core > /sys/power/pm_test
echo mem > /sys/power/state

[  239.871978]
[  239.871978] CPSW phy found : id is : 0x7c0f1
[  239.873565] PHY 0:01 not found
[  239.884796] Kernel core reported suspend failure

  • Peter,


    Have you tried the SDK from www.ti.com/tool/linuxezsdk-sitara?

    The 05.04.01.00 version has support for suspend to RAM

    Chase

  • Oops... I forgot to specifically mention the SDK version that I used to compile the kernel.

    Yes, I'm using the 05.04.01.00 SDK to compile the kernel, and the behavior is faulty as described in the original post.

  • FYI, there is a cryptic known issue listed in PSP 04.06.00.07 (the PSP for am335x-evm_defconfig in 05.04.01.00 SDK):

    http://processors.wiki.ti.com/index.php/AM335x-PSP_04.06.00.07_Release_Notes

    SDOCM00090962 Resume operation fails on some beaglebone boards

    However, that ticket says "(mainly rev A3)" and this is a rev A5 board.

    Moreover, the ticket suggests that suspend and resume messages are spit out (including a 'resume of devices complete' message) and I don't even get that much activity.

  • Peter,

    Can you post a full boot log as well as the terminal output when you run the "echo mem > /sys/power/state" command?

    Your original message mentions the angstrom FS.

    Also, what happens when you use the pre-built binaries within the SDK?

    Chase

  • OK, thanks Chase for asking the right question.

    I think what is unnecessarily confusing is that the README.htm onboard the BeagleBone:

    http://beagleboard.org/static/beaglebone/latest/README.htm

    directs users to download this Angstrom image:

    http://downloads.angstrom-distribution.org/demo/beaglebone/

    The TI Sitara Linux SDK page:

    http://software-dl.ti.com/dsps/dsps_public_sw/am_bu/sdk/AM335xSDK/latest/index_FDS.html

    just has a "beaglebone-qsg.pdf" BeagleBone Quick Start Guide that just says "insert provided SD card".

    Apparently the BeagleBone boards are "provided" with a different (Angstrom-based?) SD card?

    I must admit that I defaulted to thinking these were based off the same distribution, so I just replaced the existing kernel on the (Angstrom-based?) BeagleBone image with the Sitara Linux SDK kernel image.

    It seems worth someone formally documenting how to replace the factory BeagleBone image with the proper Linux SDK images, since it is not apparent for a new purchaser that the provided images are *not* the TI ones.

    The short version is that I downloaded "am335x-evm-sdk-bin-05.04.01.00.tar.gz" from:

    http://software-dl.ti.com/dsps/dsps_public_sw/am_bu/sdk/AM335xSDK/latest/index_FDS.html

    and broke the archive's contents into two quantities: the tisdk-rootfs-am335x-evm.tar.gz should go into one directory, and the remaining files (MLO, etc.) should go into another directory.

    With those two directories created, one can then use this script (part of the Linux SDK):

    http://processors.wiki.ti.com/index.php/Sitara_Linux_SDK_create_SD_card_script

    and choose the "Enter in custom boot and rootfs file paths" option.

    The Linux SDK image is not without its problems (USB Device Not Recognized error message, etc.), but it DOES do Suspend to RAM.

    Thanks!

  • The kernel source included in the SDK is not the Angstrom distribution, is it? Is it the Arago distribution? Or a third distribution?

    Arago's website says it is more "cutting edge" than the more stable TI SDK, but not as bleeding edge as Angstrom. However, I don't see much new on the Arago site in http://arago-project.org/files/releases/ whereas the TI SDK seems to be getting new versions released monthly or so...

    As near as I can tell, 3.2.14 is the current version of the Angstrom kernel, 3.2.0 is the latest TI SDK kernel, and.. ah.. Chase Maupin is commiting to git on Arago.. in a 3.2.0

    http://arago-project.org/git/?p=arago.git;a=summary

    so the TI SDK is being hosted / developed on Arago?

    I figure if I'm confused about all of this, maybe others are too...

  • My Beaglebone came with two cards.. Angstrom and Arago. Angstrom had my favorite language, Python, installed. I updated my Angstrom; it was at 3.2.14.. I noticed the latest TI SDK was at 3.2 but the arago card was at 3.1.0-rc8, so I figured the SDK was Angstrom.. I think I made a similar mistake as you..

  • Hi Peter,

    Peter Lawrence said:
    The Linux SDK image is not without its problems (USB Device Not Recognized error message, etc.),

    Can you provide more details here? Which USB device is this? Are you saying a USB device works correctly with Angstorm, but not with TI SDK?

    Thanks,
    Sekhar

  • Sekhar, I don't have a complete answer on this, but I think it is just a difference of configurations between the BeagleBone's Angstrom-based distribution and the TI SDK distribution.

    The former is configured to automatically load the g_mass_storage / g_ether Linux modules (and possibly other modules) upon boot.

    The latter does not do this (but the user can insmod these manually or edit the relevant configuration files).

    As a result, when plugs the BeagleBone with the TI SDK distribution into a Windows PC, a new USB device is detected, but the PC is never able to enumerate it.  After a long delay, Windows spits out a "USB Device Not Recognized" error message as a result.

    I don't think there is anything wrong, per se, with the way the TI SDK distribution works.  The only downside is that the configuration just makes the new user initially think something is wrong.

    P.S.: perhaps unlike the AM335xEVM, plugging the BeagleBoard into a PC is largely not optional as its built-in FTDI serial converter is needed to access the console.  Since there is an integrated USB hub on the BeagleBoard, this also means the Sitara AM335x's USB device/OTG port is also connected at the same time.

    Sekhar Nori said:

    Hi Peter,

    The Linux SDK image is not without its problems (USB Device Not Recognized error message, etc.),

    Can you provide more details here? Which USB device is this? Are you saying a USB device works correctly with Angstorm, but not with TI SDK?

    Thanks,
    Sekhar

    [/quote]

  • Hi Peter,

    Thanks for the detailed explanation. I just wanted to make sure we are not missing any patches in the TI SDK. Looks like thats not the case.

    Regards,

    Sekhar

     

  • Good discussion topic; with all the information scattered everywhere,it is easy to get lost.

    I hope this will help;

    This is the image that is shipping on All Revsions : 

                                                                 http://circuitco.com/support/index.php?title=BeagleBone