字符设备驱动程序由哪几部分组成

日期:2022-03-28 20:38:40 人气:1

字符设备驱动程序由哪几部分组成

字符设备驱动程序框架
1、写出open、write函数
2、告诉内核
1)、定义一个struct file_operations结构并填充好
static struct file_operations first_drv_fops = {
.owner = THIS_MODULE, /* 这是一个宏,推向编译模块时自动创建的__this_mod
    A+
热门评论