summaryrefslogtreecommitdiff
path: root/cpu/mcf52x2/fec.c
diff options
context:
space:
mode:
authorWolfgang Denk <wd@pollux.denx.de>2006-06-10 22:00:40 +0200
committerWolfgang Denk <wd@pollux.denx.de>2006-06-10 22:00:40 +0200
commitb1d71358a9448802a08bc822b78debe9f754eae7 (patch)
tree8d2264449412b582171c74fa0e360d736162a7ba /cpu/mcf52x2/fec.c
parent4176c799645d8b35224345d899006993397635c1 (diff)
downloadu-boot-imx-b1d71358a9448802a08bc822b78debe9f754eae7.zip
u-boot-imx-b1d71358a9448802a08bc822b78debe9f754eae7.tar.gz
u-boot-imx-b1d71358a9448802a08bc822b78debe9f754eae7.tar.bz2
Minor code cleanup.
Diffstat (limited to 'cpu/mcf52x2/fec.c')
-rw-r--r--cpu/mcf52x2/fec.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/cpu/mcf52x2/fec.c b/cpu/mcf52x2/fec.c
index 702563d..6db6214 100644
--- a/cpu/mcf52x2/fec.c
+++ b/cpu/mcf52x2/fec.c
@@ -283,7 +283,7 @@ int eth_init (bd_t * bd)
rtx = (RTXBD *) CFG_ENET_BD_BASE;
#else
rtx = (RTXBD *) (CFG_MONITOR_BASE+gd->reloc_off -
- (((PKTBUFSRX+TX_BUF_CNT)*+sizeof(cbd_t)
+ (((PKTBUFSRX+TX_BUF_CNT)*+sizeof(cbd_t)
+0xFF)
& ~0xFF)
);
@@ -327,13 +327,13 @@ int eth_init (bd_t * bd)
fecp->fec_r_cntrl = FEC_RCNTRL_MII_MODE;
fecp->fec_x_cntrl = FEC_TCNTRL_FDEN;
#else /* Half duplex mode */
- fecp->fec_r_cntrl = (PKT_MAXBUF_SIZE << 16); /* set max frame length */
+ fecp->fec_r_cntrl = (PKT_MAXBUF_SIZE << 16); /* set max frame length */
fecp->fec_r_cntrl |= FEC_RCNTRL_MII_MODE | FEC_RCNTRL_DRT;
fecp->fec_x_cntrl = 0;
#endif
/* Set MII speed */
- fecp->fec_mii_speed = (((CFG_CLK / 2) / (2500000 / 10)) + 5) / 10;
- fecp->fec_mii_speed *= 2;
+ fecp->fec_mii_speed = (((CFG_CLK / 2) / (2500000 / 10)) + 5) / 10;
+ fecp->fec_mii_speed *= 2;
/* Configure port B for MII.
*/