€•ƒ;Œsphinx.addnodes”Œdocument”“”)”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)”}”(hhh]”(hŒ pending_xref”“”)”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…””}”(hhŒparent”hubaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ/translations/zh_CN/power/s2ram”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)”}”(hhh]”hŒChinese (Traditional)”…””}”(hhhh2ubah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/zh_TW/power/s2ram”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒItalian”…””}”(hhhhFubah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/it_IT/power/s2ram”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒJapanese”…””}”(hhhhZubah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/ja_JP/power/s2ram”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒKorean”…””}”(hhhhnubah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/ko_KR/power/s2ram”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒSpanish”…””}”(hhhh‚ubah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/sp_SP/power/s2ram”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒsection”“”)”}”(hhh]”(hŒtitle”“”)”}”(hŒHow to get s2ram working”h]”hŒHow to get s2ram working”…””}”(hhªhh¨hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¦hh£hžhhŸŒ9/var/lib/git/docbuild/linux/Documentation/power/s2ram.rst”h KubhŒ paragraph”“”)”}”(hŒ%2006 Linus Torvalds 2006 Pavel Machek”h]”hŒ%2006 Linus Torvalds 2006 Pavel Machek”…””}”(hh»hh¹hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h Khh£hžhubhŒenumerated_list”“”)”}”(hhh]”(hŒ list_item”“”)”}”(hŒ{Check suspend.sf.net, program s2ram there has long whitelist of "known ok" machines, along with tricks to use on each one. ”h]”h¸)”}”(hŒzCheck suspend.sf.net, program s2ram there has long whitelist of "known ok" machines, along with tricks to use on each one.”h]”hŒ~Check suspend.sf.net, program s2ram there has long whitelist of “known ok†machines, along with tricks to use on each one.”…””}”(hhÔhhÒhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h KhhÎubah}”(h]”h ]”h"]”h$]”h&]”uh1hÌhhÉhžhhŸh¶h NubhÍ)”}”(hŒ‘If that does not help, try reading tricks.txt and video.txt. Perhaps problem is as simple as broken module, and simple module unload can fix it. ”h]”h¸)”}”(hŒIf that does not help, try reading tricks.txt and video.txt. Perhaps problem is as simple as broken module, and simple module unload can fix it.”h]”hŒIf that does not help, try reading tricks.txt and video.txt. Perhaps problem is as simple as broken module, and simple module unload can fix it.”…””}”(hhìhhêhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h K hhæubah}”(h]”h ]”h"]”h$]”h&]”uh1hÌhhÉhžhhŸh¶h NubhÍ)”}”(hŒAYou can use Linus' TRACE_RESUME infrastructure, described below. ”h]”h¸)”}”(hŒ@You can use Linus' TRACE_RESUME infrastructure, described below.”h]”hŒBYou can use Linus’ TRACE_RESUME infrastructure, described below.”…””}”(hjhjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h Khhþubah}”(h]”h ]”h"]”h$]”h&]”uh1hÌhhÉhžhhŸh¶h Nubeh}”(h]”h ]”h"]”h$]”h&]”Œenumtype”Œarabic”Œprefix”hŒsuffix”Œ)”uh1hÇhh£hžhhŸh¶h Kubh¢)”}”(hhh]”(h§)”}”(hŒUsing TRACE_RESUME”h]”hŒUsing TRACE_RESUME”…””}”(hj&hj$hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¦hj!hžhhŸh¶h Kubh¸)”}”(hX˜I've been working at making the machines I have able to STR, and almost always it's a driver that is buggy. Thank God for the suspend/resume debugging - the thing that Chuck tried to disable. That's often the _only_ way to debug these things, and it's actually pretty powerful (but time-consuming - having to insert TRACE_RESUME() markers into the device driver that doesn't resume and recompile and reboot).”h]”hX¢I’ve been working at making the machines I have able to STR, and almost always it’s a driver that is buggy. Thank God for the suspend/resume debugging - the thing that Chuck tried to disable. That’s often the _only_ way to debug these things, and it’s actually pretty powerful (but time-consuming - having to insert TRACE_RESUME() markers into the device driver that doesn’t resume and recompile and reboot).”…””}”(hj4hj2hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h Khj!hžhubh¸)”}”(hŒbAnyway, the way to debug this for people who are interested (have a machine that doesn't boot) is:”h]”hŒdAnyway, the way to debug this for people who are interested (have a machine that doesn’t boot) is:”…””}”(hjBhj@hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h Khj!hžhubhŒ block_quote”“”)”}”(hhh]”hŒ bullet_list”“”)”}”(hhh]”(hÍ)”}”(hŒenable PM_DEBUG, and PM_TRACE ”h]”h¸)”}”(hŒenable PM_DEBUG, and PM_TRACE”h]”hŒenable PM_DEBUG, and PM_TRACE”…””}”(hj^hj\hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h KhjXubah}”(h]”h ]”h"]”h$]”h&]”uh1hÌhjUubhÍ)”}”(hŒ‚use a script like this:: #!/bin/sh sync echo 1 > /sys/power/pm_trace echo mem > /sys/power/state to suspend ”h]”(h¸)”}”(hŒuse a script like this::”h]”hŒuse a script like this:”…””}”(hŒuse a script like this:”hjthžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h K hjpubhŒ literal_block”“”)”}”(hŒG#!/bin/sh sync echo 1 > /sys/power/pm_trace echo mem > /sys/power/state”h]”hŒG#!/bin/sh sync echo 1 > /sys/power/pm_trace echo mem > /sys/power/state”…””}”(hhhj…ubah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1jƒhŸh¶h K"hjpubh¸)”}”(hŒ to suspend”h]”hŒ to suspend”…””}”(hj—hj•hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h K'hjpubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÌhjUubhÍ)”}”(hX]if it doesn't come back up (which is usually the problem), reboot by holding the power button down, and look at the dmesg output for things like:: Magic number: 4:156:725 hash matches drivers/base/power/resume.c:28 hash matches device 0000:01:00.0 which means that the last trace event was just before trying to resume device 0000:01:00.0. Then figure out what driver is controlling that device (lspci and /sys/devices/pci* is your friend), and see if you can fix it, disable it, or trace into its resume function. If no device matches the hash (or any matches appear to be false positives), the culprit may be a device from a loadable kernel module that is not loaded until after the hash is checked. You can check the hash against the current devices again after more modules are loaded using sysfs:: cat /sys/power/pm_trace_dev_match ”h]”(h¸)”}”(hŒ’if it doesn't come back up (which is usually the problem), reboot by holding the power button down, and look at the dmesg output for things like::”h]”hŒ“if it doesn’t come back up (which is usually the problem), reboot by holding the power button down, and look at the dmesg output for things like:”…””}”(hŒ‘if it doesn't come back up (which is usually the problem), reboot by holding the power button down, and look at the dmesg output for things like:”hj­hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h K)hj©ubj„)”}”(hŒdMagic number: 4:156:725 hash matches drivers/base/power/resume.c:28 hash matches device 0000:01:00.0”h]”hŒdMagic number: 4:156:725 hash matches drivers/base/power/resume.c:28 hash matches device 0000:01:00.0”…””}”(hhhj¼ubah}”(h]”h ]”h"]”h$]”h&]”j“j”uh1jƒhŸh¶h K-hj©ubh¸)”}”(hX which means that the last trace event was just before trying to resume device 0000:01:00.0. Then figure out what driver is controlling that device (lspci and /sys/devices/pci* is your friend), and see if you can fix it, disable it, or trace into its resume function.”h]”hX which means that the last trace event was just before trying to resume device 0000:01:00.0. Then figure out what driver is controlling that device (lspci and /sys/devices/pci* is your friend), and see if you can fix it, disable it, or trace into its resume function.”…””}”(hjÌhjÊhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h K1hj©ubh¸)”}”(hXIf no device matches the hash (or any matches appear to be false positives), the culprit may be a device from a loadable kernel module that is not loaded until after the hash is checked. You can check the hash against the current devices again after more modules are loaded using sysfs::”h]”hXIf no device matches the hash (or any matches appear to be false positives), the culprit may be a device from a loadable kernel module that is not loaded until after the hash is checked. You can check the hash against the current devices again after more modules are loaded using sysfs:”…””}”(hXIf no device matches the hash (or any matches appear to be false positives), the culprit may be a device from a loadable kernel module that is not loaded until after the hash is checked. You can check the hash against the current devices again after more modules are loaded using sysfs:”hjØhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h K6hj©ubj„)”}”(hŒ!cat /sys/power/pm_trace_dev_match”h]”hŒ!cat /sys/power/pm_trace_dev_match”…””}”(hhhjçubah}”(h]”h ]”h"]”h$]”h&]”j“j”uh1jƒhŸh¶h K;hj©ubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÌhjUubeh}”(h]”h ]”h"]”h$]”h&]”Œbullet”Œ-”uh1jShŸh¶h KhjPubah}”(h]”h ]”h"]”h$]”h&]”uh1jNhj!hžhhŸNh Nubh¸)”}”(hX;For example, the above happens to be the VGA device on my EVO, which I used to run with "radeonfb" (it's an ATI Radeon mobility). It turns out that "radeonfb" simply cannot resume that device - it tries to set the PLL's, and it just _hangs_. Using the regular VGA console and letting X resume it instead works fine.”h]”hXGFor example, the above happens to be the VGA device on my EVO, which I used to run with “radeonfb†(it’s an ATI Radeon mobility). It turns out that “radeonfb†simply cannot resume that device - it tries to set the PLL’s, and it just _hangs_. Using the regular VGA console and letting X resume it instead works fine.”…””}”(hj hj hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h K=hj!hžhubh¢)”}”(hhh]”(h§)”}”(hŒNOTE”h]”hŒNOTE”…””}”(hjhjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¦hjhžhhŸh¶h KDubh¸)”}”(hŒépm_trace uses the system's Real Time Clock (RTC) to save the magic number. Reason for this is that the RTC is the only reliably available piece of hardware during resume operations where a value can be set that will survive a reboot.”h]”hŒëpm_trace uses the system’s Real Time Clock (RTC) to save the magic number. Reason for this is that the RTC is the only reliably available piece of hardware during resume operations where a value can be set that will survive a reboot.”…””}”(hj*hj(hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h KEhjhžhubh¸)”}”(hŒ•pm_trace is not compatible with asynchronous suspend, so it turns asynchronous suspend off (which may work around timing or ordering-sensitive bugs).”h]”hŒ•pm_trace is not compatible with asynchronous suspend, so it turns asynchronous suspend off (which may work around timing or ordering-sensitive bugs).”…””}”(hj8hj6hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h KJhjhžhubh¸)”}”(hXAConsequence is that after a resume (even if it is successful) your system clock will have a value corresponding to the magic number instead of the correct date/time! It is therefore advisable to use a program like ntp-date or rdate to reset the correct date/time from an external time source when using this trace option.”h]”hXAConsequence is that after a resume (even if it is successful) your system clock will have a value corresponding to the magic number instead of the correct date/time! It is therefore advisable to use a program like ntp-date or rdate to reset the correct date/time from an external time source when using this trace option.”…””}”(hjFhjDhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h KNhjhžhubh¸)”}”(hŒ÷As the clock keeps ticking it is also essential that the reboot is done quickly after the resume failure. The trace option does not use the seconds or the low order bits of the minutes of the RTC, but a too long delay will corrupt the magic value.”h]”hŒ÷As the clock keeps ticking it is also essential that the reboot is done quickly after the resume failure. The trace option does not use the seconds or the low order bits of the minutes of the RTC, but a too long delay will corrupt the magic value.”…””}”(hjThjRhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h·hŸh¶h KThjhžhubeh}”(h]”Œnote”ah ]”h"]”Œnote”ah$]”h&]”uh1h¡hj!hžhhŸh¶h KDubeh}”(h]”Œusing-trace-resume”ah ]”h"]”Œusing trace_resume”ah$]”h&]”uh1h¡hh£hžhhŸh¶h Kubeh}”(h]”Œhow-to-get-s2ram-working”ah ]”h"]”Œhow to get s2ram working”ah$]”h&]”uh1h¡hhhžhhŸh¶h Kubeh}”(h]”h ]”h"]”h$]”h&]”Œsource”h¶uh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)”}”(h¦NŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”Œentry”Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”j›Œerror_encoding”ŒUTF-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”h¶Œ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œ embed_images”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”Œnameids”}”(jujrjmjjjejbuŒ nametypes”}”(juNjmNjeNuh}”(jrh£jjj!jbjuŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”…”R”Œparse_messages”]”Œtransform_messages”]”Œ transformer”NŒ include_log”]”Œ decoration”Nhžhub.