• Patrick Mochel's avatar
    driver model: simplify device/driver binding. · 007aa553
    Patrick Mochel authored
    - move list walking and matching to bus.c (since it's a function of the bus driver)
    - do specialized walks of the bus's lists when binding; no more callbacks being passed
      to bus_for_each_*.
    - take rwsem when adding and removing both devices and drivers. lists of each are now
      fully protected by that rwsem. It's also taken before we walk each list.
    - move calls of device_{de,at}tach() to bus_{add,remove}_device() and calls of 
      driver_{de,at}tach() to bus_{add,remove}_driver().
    007aa553
bus.c 7.15 KB