NVIDIA: SAUCE: net:phy: add new speeds
BugLink: https://bugs.launchpad.net/bugs/2072591 Add speed 2500 and 25000 support in phy http://nvbugs/4043836 Signed-off-by: Mahesh Patil <maheshp@nvidia.com> Reviewed-by: Narayan Reddy <narayanr@nvidia.com> Reviewed-by: Ashutosh Jha <ajha@nvidia.com> Reviewed-by: Satish Seelamsetti <sseelamsetti@nvidia.com> Tested-by: Satish Seelamsetti <sseelamsetti@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Acked-by: Jacob Martin <jacob.martin@canonical.com> Acked-by: Noah Wager <noah.wager@canonical.com> Signed-off-by: Noah Wager <noah.wager@canonical.com>
This commit is contained in:
+11
-1
@@ -8,7 +8,7 @@
|
||||
* Anton Vorontsov <avorontsov@ru.mvista.com>
|
||||
*
|
||||
* Copyright (c) 2006-2007 MontaVista Software, Inc.
|
||||
* Copyright (c) 2023, NVIDIA CORPORATION. All rights reserved.
|
||||
* Copyright (c) 2023-2024, NVIDIA CORPORATION. All rights reserved.
|
||||
*/
|
||||
#include <linux/export.h>
|
||||
#include <linux/mii.h>
|
||||
@@ -30,8 +30,10 @@ enum {
|
||||
SWMII_SPEED_10 = 0,
|
||||
SWMII_SPEED_100,
|
||||
SWMII_SPEED_1000,
|
||||
SWMII_SPEED_2500,
|
||||
SWMII_SPEED_5000,
|
||||
SWMII_SPEED_10000,
|
||||
SWMII_SPEED_25000,
|
||||
SWMII_DUPLEX_HALF = 0,
|
||||
SWMII_DUPLEX_FULL,
|
||||
};
|
||||
@@ -54,10 +56,14 @@ static const struct swmii_regs speed[] = {
|
||||
.lpagb = LPA_1000FULL | LPA_1000HALF,
|
||||
.estat = ESTATUS_1000_TFULL | ESTATUS_1000_THALF,
|
||||
},
|
||||
[SWMII_SPEED_2500] = {
|
||||
},
|
||||
[SWMII_SPEED_5000] = {
|
||||
},
|
||||
[SWMII_SPEED_10000] = {
|
||||
},
|
||||
[SWMII_SPEED_25000] = {
|
||||
},
|
||||
};
|
||||
|
||||
static const struct swmii_regs duplex[] = {
|
||||
@@ -78,10 +84,14 @@ static const struct swmii_regs duplex[] = {
|
||||
static int swphy_decode_speed(int speed)
|
||||
{
|
||||
switch (speed) {
|
||||
case 25000:
|
||||
return SWMII_SPEED_25000;
|
||||
case 10000:
|
||||
return SWMII_SPEED_10000;
|
||||
case 5000:
|
||||
return SWMII_SPEED_5000;
|
||||
case 2500:
|
||||
return SWMII_SPEED_2500;
|
||||
case 1000:
|
||||
return SWMII_SPEED_1000;
|
||||
case 100:
|
||||
|
||||
Reference in New Issue
Block a user