[U-Boot] [PATCH 27/27] remove bi_enet*addr from global data for all arches

Mike Frysinger vapier at gentoo.org
Mon Feb 16 19:57:52 CET 2009


On Monday 16 February 2009 13:16:38 Scott Wood wrote:
> On Sat, Feb 14, 2009 at 02:23:10AM -0500, Mike Frysinger wrote:
> > diff --git a/include/asm-ppc/u-boot.h b/include/asm-ppc/u-boot.h
> > index 7451905..c16f32b 100644
> > --- a/include/asm-ppc/u-boot.h
> > +++ b/include/asm-ppc/u-boot.h
> > @@ -64,7 +64,6 @@ typedef struct bd_info {
> > -	unsigned char	bi_enetaddr[6];	/* Ethernet adress */
> > -#ifdef CONFIG_HAS_ETH1
> > -	/* second onboard ethernet port */
> > -	unsigned char   bi_enet1addr[6];
> > -#endif
> > -#ifdef CONFIG_HAS_ETH2
> > -	/* third onboard ethernet port */
> > -	unsigned char	bi_enet2addr[6];
> > -#endif
> > -#ifdef CONFIG_HAS_ETH3
> > -	unsigned char   bi_enet3addr[6];
> > -#endif
> > -#ifdef CONFIG_HAS_ETH4
> > -	unsigned char   bi_enet4addr[6];
> > -#endif
> > -#ifdef CONFIG_HAS_ETH5
> > -	unsigned char   bi_enet5addr[6];
> > -#endif
>
> This will break compatibility with pre-device-tree kernels.
>
> bd_t is a public interface, albeit a deprecated one.

the fact that the size can change based on board configs makes it already a 
pretty unreliable ABI ...

at any rate, is there a define that can be keyed off of ?  CONFIG_HAS_FDT or 
some such junk ?  then the behavior can be changed to like:
#ifndef CONFIG_HAS_FDT
	/* ABI compat junk */
	uchar bi_padding_was_enetaddr[6];
#endif
-mike


More information about the U-Boot mailing list