1、U_BOOT_CMD( bootm, CFG_MAXARGS, 1,do_bootm, "bootm - boot application image from memory
", "[addr [arg ...]]
- boot application image stored in memory
" " passing arguments "arg ..."; when booting a Linux kernel,
" " "arg" can be the address of an initrd image
" #ifdef CONFIG_OF_FLAT_TREE " When booting a Linux kernel which requires a flat device-tree
" " a third argument is required which is the address of the of the
" " device-tree blob. To boot that kernel without an initrd image,
" " use a "-" for the second argument. If you do not pass a third
" " a bd_info struct will be passed instead
" #endif ); 根据上面可知:bootm命令的执行函数是do_bootm,函数的最大参数是CFG_MAXARGS。U-Boot源代码下载地址 http://www.linuxidc.com/Linux/2011-07/38897.htm2、do_bootm函数源码摘要:SHOW_BOOT_PROGRESS (8);
#if defined(CONFIG_ZIMAGE_BOOT) || defined(CONFIG_IMAGE_BOOT) after_header_check: #endif switch (hdr->ih_os) { default: /* handled by (original) Linux case */ case IH_OS_LINUX: #ifdef CONFIG_SILENT_CONSOLE fixup_silent_linux(); #endif do_bootm_linux (cmdtp, flag, argc, argv, addr, len_ptr, verify); break; case IH_OS_NETBSD: do_bootm_netbsd (cmdtp, flag, argc, argv, addr, len_ptr, verify); break;