€•‚}Œsphinx.addnodes”Œdocument”“”)”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)”}”(hhh]”(hŒ pending_xref”“”)”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…””}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ(/translations/zh_CN/arch/x86/earlyprintk”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)”}”(hhh]”hŒChinese (Traditional)”…””}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ(/translations/zh_TW/arch/x86/earlyprintk”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒItalian”…””}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ(/translations/it_IT/arch/x86/earlyprintk”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒJapanese”…””}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ(/translations/ja_JP/arch/x86/earlyprintk”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒKorean”…””}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ(/translations/ko_KR/arch/x86/earlyprintk”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒSpanish”…””}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ(/translations/sp_SP/arch/x86/earlyprintk”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒcomment”“”)”}”(hŒ SPDX-License-Identifier: GPL-2.0”h]”hŒ SPDX-License-Identifier: GPL-2.0”…””}”hh£sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1h¡hhhžhhŸŒB/var/lib/git/docbuild/linux/Documentation/arch/x86/earlyprintk.rst”h KubhŒsection”“”)”}”(hhh]”(hŒtitle”“”)”}”(hŒ Early Printk”h]”hŒ Early Printk”…””}”(hh»hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hh¶hžhhŸh³h KubhŒ paragraph”“”)”}”(hŒsMini-HOWTO for using the earlyprintk=dbgp boot option with a USB2 Debug port key and a debug cable, on x86 systems.”h]”hŒsMini-HOWTO for using the earlyprintk=dbgp boot option with a USB2 Debug port key and a debug cable, on x86 systems.”…””}”(hhËhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Khh¶hžhubhÊ)”}”(hŒdYou need two computers, the 'USB debug key' special gadget and two USB cables, connected like this::”h]”hŒgYou need two computers, the ‘USB debug key’ special gadget and two USB cables, connected like this:”…””}”(hhÙhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K hh¶hžhubhŒ literal_block”“”)”}”(hŒB[host/target] <-------> [USB debug key] <-------> [client/console]”h]”hŒB[host/target] <-------> [USB debug key] <-------> [client/console]”…””}”hhésbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1hçhŸh³h K hh¶hžhubhµ)”}”(hhh]”(hº)”}”(hŒHardware requirements”h]”hŒHardware requirements”…””}”(hhúhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hh÷hžhhŸh³h KubhŒ block_quote”“”)”}”(hX a) Host/target system needs to have USB debug port capability. You can check this capability by looking at a 'Debug port' bit in the lspci -vvv output:: # lspci -vvv ... 00:1d.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #1 (rev 03) (prog-if 20 [EHCI]) Subsystem: Lenovo ThinkPad T61 Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR+ FastB2B- DisINTx- Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- SERR- TAbort- SERR- TAbort- SERR- TAbort- SERR- /grub.cfg. On systems with more than one EHCI debug controller you must specify the correct EHCI debug controller number. The ordering comes from the PCI bus enumeration of the EHCI controllers. The default with no number argument is "0" or the first EHCI debug controller. To use the second EHCI debug controller, you would use the command line: "earlyprintk=dbgp1" .. note:: normally earlyprintk console gets turned off once the regular console is alive - use "earlyprintk=dbgp,keep" to keep this channel open beyond early bootup. This can be useful for debugging crashes under Xorg, etc. b) On the client/console system: You should enable the following kernel config option:: CONFIG_USB_SERIAL_DEBUG=y On the next bootup with the modified kernel you should get a /dev/ttyUSBx device(s). Now this channel of kernel messages is ready to be used: start your favorite terminal emulator (minicom, etc.) and set it up to use /dev/ttyUSB0 - or use a raw 'cat /dev/ttyUSBx' to see the raw output. c) On Nvidia Southbridge based systems: the kernel will try to probe and find out which port has a debug device connected. ”h]”(j)”}”(hhh]”j)”}”(hŒOn the host/target system: ”h]”hÊ)”}”(hŒOn the host/target system:”h]”hŒOn the host/target system:”…””}”(hjFhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h KThjBubah}”(h]”h ]”h"]”h$]”h&]”uh1jhj?ubah}”(h]”h ]”h"]”h$]”h&]”jjjhjjuh1jhj;ubj )”}”(hXKYou need to enable the following kernel config option:: CONFIG_EARLY_PRINTK_DBGP=y And you need to add the boot command line: "earlyprintk=dbgp". .. note:: If you are using Grub, append it to the 'kernel' line in /etc/grub.conf. If you are using Grub2 on a BIOS firmware system, append it to the 'linux' line in /boot/grub2/grub.cfg. If you are using Grub2 on an EFI firmware system, append it to the 'linux' or 'linuxefi' line in /boot/grub2/grub.cfg or /boot/efi/EFI//grub.cfg. On systems with more than one EHCI debug controller you must specify the correct EHCI debug controller number. The ordering comes from the PCI bus enumeration of the EHCI controllers. The default with no number argument is "0" or the first EHCI debug controller. To use the second EHCI debug controller, you would use the command line: "earlyprintk=dbgp1" .. note:: normally earlyprintk console gets turned off once the regular console is alive - use "earlyprintk=dbgp,keep" to keep this channel open beyond early bootup. This can be useful for debugging crashes under Xorg, etc. ”h]”(hÊ)”}”(hŒ7You need to enable the following kernel config option::”h]”hŒ6You need to enable the following kernel config option:”…””}”(hjdhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h KVhj`ubhè)”}”(hŒCONFIG_EARLY_PRINTK_DBGP=y”h]”hŒCONFIG_EARLY_PRINTK_DBGP=y”…””}”hjrsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1hçhŸh³h KXhj`ubhÊ)”}”(hŒ>And you need to add the boot command line: "earlyprintk=dbgp".”h]”hŒBAnd you need to add the boot command line: “earlyprintk=dbgpâ€.”…””}”(hj€hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h KZhj`ubjD)”}”(hXLIf you are using Grub, append it to the 'kernel' line in /etc/grub.conf. If you are using Grub2 on a BIOS firmware system, append it to the 'linux' line in /boot/grub2/grub.cfg. If you are using Grub2 on an EFI firmware system, append it to the 'linux' or 'linuxefi' line in /boot/grub2/grub.cfg or /boot/efi/EFI//grub.cfg.”h]”hÊ)”}”(hXLIf you are using Grub, append it to the 'kernel' line in /etc/grub.conf. If you are using Grub2 on a BIOS firmware system, append it to the 'linux' line in /boot/grub2/grub.cfg. If you are using Grub2 on an EFI firmware system, append it to the 'linux' or 'linuxefi' line in /boot/grub2/grub.cfg or /boot/efi/EFI//grub.cfg.”h]”hX\If you are using Grub, append it to the ‘kernel’ line in /etc/grub.conf. If you are using Grub2 on a BIOS firmware system, append it to the ‘linux’ line in /boot/grub2/grub.cfg. If you are using Grub2 on an EFI firmware system, append it to the ‘linux’ or ‘linuxefi’ line in /boot/grub2/grub.cfg or /boot/efi/EFI//grub.cfg.”…””}”(hj’hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K]hjŽubah}”(h]”h ]”h"]”h$]”h&]”uh1jChj`ubhÊ)”}”(hXfOn systems with more than one EHCI debug controller you must specify the correct EHCI debug controller number. The ordering comes from the PCI bus enumeration of the EHCI controllers. The default with no number argument is "0" or the first EHCI debug controller. To use the second EHCI debug controller, you would use the command line: "earlyprintk=dbgp1"”h]”hXnOn systems with more than one EHCI debug controller you must specify the correct EHCI debug controller number. The ordering comes from the PCI bus enumeration of the EHCI controllers. The default with no number argument is “0†or the first EHCI debug controller. To use the second EHCI debug controller, you would use the command line: “earlyprintk=dbgp1—…””}”(hj¦hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Kdhj`ubjD)”}”(hŒÕnormally earlyprintk console gets turned off once the regular console is alive - use "earlyprintk=dbgp,keep" to keep this channel open beyond early bootup. This can be useful for debugging crashes under Xorg, etc.”h]”hÊ)”}”(hŒÕnormally earlyprintk console gets turned off once the regular console is alive - use "earlyprintk=dbgp,keep" to keep this channel open beyond early bootup. This can be useful for debugging crashes under Xorg, etc.”h]”hŒÙnormally earlyprintk console gets turned off once the regular console is alive - use “earlyprintk=dbgp,keep†to keep this channel open beyond early bootup. This can be useful for debugging crashes under Xorg, etc.”…””}”(hj¸hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Klhj´ubah}”(h]”h ]”h"]”h$]”h&]”uh1jChj`ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jhŸh³h KVhj;ubj)”}”(hhh]”j)”}”(hŒOn the client/console system: ”h]”hÊ)”}”(hŒOn the client/console system:”h]”hŒOn the client/console system:”…””}”(hjÙhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h KqhjÕubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjÒubah}”(h]”h ]”h"]”h$]”h&]”jjjhjjŒstart”Kuh1jhj;ubj )”}”(hXuYou should enable the following kernel config option:: CONFIG_USB_SERIAL_DEBUG=y On the next bootup with the modified kernel you should get a /dev/ttyUSBx device(s). Now this channel of kernel messages is ready to be used: start your favorite terminal emulator (minicom, etc.) and set it up to use /dev/ttyUSB0 - or use a raw 'cat /dev/ttyUSBx' to see the raw output. ”h]”(hÊ)”}”(hŒ6You should enable the following kernel config option::”h]”hŒ5You should enable the following kernel config option:”…””}”(hjøhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Kshjôubhè)”}”(hŒCONFIG_USB_SERIAL_DEBUG=y”h]”hŒCONFIG_USB_SERIAL_DEBUG=y”…””}”hjsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1hçhŸh³h KuhjôubhÊ)”}”(hŒTOn the next bootup with the modified kernel you should get a /dev/ttyUSBx device(s).”h]”hŒTOn the next bootup with the modified kernel you should get a /dev/ttyUSBx device(s).”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h KwhjôubhÊ)”}”(hŒÉNow this channel of kernel messages is ready to be used: start your favorite terminal emulator (minicom, etc.) and set it up to use /dev/ttyUSB0 - or use a raw 'cat /dev/ttyUSBx' to see the raw output.”h]”hŒÍNow this channel of kernel messages is ready to be used: start your favorite terminal emulator (minicom, etc.) and set it up to use /dev/ttyUSB0 - or use a raw ‘cat /dev/ttyUSBx’ to see the raw output.”…””}”(hj"hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Kzhjôubeh}”(h]”h ]”h"]”h$]”h&]”uh1jhŸh³h Kshj;ubj)”}”(hhh]”j)”}”(hŒxOn Nvidia Southbridge based systems: the kernel will try to probe and find out which port has a debug device connected. ”h]”hÊ)”}”(hŒwOn Nvidia Southbridge based systems: the kernel will try to probe and find out which port has a debug device connected.”h]”hŒwOn Nvidia Southbridge based systems: the kernel will try to probe and find out which port has a debug device connected.”…””}”(hj=hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Khj9ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhj6ubah}”(h]”h ]”h"]”h$]”h&]”jjjhjjjóKuh1jhj;ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jhŸh³h KThj*hžhubeh}”(h]”Œsoftware-requirements”ah ]”h"]”Œsoftware requirements”ah$]”h&]”uh1h´hh¶hžhhŸh³h KRubhµ)”}”(hhh]”(hº)”}”(hŒTesting”h]”hŒTesting”…””}”(hjhhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjehžhhŸh³h KƒubhÊ)”}”(hŒ°You can test the output by using earlyprintk=dbgp,keep and provoking kernel messages on the host/target system. You can provoke a harmless kernel message by for example doing::”h]”hŒ¯You can test the output by using earlyprintk=dbgp,keep and provoking kernel messages on the host/target system. You can provoke a harmless kernel message by for example doing:”…””}”(hjvhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K…hjehžhubhè)”}”(hŒecho h > /proc/sysrq-trigger”h]”hŒecho h > /proc/sysrq-trigger”…””}”hj„sbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1hçhŸh³h K‰hjehžhubhÊ)”}”(hŒKOn the host/target system you should see this help line in "dmesg" output::”h]”hŒNOn the host/target system you should see this help line in “dmesg†output:”…””}”(hj’hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K‹hjehžhubhè)”}”(hX?SysRq : HELP : loglevel(0-9) reBoot Crashdump terminate-all-tasks(E) memory-full-oom-kill(F) kill-all-tasks(I) saK show-backtrace-all-active-cpus(L) show-memory-usage(M) nice-all-RT-tasks(N) powerOff show-registers(P) show-all-timers(Q) unRaw Sync show-task-states(T) Unmount show-blocked-tasks(W) dump-ftrace-buffer(Z)”h]”hX?SysRq : HELP : loglevel(0-9) reBoot Crashdump terminate-all-tasks(E) memory-full-oom-kill(F) kill-all-tasks(I) saK show-backtrace-all-active-cpus(L) show-memory-usage(M) nice-all-RT-tasks(N) powerOff show-registers(P) show-all-timers(Q) unRaw Sync show-task-states(T) Unmount show-blocked-tasks(W) dump-ftrace-buffer(Z)”…””}”hj sbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1hçhŸh³h KhjehžhubhÊ)”}”(hŒ!On the client/console system do::”h]”hŒ On the client/console system do:”…””}”(hj®hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Khjehžhubhè)”}”(hŒcat /dev/ttyUSB0”h]”hŒcat /dev/ttyUSB0”…””}”hj¼sbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1hçhŸh³h K‘hjehžhubhÊ)”}”(hŒeAnd you should see the help line above displayed shortly after you've provoked it on the host system.”h]”hŒgAnd you should see the help line above displayed shortly after you’ve provoked it on the host system.”…””}”(hjÊhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K“hjehžhubhÊ)”}”(hŒ}If it does not work then please ask about it on the linux-kernel@vger.kernel.org mailing list or contact the x86 maintainers.”h]”(hŒ4If it does not work then please ask about it on the ”…””}”(hjØhžhhŸNh Nubj~)”}”(hŒlinux-kernel@vger.kernel.org”h]”hŒlinux-kernel@vger.kernel.org”…””}”(hjàhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œ#mailto:linux-kernel@vger.kernel.org”uh1j}hjØubhŒ- mailing list or contact the x86 maintainers.”…””}”(hjØhžhhŸNh Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K–hjehžhubeh}”(h]”Œtesting”ah ]”h"]”Œtesting”ah$]”h&]”uh1h´hh¶hžhhŸh³h Kƒubeh}”(h]”Œ early-printk”ah ]”h"]”Œ early printk”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Œfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œ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”‰Œ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”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”Œnameids”}”(jjj'j$jbj_jÿjüuŒ nametypes”}”(j‰j'‰jb‰jÿ‰uh}”(jh¶j$h÷j_j*jüjeuŒ 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”]”(hŒsystem_message”“”)”}”(hhh]”hÊ)”}”(hŒ:Enumerated list start value not ordinal-1: "b" (ordinal 2)”h]”hŒ>Enumerated list start value not ordinal-1: “b†(ordinal 2)”…””}”(hj”hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhj‘ubah}”(h]”h ]”h"]”h$]”h&]”Œlevel”KŒtype”ŒINFO”Œsource”h³Œline”Kuh1jhj;ubj)”}”(hhh]”hÊ)”}”(hŒ:Enumerated list start value not ordinal-1: "c" (ordinal 3)”h]”hŒ>Enumerated list start value not ordinal-1: “c†(ordinal 3)”…””}”(hj°hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhj­ubah}”(h]”h ]”h"]”h$]”h&]”Œlevel”KŒtype”jªŒsource”h³Œline”Kuh1jhj;ubeŒtransform_messages”]”Œ transformer”NŒ include_log”]”Œ decoration”Nhžhub.