1.内核态中实现poll接口 使用poll_wait 添加到 队列中,用户态使用poll 获取状态
2.fasync 异步信号,在内核中中断回调函数中实现fasync 接口,fasync 中fasync_helper和kill_fasync等接口,添加到异步通知队列中,用户态只要open 这个设备结点signal(SIGIO, input_handler); //让input_handler()处理SIGIO信号
|
WorkingNotes
一个野生程序猿 |
|
|