Linux 0.11内核main函数
来源:互联网 发布:linux ntp启动 编辑:程序博客网 时间:2024/05/29 04:15
Linux 0.11内核main函数
void main(void) /* This really IS void, no error here. */
{ /* The startup routine assumes (well, ...) this */
/*
* Interrupts are still disabled. Do necessary setups, then
* enable them
*/
ROOT_DEV = ORIG_ROOT_DEV;
drive_info = DRIVE_INFO;
memory_end = (1<<20) + (EXT_MEM_K<<10);
memory_end &= 0xfffff000;
if (memory_end > 16*1024*1024)
memory_end = 16*1024*1024;
if (memory_end > 12*1024*1024)
buffer_memory_end = 4*1024*1024;
else if (memory_end > 6*1024*1024)
buffer_memory_end = 2*1024*1024;
else
buffer_memory_end = 1*1024*1024;
main_memory_start = buffer_memory_end;
#ifdef RAMDISK
main_memory_start += rd_init(main_memory_start, RAMDISK*1024);
#endif
mem_init(main_memory_start,memory_end);
trap_init();
blk_dev_init();
chr_dev_init();
tty_init();
time_init();
sched_init();
buffer_init(buffer_memory_end);
hd_init();
floppy_init();
sti();
move_to_user_mode();
if (!fork()) { /* we count on this going ok */
init();
}
/*
* NOTE!! For any other task 'pause()' would mean we have to get a
* signal to awaken, but task0 is the sole exception (see 'schedule()')
* as task 0 gets activated at every idle moment (when no other tasks
* can run). For task0 'pause()' just means we go check if some other
* task can run, and if not we return here.
*/
for(;;) pause();
}
- Linux 0.11内核main函数
- linux 0.11 内核学习 -- main.c,调用函数而已。
- 《第一篇 从linux 0.11系统初始化main.c的fork()函数调用分析内核源码》
- Linux内核学习笔记之main函数(四)
- Linux内核学习笔记之main函数(四)
- linux内核设计的艺术-开始执行main函数
- 从开机加电到执行main函数之前的过程+读Linux内核设计艺术..
- linux内核(v0.11)-从开机加电执行到main函数前
- Linux内核设计的艺术(第一章,从开机加电到执行main函数之前的过程)
- Linux内核设计的艺术-从开机加电到执行main函数之前的过程
- Linux 0.12内核从开机加电到执行main函数之前的过程
- Linux0.12内核main函数剖析
- Linux内核的开始main.c
- linux c main函数参数
- linux c main函数参数
- Linux如何执行main()函数
- linux下的main 函数
- linux内核学习-3 main函数(关注新浪微博:寂寞侵蚀的岁月(4000多篇技术分享))
- 地震后到学校放假E(EarthQuake 11)
- Delphi分割字符串的函数ExtractStrings
- 利用Rownum对数据按GridView 的PageSize进行划分,为分页显示做准备
- 在VC中用ADO动态创建带密码的Access数据库
- 《语义网》译文(TIM BERNERS-LEE, JAMES HENDLER and ORA LASSILA )
- Linux 0.11内核main函数
- 在MFC下使用OpenGL的一个简单的例子(转)
- IIS控制大全
- Linux 下配置Expat解析XML
- 判断一个字符是否为汉字的最佳方法[转]
- 统计1到n之间的所有数字中1出现的个数
- TCP/IP 协议之 UDP协议
- Oracle数据库对象管理(实例介绍)
- 推荐100首值得听的英文歌