Skip to content
Snippets Groups Projects
Commit a50a90c9 authored by Marek Vasut's avatar Marek Vasut Committed by Albert ARIBAUD
Browse files

FEC: Add RMII mode support


Signed-off-by: default avatarMarek Vasut <marek.vasut@gmail.com>
Cc: Ben Warren <biggerbadderben@gmail.com>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Detlev Zundel <dzu@denx.de>
parent 9eb3770b
No related branches found
No related tags found
No related merge requests found
...@@ -448,6 +448,8 @@ static int fec_init(struct eth_device *dev, bd_t* bd) ...@@ -448,6 +448,8 @@ static int fec_init(struct eth_device *dev, bd_t* bd)
rcntrl = PKTSIZE << FEC_RCNTRL_MAX_FL_SHIFT; rcntrl = PKTSIZE << FEC_RCNTRL_MAX_FL_SHIFT;
if (fec->xcv_type == SEVENWIRE) if (fec->xcv_type == SEVENWIRE)
rcntrl |= FEC_RCNTRL_FCE; rcntrl |= FEC_RCNTRL_FCE;
else if (fec->xcv_type == RMII)
rcntrl |= FEC_RCNTRL_RMII;
else /* MII mode */ else /* MII mode */
rcntrl |= FEC_RCNTRL_FCE | FEC_RCNTRL_MII_MODE; rcntrl |= FEC_RCNTRL_FCE | FEC_RCNTRL_MII_MODE;
......
...@@ -194,6 +194,7 @@ struct ethernet_regs { ...@@ -194,6 +194,7 @@ struct ethernet_regs {
#define FEC_RCNTRL_PROM 0x00000008 #define FEC_RCNTRL_PROM 0x00000008
#define FEC_RCNTRL_BC_REJ 0x00000010 #define FEC_RCNTRL_BC_REJ 0x00000010
#define FEC_RCNTRL_FCE 0x00000020 #define FEC_RCNTRL_FCE 0x00000020
#define FEC_RCNTRL_RMII 0x00000100
#define FEC_TCNTRL_GTS 0x00000001 #define FEC_TCNTRL_GTS 0x00000001
#define FEC_TCNTRL_HBC 0x00000002 #define FEC_TCNTRL_HBC 0x00000002
...@@ -257,7 +258,8 @@ struct fec_bd { ...@@ -257,7 +258,8 @@ struct fec_bd {
enum xceiver_type { enum xceiver_type {
SEVENWIRE, /* 7-wire */ SEVENWIRE, /* 7-wire */
MII10, /* MII 10Mbps */ MII10, /* MII 10Mbps */
MII100 /* MII 100Mbps */ MII100, /* MII 100Mbps */
RMII /* RMII */
}; };
/** /**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment