Documentation/translations/zh_TW/arch/loongarch/booting.rst
Source file repositories/reference/linux-study-clean/Documentation/translations/zh_TW/arch/loongarch/booting.rst
File Facts
- System
- Linux kernel
- Corpus path
Documentation/translations/zh_TW/arch/loongarch/booting.rst- Extension
.rst- Size
- 1597 bytes
- Lines
- 50
- Domain
- Support Tooling And Documentation
- Bucket
- Documentation
- Inferred role
- Support Tooling And Documentation: documentation
- Status
- atlas-only
Why This File Exists
Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
- Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
Dependency Surface
- No C-style include directives detected by the generator.
Detected Declarations
- No top-level syscall, struct, function, initcall, or export declaration detected by the generator.
Annotated Snippet
.. SPDX-License-Identifier: GPL-2.0
.. include:: ../../disclaimer-zh_TW.rst
:Original: Documentation/arch/loongarch/booting.rst
:翻譯:
司延騰 Yanteng Si <siyanteng@loongson.cn>
====================
啓動 Linux/LoongArch
====================
:作者: 司延騰 <siyanteng@loongson.cn>
:日期: 2022年11月18日
BootLoader傳遞給內核的信息
==========================
LoongArch支持ACPI和FDT啓動,需要傳遞給內核的信息包括memmap、initrd、cmdline、可
選的ACPI/FDT表等。
內核在 `kernel_entry` 入口處被傳遞以下參數:
- a0 = efi_boot: `efi_boot` 是一個標誌,表示這個啓動環境是否完全符合UEFI
的要求。
- a1 = cmdline: `cmdline` 是一個指向內核命令行的指針。
- a2 = systemtable: `systemtable` 指向EFI的系統表,在這個階段涉及的所有
指針都是物理地址。
Linux/LoongArch內核鏡像文件頭
=============================
內核鏡像是EFI鏡像。作爲PE文件,它們有一個64字節的頭部結構體,如下所示::
u32 MZ_MAGIC /* "MZ", MS-DOS 頭 */
u32 res0 = 0 /* 保留 */
u64 kernel_entry /* 內核入口點 */
u64 _end - _text /* 內核鏡像有效大小 */
u64 load_offset /* 加載內核鏡像相對內存起始地址的偏移量 */
u64 res1 = 0 /* 保留 */
u64 res2 = 0 /* 保留 */
u64 res3 = 0 /* 保留 */
u32 LINUX_PE_MAGIC /* 魔術數 */
u32 pe_header - _head /* 到PE頭的偏移量 */
Annotation
- Atlas domain: Support Tooling And Documentation / Documentation.
- Implementation status: atlas-only.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.