From 6804a8c89b8c31c3ef4e7e8ab03b82ebee41dd45 Mon Sep 17 00:00:00 2001 From: Michael Brown Date: Thu, 19 Apr 2018 12:38:55 +0100 Subject: [mii] Separate concepts of MII interface and MII device We currently have no generic concept of a PHY address, since all existing implementations simply hardcode the PHY address within the MII access methods. A bit-bashing MII interface will need to be provided with an explicit PHY address in order to generate the correct waveform. Allow for this by separating out the concept of a MII device (i.e. a specific PHY address attached to a particular MII interface). Signed-off-by: Michael Brown --- src/drivers/net/mii.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/drivers/net/mii.c') diff --git a/src/drivers/net/mii.c b/src/drivers/net/mii.c index 9b297029..f6db3074 100644 --- a/src/drivers/net/mii.c +++ b/src/drivers/net/mii.c @@ -37,10 +37,10 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL ); /** * Restart autonegotiation * - * @v mii MII interface + * @v mii MII device * @ret rc Return status code */ -int mii_restart ( struct mii_interface *mii ) { +int mii_restart ( struct mii_device *mii ) { int bmcr; int rc; @@ -66,12 +66,12 @@ int mii_restart ( struct mii_interface *mii ) { } /** - * Reset MII interface + * Reset MII device * - * @v mii MII interface + * @v mii MII device * @ret rc Return status code */ -int mii_reset ( struct mii_interface *mii ) { +int mii_reset ( struct mii_device *mii ) { unsigned int i; int bmcr; int rc; @@ -119,11 +119,11 @@ int mii_reset ( struct mii_interface *mii ) { /** * Update link status via MII * - * @v mii MII interface + * @v mii MII device * @v netdev Network device * @ret rc Return status code */ -int mii_check_link ( struct mii_interface *mii, struct net_device *netdev ) { +int mii_check_link ( struct mii_device *mii, struct net_device *netdev ) { int bmsr; int link; int rc; -- cgit v1.2.3-55-g7522