📄 main.c,v
字号:
{ "md", 0x0900 }, #endif #ifdef CONFIG_BLK_DEV_XD { "xda", 0x0d00 }, { "xdb", 0x0d40 },#endif#ifdef CONFIG_BLK_DEV_RAM { "ram", 0x0100 },#endif#ifdef CONFIG_BLK_DEV_SR { "scd", 0x0b00 },#endif#ifdef CONFIG_MCD { "mcd", 0x1700 },#endif#ifdef CONFIG_CDU535 { "cdu535", 0x1800 }, { "sonycd", 0x1800 },#endif#ifdef CONFIG_AZTCD { "aztcd", 0x1d00 },#endif#ifdef CONFIG_CM206 { "cm206cd", 0x2000 },#endif#ifdef CONFIG_GSCD { "gscd", 0x1000 },#endif#ifdef CONFIG_SBPCD { "sbpcd", 0x1900 },#endif#ifdef CONFIG_BLK_DEV_PS2 { "eda", 0x2400 }, { "edb", 0x2440 },#endif#ifdef CONFIG_PARIDE_PD { "pda", 0x2d00 }, { "pdb", 0x2d10 }, { "pdc", 0x2d20 }, { "pdd", 0x2d30 },#endif#ifdef CONFIG_PARIDE_PCD { "pcd", 0x2e00 },#endif#ifdef CONFIG_PARIDE_PF { "pf", 0x2f00 },#endif#if CONFIG_APBLOCK { "apblock", APBLOCK_MAJOR << 8},#endif#if CONFIG_DDV { "ddv", DDV_MAJOR << 8},#endif { NULL, 0 }};kdev_t __init name_to_kdev_t(char *line){ int base = 0; if (strncmp(line,"/dev/",5) == 0) { struct dev_name_struct *dev = root_dev_names; line += 5; do { int len = strlen(dev->name); if (strncmp(line,dev->name,len) == 0) { line += len; base = dev->num; break; } dev++; } while (dev->name); } return to_kdev_t(base + simple_strtoul(line,NULL,base?10:16));}static void __init root_dev_setup(char *line, int *num){ ROOT_DEV = name_to_kdev_t(line);}/* * List of kernel command line parameters. The first table lists parameters * which are subject to values parsing (leading numbers are converted to * an array of ints and chopped off the string), the second table contains * the few exceptions which obey their own syntax rules. */struct kernel_param { const char *str; void (*setup_func)(char *, int *);};static struct kernel_param cooked_params[] __initdata = {/* FIXME: make PNP just become reserve_setup */#ifndef CONFIG_KERNEL_PNP_RESOURCE { "reserve=", reserve_setup },#else { "reserve=", pnp_reserve_setup },#endif { "profile=", profile_setup },#ifdef __SMP__ { "nosmp", smp_setup }, { "maxcpus=", smp_setup },#ifdef CONFIG_X86_IO_APIC { "noapic", ioapic_setup }, { "pirq=", ioapic_pirq_setup },#endif#endif#ifdef CONFIG_BLK_DEV_RAM { "ramdisk_start=", ramdisk_start_setup }, { "load_ramdisk=", load_ramdisk }, { "prompt_ramdisk=", prompt_ramdisk }, { "ramdisk=", ramdisk_size }, { "ramdisk_size=", ramdisk_size },#ifdef CONFIG_BLK_DEV_INITRD { "noinitrd", no_initrd },#endif#endif#ifdef CONFIG_FB { "video=", video_setup },#endif { "panic=", panic_setup }, { "console=", console_setup },#ifdef CONFIG_VGA_CONSOLE { "no-scroll", no_scroll },#endif#ifdef CONFIG_MDA_CONSOLE { "mdacon=", mdacon_setup },#endif#ifdef CONFIG_VT { "kbd-reset", kbd_reset_setup },#endif#ifdef CONFIG_BUGi386 { "no-hlt", no_halt }, { "no387", no_387 }, { "reboot=", reboot_setup },#endif#ifdef CONFIG_INET { "ether=", eth_setup },#endif#ifdef CONFIG_ARCNET_COM20020 { "com20020=", com20020_setup },#endif#ifdef CONFIG_ARCNET_RIM_I { "arcrimi=", arcrimi_setup },#endif#ifdef CONFIG_ARCNET_COM90xxIO { "com90io=", com90io_setup },#endif#ifdef CONFIG_ARCNET_COM90xx { "com90xx=", com90xx_setup },#endif#ifdef CONFIG_DECNET { "decnet=", decnet_setup },#endif#ifdef CONFIG_PRINTER { "lp=", lp_setup },#endif#ifdef CONFIG_JOY_AMIGA { "js_am=", js_am_setup },#endif#ifdef CONFIG_JOY_ANALOG { "js_an=", js_an_setup },#endif#ifdef CONFIG_JOY_ASSASIN { "js_as=", js_as_setup },#endif#ifdef CONFIG_JOY_CONSOLE { "js_console=", js_console_setup }, { "js_console2=", js_console_setup }, { "js_console3=", js_console_setup },#endif#ifdef CONFIG_JOY_DB9 { "js_db9=", js_db9_setup }, { "js_db9_2=", js_db9_setup }, { "js_db9_3=", js_db9_setup },#endif#ifdef CONFIG_JOY_TURBOGRAFX { "js_tg=", js_tg_setup }, { "js_tg_2=", js_tg_setup }, { "js_tg_3=", js_tg_setup },#endif#ifdef CONFIG_SCSI { "max_scsi_luns=", scsi_luns_setup }, { "scsi_logging=", scsi_logging_setup },#endif#ifdef CONFIG_JOY_LIGHTNING { "js_l4=", js_l4_setup },#endif#ifdef CONFIG_SCSI_ADVANSYS { "advansys=", advansys_setup },#endif#if defined(CONFIG_BLK_DEV_HD) { "hd=", hd_setup },#endif#ifdef CONFIG_CHR_DEV_ST { "st=", st_setup },#endif#ifdef CONFIG_BUSMOUSE { "bmouse=", bmouse_setup },#endif#ifdef CONFIG_MS_BUSMOUSE { "msmouse=", msmouse_setup },#endif#ifdef CONFIG_SCSI_SEAGATE { "st0x=", st0x_setup }, { "tmc8xx=", tmc8xx_setup },#endif#ifdef CONFIG_SCSI_T128 { "t128=", t128_setup },#endif#ifdef CONFIG_SCSI_PAS16 { "pas16=", pas16_setup },#endif#ifdef CONFIG_SCSI_GENERIC_NCR5380 { "ncr5380=", generic_NCR5380_setup }, { "ncr53c400=", generic_NCR53C400_setup }, { "ncr53c400a=", generic_NCR53C400A_setup }, { "dtc3181e=", generic_DTC3181E_setup },#endif#ifdef CONFIG_SCSI_AHA152X { "aha152x=", aha152x_setup},#endif#ifdef CONFIG_SCSI_AHA1542 { "aha1542=", aha1542_setup},#endif#ifdef CONFIG_SCSI_GDTH { "gdth=", gdth_setup},#endif#ifdef CONFIG_SCSI_AIC7XXX { "aic7xxx=", aic7xxx_setup},#endif#ifdef CONFIG_SCSI_BUSLOGIC { "BusLogic=", BusLogic_Setup},#endif#ifdef CONFIG_SCSI_NCR53C8XX { "ncr53c8xx=", ncr53c8xx_setup},#endif#ifdef CONFIG_SCSI_SYM53C8XX { "sym53c8xx=", sym53c8xx_setup},#endif#ifdef CONFIG_SCSI_EATA { "eata=", eata2x_setup},#endif#ifdef CONFIG_SCSI_U14_34F { "u14-34f=", u14_34f_setup},#endif#ifdef CONFIG_SCSI_AM53C974 { "AM53C974=", AM53C974_setup},#endif#ifdef CONFIG_SCSI_NCR53C406A { "ncr53c406a=", NCR53c406a_setup},#endif#ifdef CONFIG_SCSI_SYM53C416 { "sym53c416=", sym53c416_setup},#endif#ifdef CONFIG_SCSI_FUTURE_DOMAIN { "fdomain=", fdomain_setup},#endif#ifdef CONFIG_SCSI_IN2000 { "in2000=", in2000_setup},#endif#ifdef CONFIG_SCSI_7000FASST { "wd7000=", wd7000_setup},#endif#ifdef CONFIG_SCSI_IBMMCA { "ibmmcascsi=", ibmmca_scsi_setup },#endif#if defined(CONFIG_SCSI_DC390T) && ! defined(CONFIG_SCSI_DC390T_NOGENSUPP) { "tmscsim=", dc390_setup },#endif#ifdef CONFIG_BLK_DEV_XD { "xd=", xd_setup }, { "xd_geo=", xd_manual_geo_init },#endif#if defined(CONFIG_BLK_DEV_FD) || defined(CONFIG_AMIGA_FLOPPY) || defined(CONFIG_ATARI_FLOPPY) { "floppy=", floppy_setup },#endif#ifdef CONFIG_BLK_DEV_PS2 { "eda=", ed_setup }, { "edb=", ed_setup }, { "tp720=", tp720_setup },#endif#ifdef CONFIG_CDU31A { "cdu31a=", cdu31a_setup },#endif CONFIG_CDU31A#ifdef CONFIG_MCD { "mcd=", mcd_setup },#endif CONFIG_MCD#ifdef CONFIG_MCDX { "mcdx=", mcdx_setup },#endif CONFIG_MCDX#ifdef CONFIG_SBPCD { "sbpcd=", sbpcd_setup },#endif CONFIG_SBPCD#ifdef CONFIG_AZTCD { "aztcd=", aztcd_setup },#endif CONFIG_AZTCD#ifdef CONFIG_CDU535 { "sonycd535=", sonycd535_setup },#endif CONFIG_CDU535#ifdef CONFIG_GSCD { "gscd=", gscd_setup },#endif CONFIG_GSCD#ifdef CONFIG_CM206 { "cm206=", cm206_setup },#endif CONFIG_CM206#ifdef CONFIG_OPTCD { "optcd=", optcd_setup },#endif CONFIG_OPTCD#ifdef CONFIG_SJCD { "sjcd=", sjcd_setup },#endif CONFIG_SJCD#ifdef CONFIG_ISP16_CDI { "isp16=", isp16_setup },#endif CONFIG_ISP16_CDI#ifdef CONFIG_SOUND_OSS { "sound=", sound_setup },#endif#ifdef CONFIG_ISDN_DRV_ICN { "icn=", icn_setup },#endif#ifdef CONFIG_ISDN_DRV_HISAX { "hisax=", HiSax_setup }, { "HiSax=", HiSax_setup },#endif#ifdef CONFIG_ISDN_DRV_PCBIT { "pcbit=", pcbit_setup },#endif#ifdef CONFIG_ATARIMOUSE { "atamouse=", atari_mouse_setup },#endif#ifdef CONFIG_DMASOUND { "dmasound=", dmasound_setup },#endif#ifdef CONFIG_ATARI_SCSI { "atascsi=", atari_scsi_setup },#endif#ifdef CONFIG_STRAM_SWAP { "stram_swap=", stram_swap_setup },#endif#if defined(CONFIG_A4000T_SCSI) || defined(CONFIG_WARPENGINE_SCSI) \ || defined(CONFIG_A4091_SCSI) || defined(CONFIG_MVME16x_SCSI) \ || defined(CONFIG_BVME6000_SCSI) { "53c7xx=", ncr53c7xx_setup },#endif#if defined(CONFIG_A3000_SCSI) || defined(CONFIG_A2091_SCSI) \ || defined(CONFIG_GVP11_SCSI) { "wd33c93=", wd33c93_setup },#endif#if defined(CONFIG_GVP11_SCSI) { "gvp11=", gvp11_setup },#endif#ifdef CONFIG_MAC_SCSI { "mac5380=", mac_scsi_setup },#endif#ifdef CONFIG_CYCLADES { "cyclades=", cy_setup },#endif#ifdef CONFIG_DIGI { "digi=", pcxx_setup },#endif#ifdef CONFIG_DIGIEPCA { "digiepca=", epca_setup },#endif#ifdef CONFIG_RISCOM8 { "riscom8=", riscom8_setup },#endif#ifdef CONFIG_DMASCC { "dmascc=", dmascc_setup },#endif#ifdef CONFIG_SPECIALIX { "specialix=", specialix_setup },#endif#ifdef CONFIG_BAYCOM_PAR { "baycom_par=", baycom_par_setup },#endif#ifdef CONFIG_BAYCOM_SER_FDX { "baycom_ser_fdx=", baycom_ser_fdx_setup },#endif#ifdef CONFIG_BAYCOM_SER_HDX { "baycom_ser_hdx=", baycom_ser_hdx_setup },#endif#ifdef CONFIG_SOUNDMODEM { "soundmodem=", sm_setup },#endif#ifdef CONFIG_WDT { "wdt=", wdt_setup },#endif#ifdef CONFIG_PARPORT { "parport=", parport_setup },#endif#ifdef CONFIG_PLIP { "plip=", plip_setup },#endif#ifdef CONFIG_HFMODEM { "hfmodem=", hfmodem_setup },#endif#ifdef CONFIG_FTAPE { "ftape=", ftape_setup},#endif#ifdef CONFIG_MD_BOOT { "md=", md_setup},#endif#ifdef CONFIG_ADBMOUSE { "adb_buttons=", adb_mouse_setup },#endif#ifdef CONFIG_LTPC { "ltpc=", ltpc_setup },#endif { 0, 0 }};static struct kernel_param raw_params[] __initdata = { { "root=", root_dev_setup },#ifdef CONFIG_ROOT_NFS { "nfsroot=", nfs_root_setup }, { "nfsaddrs=", ip_auto_config_setup },#endif#ifdef CONFIG_IP_PNP { "ip=", ip_auto_config_setup },#endif#ifdef CONFIG_PCI { "pci=", pci_setup },#endif#ifdef CONFIG_PARIDE_PD { "pd.", pd_setup },#endif#ifdef CONFIG_PARIDE_PCD { "pcd.", pcd_setup },#endif#ifdef CONFIG_PARIDE_PF { "pf.", pf_setup },#endif#ifdef CONFIG_PARIDE_PT { "pt.", pt_setup },#endif#ifdef CONFIG_PARIDE_PG { "pg.", pg_setup },#endif#ifdef CONFIG_APM { "apm=", apm_setup },#endif { 0, 0 }};#ifdef CONFIG_BLK_DEV_RAMstatic void __init ramdisk_start_setup(char *str, int *ints){ if (ints[0] > 0 && ints[1] >= 0) rd_image_start = ints[1];}static void __init load_ramdisk(char *str, int *ints){ if (ints[0] > 0 && ints[1] >= 0) rd_doload = ints[1] & 1;}static void __init prompt_ramdisk(char *str, int *ints){ if (ints[0] > 0 && ints[1] >= 0) rd_prompt = ints[1] & 1;}static void __init ramdisk_size(char *str, int *ints){ if (ints[0] > 0 && ints[1] >= 0) rd_size = ints[1];}#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -