Opened 14 years ago
Last modified 14 years ago
#57 new task
Rework device API: one device in many classes
Reported by: | Nicolas Pouillon | Owned by: | Nicolas Pouillon |
---|---|---|---|
Priority: | blocker | Milestone: | Topology handling |
Component: | drivers | Keywords: | |
Cc: |
Description
We currently have a problem with devices that are in more than one driver class at the same time. We have to split them in subdevices, even if it is incorrect.
Some examples:
- CPU nodes are also ICUs
- soclib Xicu is timer and ICU
There once was a discussion about allowing devices to implement more than one class at the same time. How to do this ?
Attachments (1)
Change History (2)
Note: See
TracTickets for help on using
tickets.
Could we do something like:
API proposal
Accessing functions of a given class
Example for implementing a generic function of class BAR
Rationale
Added from current code, there is a new indirection through
drv->funcs_offset
.driver_class_funcs
return&funcs[0]
if there is no support for multiple drivers per device.Is this acceptable ?