往期内容
I2C子系统专栏:
- I2C(IIC)协议讲解-CSDN博客
- SMBus 协议详解-CSDN博客
- I2C相关结构体讲解:i2c_adapter、i2c_algorithm、i2c_msg-CSDN博客
- 内核提供的通用I2C设备驱动I2c-dev.c分析:注册篇
总线和设备树专栏:
前言
在上一篇,注册篇中,从讲解普通的字符设备驱动框架后再讲解了关于i2c-dev.c中是如何去注册字符设备驱动的,接下来就讲解关于其file_operations中定义的函数是如何去实现的。
内核中提供的驱动文件: Linux-4.9.88/drivers/i2c/i2c-dev.c