Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

LinuxµÄÄÚºËÑÓ³Ùº¯Êý

µ±ÄÚºËÐèÒªµÈ´ýÒ»¸ö±È½Ï¶ÌµÄʱ¼ä¼ä¸ôʱ£¬±È·½Ëµ£ºÓÐʱºòÉ豸Çý¶¯Æ÷»áµÈ´ýÔ¤Ïȶ¨ÒåµÄÈô¸É¸ö΢ÃîµÄʱ¼äÖ±µ½Ó²¼þÍê³ÉijЩ²Ù×÷¡£ÓÉÓÚ¶¯Ì¬¶¨Ê±Æ÷ͨ³£ÓкܴóµÄÉèÖÿªÏúºÍÒ»¸öÏ൱´óµÄ×îСµÈ´ýʱ¼ä£¨1ms£©£¬ËùÒÔÉ豸Çý¶¯Æ÷ʹÓÃËü»áºÜ²»·½±ã¡£
ÔÚÕâЩÇé¿öÏ£¬ÄÚºËʹÓÃudelay£¨£©ºÍndelay£¨£©º¯Êý£ºÇ°Õß½ÓÊÕÒ»¸ö΢ÃµÄʱ¼ä¼ä¸ô×÷ΪËüµÄ²ÎÊý£¬²¢ÔÚÖ¸¶¨µÄÑÓ³Ù½áÊøºó·µ»Ø£»¶øºóÕßËù½ÓÊÕµÄÖ¸¶¨ÑӳٵIJÎÊýÊÇÄÉÃ뼶µÄ£¬Í¬ÑùÔÚÖ¸¶¨µÄÑÓ³Ù½áÊøºó·µ»Ø¡£
udelay£¨£©ºÍndelay£¨£©ÕâÁ½¸öº¯Êý¶¨ÒåÈçÏ£º
void udelay(unsigned long usecs)
{
    unsigned long loops;
    loops = (usecs*HZ*current_cpu_data.loops_per_jiffy)/1000000;
    cur_timer->delay(loops);
}
void ndelay(unsigned long nsecs)
{
    unsigned long loops;
    loops = (nsecs*HZ*current_cpu_data.loops_per_jiffy)/1000000000;
    cur_timer->delay(loops);
}
    ÕâÁ½¸öº¯Êý¶¼ÊÇÒÀÀµÓëcur_timer¶¨Ê±Æ÷¶ÔÏóµÄdelay·½·¨£¬Ëü½ÓÊÕ“loops”ÖеÄʱ¼ä¼ä¸ô×÷Ϊ²ÎÊý¡£Ã¿Ò»´Î“loop”¾«È·µÄ³ÖÐøʱ¼äÈ¡¾öÓÚcur_timerÉæ¼°µÄ¶¨Ê±Æ÷¶ÔÏó¡£
¡¾Èç¹ûcur_timerÖ¸Ïòtime_hpet¡¢time_pmtmrºÍtimer_tsc¶ÔÏó£¬ÄÇôһ´Î“loop”ʱ¼ä¶ÔÓ¦Ò»¸öCPUÑ­»·——Ò²¾ÍÊÇÁ½¸öÁ¬ÐøCPUʱÖÓÐźżäµÄʱ¼ä¼ä¸ô¡£¡¿
¡¾Èç¹ûcur_timerÖ¸Ïòtimer_none»òtimer_pit¶ÔÏó£¬ÄÇôһ´Î“loop”ʱ¼ä¶ÔÓ¦Ò»Ìõ½ô´ÕÖ¸ÁîÑ­»·ÔÚÒ»´Îµ¥¶ÀµÄÑ­»·ÖÐËù»¨·ÑµÄʱ¼ä¡£¡¿
     ʼ»¯½×¶Î£¬select_timer()ÉèÖúÃcur_timerºó£¬ÄÚºËͨ¹ýÖ´ÐÐcalibrate_delay()º¯ÊýÀ´¾ö¶¨Ò»¸ö½ÚÅÄÀïÓжàÉٴΓloop”¡£Õâ¸öÖµ±»±£´æÔÚcurrent_cpu_data.loops_per_jiffy±äÁ¿ÖУ¬ÕâÑùudelay()ºÍndelay()¾ÍÄܸù¾ÝËüÀ´°Ñ΢ÃîºÍÄÉÃëת»»³É“loops”¡£


Ïà¹ØÎĵµ£º

