- 论坛徽章:
- 0
|
本帖最后由 chunchengfh 于 2012-04-17 11:18 编辑
在操作端口0x70的时候,输入值的最高位(即0x80 = 0b10000000)控制了CPU的NMI的启用与否;
这是一个设置或者不设置的问题,没办法保持其原来的值不变
用0x80|addr表示关闭NMI
这个设计和A20(用键盘端口控制1M内存访问范围)一样,是当年为了节省一点资源而将八竿子打不着的两样东东混合到一起的设计结果
网上的解释:
Whenever you send a byte to IO port 0x70, the high order bit tells the hardware whether to disable NMIs from reaching the CPU. If the bit is on, NMI is disabled (until the next time you send a byte to Port 0x70). The low order 7 bits of any byte sent to Port 0x70 are used to address CMOS registers. |
|