summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMeco Man <[email protected]>2022-08-14 21:31:12 -0400
committerMan, Jianting (Meco) <[email protected]>2022-08-14 21:50:14 -0400
commitff310443b86164dd52beb62a15cd1919b0e8cdc0 (patch)
tree0ce00a7211ff0492ca6a4b15531dc466ff0b72aa
parent4537d06afbf621dad32cc079f4b567c11963b785 (diff)
[nxp] move phy driver into drivers folder
-rw-r--r--bsp/imxrt/libraries/drivers/SConscript2
-rw-r--r--bsp/imxrt/libraries/drivers/drv_ksz8081.c (renamed from bsp/imxrt/libraries/peripherals/phyksz8081.c)4
-rw-r--r--bsp/imxrt/libraries/peripherals/SConscript16
3 files changed, 3 insertions, 19 deletions
diff --git a/bsp/imxrt/libraries/drivers/SConscript b/bsp/imxrt/libraries/drivers/SConscript
index 46546243f5..60d9654238 100644
--- a/bsp/imxrt/libraries/drivers/SConscript
+++ b/bsp/imxrt/libraries/drivers/SConscript
@@ -50,6 +50,8 @@ if GetDepend('BSP_USING_ETH'):
if GetDepend('BSP_USING_PHY'):
src += ['drv_mdio.c']
+ if GetDepend('PHY_USING_KSZ8081'):
+ src += ['drv_ksz8081.c']
if GetDepend('BSP_USING_AUDIO'):
src += ['drv_sai.c']
diff --git a/bsp/imxrt/libraries/peripherals/phyksz8081.c b/bsp/imxrt/libraries/drivers/drv_ksz8081.c
index 3735965663..f922f5f840 100644
--- a/bsp/imxrt/libraries/peripherals/phyksz8081.c
+++ b/bsp/imxrt/libraries/drivers/drv_ksz8081.c
@@ -358,12 +358,10 @@ static struct rt_phy_ops phy_ops =
static int rt_phy_ksz8081_register( void )
{
phy_ksz8081.ops = &phy_ops;
- rt_hw_phy_register(&phy_ksz8081, "rtt-phy");
+ rt_hw_phy_register(&phy_ksz8081, "ksz8081");
return 1;
}
INIT_DEVICE_EXPORT(rt_phy_ksz8081_register);
-
-
#endif /* PHY_USING_KSZ8081 */
diff --git a/bsp/imxrt/libraries/peripherals/SConscript b/bsp/imxrt/libraries/peripherals/SConscript
deleted file mode 100644
index 6d41c2b7c9..0000000000
--- a/bsp/imxrt/libraries/peripherals/SConscript
+++ /dev/null
@@ -1,16 +0,0 @@
-from building import *
-
-src = []
-cwd = []
-CPPDEFINES = []
-
-cwd = GetCurrentDir()
-
-if GetDepend('BSP_USING_PHY') and GetDepend('PHY_USING_KSZ8081'):
- src += ['phyksz8081.c']
-
-path = [cwd]
-
-group = DefineGroup('Libraries', src, depend = [''], CPPPATH = path, CPPDEFINES=CPPDEFINES)
-
-Return('group')