[U-Boot] [PATCH] ARM: lacie_kw: add support for WIRELESS_SPACE

Prafulla Wadaskar prafulla at marvell.com
Fri Aug 17 09:59:24 CEST 2012



> -----Original Message-----
> From: u-boot-bounces at lists.denx.de [mailto:u-boot-
> bounces at lists.denx.de] On Behalf Of Albert ARIBAUD
> Sent: 16 August 2012 23:39
> To: u-boot at lists.denx.de
> Subject: [U-Boot] [PATCH] ARM: lacie_kw: add support for
> WIRELESS_SPACE
> 
> 
> Signed-off-by: Albert ARIBAUD <albert.u.boot at aribaud.net>
> ---
> 
> This patch adds the Wireless Space to the lacie_kw sub-targets.
> It *should* not change a thing to the already existing sub-targets
> (except that each one gets its own prompt).
> 
> Owners of NETSPACE_[MAX]_V2, INETSPACE_V2, NET2BIG_V2 please test.
> 
>  board/LaCie/netspace_v2/netspace_v2.c |   42 ++----------
>  board/LaCie/netspace_v2/netspace_v2.h |  121
> +++++++++++++++++++++++++++++++++
>  boards.cfg                            |    1 +
>  drivers/net/mvgbe.c                   |   10 ++-

It would be good if you split the patch, to me the change to above file is generic, which is your dependency.

>  include/configs/lacie_kw.h            |   38 ++++++++++-
>  5 files changed, 175 insertions(+), 37 deletions(-)
> 
...snip...
> diff --git a/include/configs/lacie_kw.h b/include/configs/lacie_kw.h
> index c35c2db..a979ab4 100644
> --- a/include/configs/lacie_kw.h
> +++ b/include/configs/lacie_kw.h
> @@ -33,6 +33,10 @@
>  #elif defined(CONFIG_NET2BIG_V2)
>  #define CONFIG_MACH_TYPE		MACH_TYPE_NET2BIG_V2
>  #define CONFIG_IDENT_STRING		" 2Big v2"
> +#elif defined(CONFIG_WIRELESS_SPACE)
> +#define MACH_TYPE_WIRELESS_SPACE	2500 /* is missing in mach-types.h
> */
> +#define CONFIG_MACH_TYPE		MACH_TYPE_WIRELESS_SPACE
> +#define CONFIG_IDENT_STRING		" Wireless Space"
>  #else
>  #error "Unknown board"
>  #endif
> @@ -73,6 +77,12 @@
>  #define CONFIG_SYS_KWD_CONFIG $(SRCTREE)/$(CONFIG_BOARDDIR)/kwbimage-
> is2.cfg
>  #endif
> 
> +#ifdef CONFIG_WIRELESS_SPACE
> +/* No SPI but NAND */
> +#undef CONFIG_CMD_SF
> +#define CONFIG_CMD_NAND
> +#endif
> +
>  /*
>   * mv-common.h should be defined after CMD configs since it used them
>   * to enable certain macros
> @@ -90,8 +100,14 @@
>  #define CONFIG_SYS_IDE_MAXDEVICE        1
>  #if defined(CONFIG_NET2BIG_V2)
>  #define CONFIG_SYS_PROMPT		"2big2> "
> -#else
> +#elif defined(CONFIG_NETSPACE_V2)
>  #define CONFIG_SYS_PROMPT		"ns2> "
> +#elif defined(CONFIG_INETSPACE_V2)
> +#define CONFIG_SYS_PROMPT		"is2> "
> +#elif defined(CONFIG_WIRELESS_SPACE)
> +#define CONFIG_SYS_PROMPT		"ws> "
> +#else
> +#define CONFIG_SYS_PROMPT		"lacie-kw> "
>  #endif
> 
>  /*
> @@ -99,7 +115,16 @@
>   */
>  #ifdef CONFIG_CMD_NET
>  #define CONFIG_MISC_INIT_R /* Call misc_init_r() to initialize MAC
> address */
> +#if defined(CONFIG_WIRELESS_SPACE)
> +#define CONFIG_MVGBE_PORTS		{1, 1}	/* enable both ports only */
> +#define CONFIG_EGIGA1_PHY		0x6		/* egiga1 has a PHY, egiga0
> has NOT */
> +#define CONFIG_MVGBE_PHY_ADRS	{0xa, 0x6}
> +#define CONFIG_MII
> +#define CONFIG_SYS_FAULT_ECHO_LINK_DOWN
> +#else
>  #define CONFIG_MVGBE_PORTS		{1, 0} /* enable port 0 only */
> +#define CONFIG_EGIGA0_PHY		0x8
> +#endif
>  #define CONFIG_NETCONSOLE
>  #endif
> 
> @@ -154,11 +179,20 @@
>  /*
>   * Environment variables configurations
>   */
> +
> +#if defined(CONFIG_WIRELESS_SPACE)
> +#define CONFIG_ENV_IS_IN_NAND
> +#define CONFIG_ENV_SECT_SIZE		0x10000	/* 64KB */
> +#define CONFIG_ENV_SIZE			0x1000	/* 4KB */
> +#define CONFIG_ENV_ADDR			0x70000
> +#define CONFIG_ENV_OFFSET		0x70000	/* env starts here */
> +#else
>  #define CONFIG_ENV_IS_IN_SPI_FLASH
>  #define CONFIG_ENV_SECT_SIZE		0x10000	/* 64KB */
>  #define CONFIG_ENV_SIZE			0x1000	/* 4KB */
>  #define CONFIG_ENV_ADDR			0x70000
>  #define CONFIG_ENV_OFFSET		0x70000	/* env starts here */
> +#endif
> 
>  /*
>   * Default environment variables
> @@ -185,4 +219,6 @@
>  	"usbload=usb start && "					\
>  		"fatload usb 0:1 $loadaddr /boot/$bootfile\0"
> 
> +//#define DEBUG

Either remove it or make it c-style comments.

Regards...
Prafulla . . .

> +
>  #endif /* _CONFIG_LACIE_KW_H */
> --
> 1.7.9.5
> 
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot


More information about the U-Boot mailing list