#include <sys/io.h>
#include <stdio.h>
#include <sys/io.h>
#include <unistd.h>
int main()
{
iopl(5);//permission
outb(0Xf5,0X64);//writting to port to disable
printf("keyboard disabled");
sleep(1000);
printf("keyboard enabled");
outb(0Xf4,0X64);
}
在禁用/启用代码时获取分段错误但我没有得到我错的地方。请检查!