Changes between Version 11 and Version 12 of jazz/09-05-08
- Timestamp:
- May 8, 2009, 5:29:32 PM (16 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
jazz/09-05-08
v11 v12 3 3 * [午餐] [http://www.ipeen.com.tw/shop/shop.php?id=15102 聯合泰國小吃店] 4 4 5 * 拉票喔!! SourceForge 2009 Community Choice Awards[[BR]][[Image(sf.net_cca09.jpg, width=400)]]5 * 拉票喔!! !SourceForge 2009 Community Choice Awards[[BR]][[Image(sf.net_cca09.jpg, width=400)]] 6 6 7 7 == File System : Lustre == … … 53 53 { 54 54 static int iopldone = 0; 55 56 #ifdef DEBUG 57 printf("inportb(0x%04x)\n", port); 58 #endif 55 unsigned int val=0; 59 56 60 57 if (port > 1024) { 61 58 if (!iopldone && iopl(3)) { 62 fprintf(stderr, "iopl(): %s\n", strerror(errno));63 return 1;59 fprintf(stderr, " iopl(): %s\n", strerror(errno)); 60 return 0; 64 61 } 65 62 iopldone++; 66 63 } else if (ioperm(port,size,1)) { 67 fprintf(stderr, " ioperm(%x): %s\n", port, strerror(errno));68 return 1;64 fprintf(stderr, " ioperm(%x): %s\n", port, strerror(errno)); 65 return 0; 69 66 } 70 67 71 if (size == 4) 72 return inl(port); 73 else if (size == 2) 74 return inw(port) & 0xffff; 75 else 76 return inb(port) & 0xff; 68 if (size == 4) { 69 val=inl(port); 70 #ifdef DEBUG 71 printf("Read_port:(0x%04x)=>0x%08x\n", port, val); 72 #endif 73 } else if (size == 2) { 74 val=inw(port); 75 #ifdef DEBUG 76 printf("Read_port:(0x%04x)=>0x%04x\n", port, val); 77 #endif 78 } else { 79 val=inb(port); 80 #ifdef DEBUG 81 printf("Read_port:(0x%04x)=>0x%02x\n", port, val); 82 #endif 83 } 84 return(val); 77 85 } 78 86 }}}