diff options
author | Andy Fleming <afleming@freescale.com> | 2008-08-31 16:33:28 -0500 |
---|---|---|
committer | Ben Warren <biggerbadderben@gmail.com> | 2008-09-02 21:18:15 -0700 |
commit | 652f7c2eef76a1340928bd660845441e932d86a2 (patch) | |
tree | c5812ea5bf44adde7fd7d53537f86fa2161e813f /board/freescale/common/sgmii_riser.c | |
parent | 2abe361c03b43e6dcf68f54e96b5c05156c49284 (diff) | |
download | u-boot-imx-652f7c2eef76a1340928bd660845441e932d86a2.zip u-boot-imx-652f7c2eef76a1340928bd660845441e932d86a2.tar.gz u-boot-imx-652f7c2eef76a1340928bd660845441e932d86a2.tar.bz2 |
Add support for Freescale SGMII Riser Card
The 8544DS and 8572DS systems have an optional SGMII riser card which
exposes new ethernet ports which are connected to the eTSECs via an
SGMII interface. The SGMII PHYs for this board are offset from the standard
PHY addresses, so this code modifies the passed in tsec_info structure to
use the SGMII PHYs on the card, instead.
Signed-off-by: Andy Fleming <afleming@freescale.com>
Signed-off-by: Ben Warren <biggerbadderben@gmail.com>
Diffstat (limited to 'board/freescale/common/sgmii_riser.c')
-rw-r--r-- | board/freescale/common/sgmii_riser.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/board/freescale/common/sgmii_riser.c b/board/freescale/common/sgmii_riser.c new file mode 100644 index 0000000..5ccd6bc --- /dev/null +++ b/board/freescale/common/sgmii_riser.c @@ -0,0 +1,26 @@ +/* + * Freescale SGMII Riser Card + * + * This driver supports the SGMII Riser card found on the + * "DS" style of development board from Freescale. + * + * This software may be used and distributed according to the + * terms of the GNU Public License, Version 2, incorporated + * herein by reference. + * + * Copyright 2008 Freescale Semiconductor, Inc. + * + */ + +#include <config.h> +#include <common.h> +#include <tsec.h> + +void fsl_sgmii_riser_init(struct tsec_info_struct *tsec_info, int num) +{ + int i; + + for (i = 0; i < num; i++) + if (tsec_info[i].flags & TSEC_SGMII) + tsec_info[i].phyaddr += SGMII_RISER_PHY_OFFSET; +} |