My question is about linux device model. I did some digging myself in the source code and found that the device model works around many structures out of which some of them are:
- struct device
- struct device_driver
- struct bus_type
- There are more related to power management.
But when I looked into the char drivers implemented in linux kernel (or if I implement my own char driver) linux kernel is only implementing "struct device" and all other structures are just NULL. I have checked this through some debugging and with friendly neighbourhood API printk().
So my question is then why char drivers are not completely following the device model?
Also which drivers are completely following linux device model?