Ô¶ÀëWindows,ʹÓÃLinux/Unix

2005Äê9ÔÂ22ÈÕ£¬Ç廪ÔÚ¶Á²©Ê¿ÉúÍõÛóÔÚˮľÉçÇøBLOGÉÏ·¢±íÁË¡¶Ç廪ÃεķÛËé--д¸øÇ廪´óѧµÄÍËѧÉêÇë¡·Ã÷È·ÒªÇóÍËѧ, ÒýÆðÉç»á¸÷½ç¹ã·ºÕùÂÛ. Ëû´´×÷µÄ³¤ÆªÎÄÕ¡¶ÍêÈ«ÓÃLinux¹¤×÷¡·, ÑóÑóÁ½Íò¶à×Ö, ´Ó²»Í¬½Ç¶È¾Ó¸ßÁÙϵIJûÊöÁËËûÑÛÖÐLinuxÍêÈ«ÓÅÔ½ÓÚWindowsµÄ¸÷ÖÖÀíÓÉ, ÕâƪÎÄÕ²¢²»¼òµ¥µÄÊÇһƪÂÛÊö"WindowsÄÜ×öµÄÊÂLinux¶¼Ä ......

Linux»·¾³½ø³Ì¼äͨÐÅ


Linux»·¾³½ø³Ì¼äͨÐÅ£¨Ò»£©
¹ÜµÀ¼°ÓÐÃû¹ÜµÀ
Ö£ÑåÐË (mlinux@163.com)¹ú·À¿Æ´ó¼ÆËã»úѧԺ
2002 Äê 12 ÔÂ 11 ÈÕ
ÔÚ±¾ÏµÁÐÐòÖÐ×÷Õ߸ÅÊöÁË linux ½ø³Ì¼äͨÐŵļ¸ÖÖÖ÷ÒªÊֶΡ£ÆäÖйܵÀºÍÓÐÃû¹ÜµÀÊÇ×îÔçµÄ½ø³Ì¼äͨÐÅ»úÖÆÖ®Ò»£¬¹ÜµÀ¿ÉÓÃÓÚ¾ßÓÐÇ×Ôµ¹Øϵ½ø³Ì¼äµÄͨÐÅ£¬ÓÐÃû¹ÜµÀ¿Ë·þÁ˹ܵÀûÓÐÃû×ÖµÄÏÞÖÆ£¬Òò´Ë£¬³ý¾ßÓйܵ ......

wmware linux Íø¿¨ÎÊÌâ

Device eth0 has different MAC address than expected
   Ç°ÌìÔÚŪVMwareµÄʱºò,ÔÚVMwareÉÏcloneÁËÒ»¸ölinux,ºóÀ´ÔÚcloneµÄlinux(RedHat Enterprise Linux 4)Éϲ»ÄÜÉÏÍøÁË,¼¤»îeth0ʱÀϵ¯³ö Device eth0 has different MAC address than expected ,ÎÒÃÇÖ»Òª±à¼­Õâ¸öÎļþ:/etc/sysconfig/network-scripts/ifcfg- ......

VMwareÏÂWindowsÓëLinuxÎļþ¹²Ïí

´Ë´¦vmware°æ±¾Îª6.5 £¬Ö÷»úΪwindows xp,vmware °²×°ÁËredhat linux
1.ÍøÂçÉèÖãº
´ò¿ªvmware,µãvmware->setting->Hardware->Newwork Adapter->Custom - >
VMnet1(host-only) 
²é¿´windowsÍøÂçÁ¬½Ó,¿´µ½Ò»¸öVMnet1µÄÁ¬½Ó,ÉèÖÃËüµÄipÓë×ÓÍøÑÚÂë¡£Èç:IP:192.168.13.1 ,×ÓÍøÑÚÂë 255.255.255.0 ......

LinuxÏÂRamdisk¸ùÎļþϵͳÖÆ×÷¹ý³Ì½âÎö

  http://blog.csdn.net/hzdysymbol/archive/2009/01/17/3796814.aspxÒ»¡¢ÔÚÒ»¸öÒѽ¨ºÃµÄÎļþϵͳÉϽøÐÐÐÞ¸Ä
    ÉèÒѽ¨Á¢ºÃµÄÎļþϵͳѹËõÎļþΪramdisk.gz
    1¡¢½âѹ
    #cd ramdisk.gzËùÔÚĿ¼
    #gunzip ramdisk.gz
    Ô ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