phylib: rework to prepare for OF registration of PHYs
authorGrant Likely <[email protected]>
Sat, 25 Apr 2009 12:52:46 +0000 (12:52 +0000)
committerDavid S. Miller <[email protected]>
Mon, 27 Apr 2009 09:53:45 +0000 (02:53 -0700)
commit4dea547fef1ba23f9d23f5e7f5218187a7dcf1b3
tree5d3ef6350d21c5a8ad952ef6f89f7d47099caf0a
parent739649c53d7f78f5bf41bdfd1a858ee90c7a687a
phylib: rework to prepare for OF registration of PHYs

This patch makes changes in preparation for supporting open firmware
device tree descriptions of MDIO busses.  Changes include:
- Cleanup handling of phy_map[] entries; they are already NULLed when
  registering and so don't need to be re-cleared, and it is good practice
  to clear them out when unregistering.
- Split phy_device registration out into a new function so that the
  OF helpers can do two stage registration (separate allocation and
  registration steps).

Signed-off-by: Grant Likely <[email protected]>
Acked-by: Andy Fleming <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
drivers/net/phy/mdio_bus.c
drivers/net/phy/phy_device.c
include/linux/phy.h