[U-Boot] [PATCH v9] Marvell MV88E61XX Switch Driver support

Prafulla Wadaskar prafulla at marvell.com
Tue May 5 05:09:28 CEST 2009


 

> -----Original Message-----
> From: Jean-Christophe PLAGNIOL-VILLARD [mailto:plagnioj at jcrosoft.com] 
> Sent: Tuesday, May 05, 2009 3:43 AM
> To: Prafulla Wadaskar
> Cc: u-boot at lists.denx.de; Ashish Karkare; Prabhanjan Sarnaik; 
> Ronen Shitrit
> Subject: Re: [U-Boot] [PATCH v9] Marvell MV88E61XX Switch 
> Driver support
> 
> > --- a/include/netdev.h
> > +++ b/include/netdev.h
> > @@ -28,6 +28,34 @@
> >  #ifndef _NETDEV_H_
> >  #define _NETDEV_H_
> >  
> > +/* constants for switch configuration */ enum switch_cfg_vlan {
> IHMO in this case it must be mvxxxx_swtich .....
Since this definition is a part of public header file and can be used for other switch/phy configuration, that's why I have replaced MV88E61XX by SWITCH.
> 
> and maybe cover by a defive
This is the only switch in the driver/net/phy folder that's why not ifdefed.
I will do this

> 
> but I not sure it's the rigth place for this
I have suggested to creat new phydev.h for this, Ben suggested this place

> 
> > +	SWITCH_VLANCFG_DEFAULT,
> > +	SWITCH_VLANCFG_ROUTER
> > +};
> > +
> > +enum switch_cfg_rgmiid {
> > +	SWITCH_RGMII_DELAY_DIS,
> > +	SWITCH_RGMII_DELAY_EN
> > +};
> > +
> > +enum switch_cfg_prtstt {
> > +	SWITCH_PORTSTT_DISABLED,
> > +	SWITCH_PORTSTT_BLOCKING,
> > +	SWITCH_PORTSTT_LEARNING,
> > +	SWITCH_PORTSTT_FORWARDING
> > +};
> > +
> > +/* switch configuration structure */
> > +struct switch_config {
> > +	char *name;
> > +	enum switch_cfg_vlan vlancfg;
> > +	enum switch_cfg_rgmiid rgmii_delay;
> > +	enum switch_cfg_prtstt portstate;
> > +	u32 ports_enabled;
> > +	u8 cpuport;
> > +};
> a simple
> struct switch_config;
> 
> and the a MV88E61XX_H
> 
> will be cleaner
I will replace switch with mv88361xx and ifdef to make it clean

Regards..
Prafulla . .

> 
> Best Regards,
> J.
> 


More information about the U-Boot mailing list