数据结构struct bus_type

struct bus_type {
const char *name;
struct bus_attribute *bus_attrs; // bus总线的默认属性
struct device_attribute * dev_attrs; // bus总线上设备的默认属性
struct driver_attribute *drv_attrs; // bus总线上设备驱动的默认属性
int (*match) (struct device *dev, struct device_driver *drv); // 当有新的设备或驱动添加到总线上时match函数被调用,如果设备和驱
//动可以匹配,返回0;
int (*uevent) (struct device *dev, struct kobj_uevent_env *env); //当一个设备添加、移除或添加环境变量时,函数调用;
int (*probe) (struct device *dev); // 当有新设备或驱动添加时,probe函数调用,并且回调该驱动的probe函数来初始化相关联的设备
int (*remove) (struct device *dev); // 设备移除时调用remove函数
int (*shutdown) (struct device *dev); // Called at shut-down time to quiesce the device.
int (*suspend) (struct device *dev, pm_message_t state); // 设备进入睡眠时调用suspend函数
int (*resume) (struct device *dev); // 唤醒设备时调用resume
const struct dev_pm_ops *pm; // 总线的电源管理选项,并回调设备驱动的电源管理模块
struct iommu_ops *iommu_ops; //
struct subsys_private *p;

};

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值