diff options
author | Kumar Gala <galak@kernel.crashing.org> | 2010-09-30 09:15:03 -0500 |
---|---|---|
committer | Kumar Gala <galak@kernel.crashing.org> | 2010-10-20 02:27:18 -0500 |
commit | a1964ea5c25238fdad254dbe88d1e4ed9cd84061 (patch) | |
tree | a69b11d110cddfd003674577e199c847faa21eb3 /board/freescale/mpc8360emds | |
parent | f8c42495e08b270dbeb47c5dd79e9564fa4b5ec2 (diff) |
powerpc/8xxx: Add fdt_fixup_phy_connection helper
Add a common helper that will set the PHY connection type based on enum.
We use this on eTSEC, UCC, and will with Fman in the future.
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'board/freescale/mpc8360emds')
-rw-r--r-- | board/freescale/mpc8360emds/mpc8360emds.c | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/board/freescale/mpc8360emds/mpc8360emds.c b/board/freescale/mpc8360emds/mpc8360emds.c index 59ada9ca75..0babd2648a 100644 --- a/board/freescale/mpc8360emds/mpc8360emds.c +++ b/board/freescale/mpc8360emds/mpc8360emds.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2006 Freescale Semiconductor, Inc. + * Copyright (C) 2006,2010 Freescale Semiconductor, Inc. * Dave Liu <daveliu@freescale.com> * * See file CREDITS for list of people who contributed to this @@ -22,6 +22,7 @@ #include <spd_sdram.h> #include <asm/mmu.h> #include <asm/io.h> +#include <asm/fsl_enet.h> #if defined(CONFIG_OF_LIBFDT) #include <libfdt.h> #endif @@ -396,10 +397,8 @@ void ft_board_setup(void *blob, bd_t *bd) prop = fdt_getprop(blob, path, "phy-connection-type", 0); if (prop && (strcmp(prop, "rgmii-id") == 0)) - fdt_setprop(blob, path, - "phy-connection-type", - "rgmii-rxid", - sizeof("rgmii-rxid")); + fdt_fixup_phy_connection(blob, path, + RGMII_RXID); } #endif #if defined(CONFIG_HAS_ETH1) @@ -410,10 +409,8 @@ void ft_board_setup(void *blob, bd_t *bd) prop = fdt_getprop(blob, path, "phy-connection-type", 0); if (prop && (strcmp(prop, "rgmii-id") == 0)) - fdt_setprop(blob, path, - "phy-connection-type", - "rgmii-rxid", - sizeof("rgmii-rxid")); + fdt_fixup_phy_connection(blob, path, + RGMII_RXID); } #endif } |