diff options
author | Kim Phillips <kim.phillips@freescale.com> | 2007-11-26 17:17:58 -0500 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2007-12-01 16:32:30 -0500 |
commit | bd0ceaab86d3f0e3916b3b7868cfe20de490eebc (patch) | |
tree | 3c9f9cc07bdd088d39944053137b2966f3f81663 /drivers | |
parent | 9daf5a7695f70b60c498aac079f908c81ffe4d15 (diff) |
ucc_geth: handle passing of RX-only and TX-only internal delay PHY connection type parameters
Extend the RGMII-Internal Delay specification case to include
TX-only and RX-only variants.
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Tested-by: Anton Vorontsov <avorontsov@ru.mvista.com>
Acked-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ucc_geth.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/net/ucc_geth.c b/drivers/net/ucc_geth.c index a3ff270593f1..7f689907ac28 100644 --- a/drivers/net/ucc_geth.c +++ b/drivers/net/ucc_geth.c | |||
@@ -1460,6 +1460,8 @@ static int adjust_enet_interface(struct ucc_geth_private *ugeth) | |||
1460 | if ((ugeth->phy_interface == PHY_INTERFACE_MODE_RMII) || | 1460 | if ((ugeth->phy_interface == PHY_INTERFACE_MODE_RMII) || |
1461 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII) || | 1461 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII) || |
1462 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII_ID) || | 1462 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII_ID) || |
1463 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII_RXID) || | ||
1464 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII_TXID) || | ||
1463 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RTBI)) { | 1465 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RTBI)) { |
1464 | upsmr |= UPSMR_RPM; | 1466 | upsmr |= UPSMR_RPM; |
1465 | switch (ugeth->max_speed) { | 1467 | switch (ugeth->max_speed) { |
@@ -1557,6 +1559,8 @@ static void adjust_link(struct net_device *dev) | |||
1557 | if ((ugeth->phy_interface == PHY_INTERFACE_MODE_RMII) || | 1559 | if ((ugeth->phy_interface == PHY_INTERFACE_MODE_RMII) || |
1558 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII) || | 1560 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII) || |
1559 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII_ID) || | 1561 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII_ID) || |
1562 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII_RXID) || | ||
1563 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RGMII_TXID) || | ||
1560 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RTBI)) { | 1564 | (ugeth->phy_interface == PHY_INTERFACE_MODE_RTBI)) { |
1561 | if (phydev->speed == SPEED_10) | 1565 | if (phydev->speed == SPEED_10) |
1562 | upsmr |= UPSMR_R10M; | 1566 | upsmr |= UPSMR_R10M; |
@@ -3795,6 +3799,10 @@ static phy_interface_t to_phy_interface(const char *phy_connection_type) | |||
3795 | return PHY_INTERFACE_MODE_RGMII; | 3799 | return PHY_INTERFACE_MODE_RGMII; |
3796 | if (strcasecmp(phy_connection_type, "rgmii-id") == 0) | 3800 | if (strcasecmp(phy_connection_type, "rgmii-id") == 0) |
3797 | return PHY_INTERFACE_MODE_RGMII_ID; | 3801 | return PHY_INTERFACE_MODE_RGMII_ID; |
3802 | if (strcasecmp(phy_connection_type, "rgmii-txid") == 0) | ||
3803 | return PHY_INTERFACE_MODE_RGMII_TXID; | ||
3804 | if (strcasecmp(phy_connection_type, "rgmii-rxid") == 0) | ||
3805 | return PHY_INTERFACE_MODE_RGMII_RXID; | ||
3798 | if (strcasecmp(phy_connection_type, "rtbi") == 0) | 3806 | if (strcasecmp(phy_connection_type, "rtbi") == 0) |
3799 | return PHY_INTERFACE_MODE_RTBI; | 3807 | return PHY_INTERFACE_MODE_RTBI; |
3800 | 3808 | ||
@@ -3889,6 +3897,8 @@ static int ucc_geth_probe(struct of_device* ofdev, const struct of_device_id *ma | |||
3889 | case PHY_INTERFACE_MODE_GMII: | 3897 | case PHY_INTERFACE_MODE_GMII: |
3890 | case PHY_INTERFACE_MODE_RGMII: | 3898 | case PHY_INTERFACE_MODE_RGMII: |
3891 | case PHY_INTERFACE_MODE_RGMII_ID: | 3899 | case PHY_INTERFACE_MODE_RGMII_ID: |
3900 | case PHY_INTERFACE_MODE_RGMII_RXID: | ||
3901 | case PHY_INTERFACE_MODE_RGMII_TXID: | ||
3892 | case PHY_INTERFACE_MODE_TBI: | 3902 | case PHY_INTERFACE_MODE_TBI: |
3893 | case PHY_INTERFACE_MODE_RTBI: | 3903 | case PHY_INTERFACE_MODE_RTBI: |
3894 | max_speed = SPEED_1000; | 3904 | max_speed = SPEED_1000; |