public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot-Users] [PATCH] qemu-mips: add CFI support
@ 2008-04-10  8:31 Jean-Christophe PLAGNIOL-VILLARD
  2008-04-10 14:44 ` Shinya Kuribayashi
  2008-04-18  7:54 ` Wolfgang Denk
  0 siblings, 2 replies; 3+ messages in thread
From: Jean-Christophe PLAGNIOL-VILLARD @ 2008-04-10  8:31 UTC (permalink / raw)
  To: u-boot

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>

diff --git a/include/configs/qemu-mips.h b/include/configs/qemu-mips.h
index e164019..7ee6fd4 100644
--- a/include/configs/qemu-mips.h
+++ b/include/configs/qemu-mips.h
@@ -33,7 +33,7 @@
 #define CONFIG_MISC_INIT_R
 
 /*IP address is default used by Qemu*/
-#define CONFIG_IPADDR		10.0.2.15    	     /* Our IP address */
+#define CONFIG_IPADDR		10.0.2.15	     /* Our IP address */
 #define CONFIG_SERVERIP		10.0.2.2	     /* Server IP address*/
 
 #define CONFIG_BOOTDELAY	10	/* autoboot after 10 seconds	*/
@@ -74,16 +74,12 @@
 #define CONFIG_CMD_ELF
 #define CONFIG_CMD_FAT
 #define CONFIG_CMD_EXT2
-#undef  CONFIG_CMD_IMLS
-#undef  CONFIG_CMD_FLASH
-#undef  CONFIG_CMD_LOADB
-#undef  CONFIG_CMD_LOADS
 #define CONFIG_CMD_DHCP
+#define CONFIG_CMD_PING
 
 #define CONFIG_DRIVER_NE2000
 #define CONFIG_DRIVER_NE2000_BASE	(0xb4000300)
 
-#define CFG_NO_FLASH
 #define CFG_NS16550
 #define CFG_NS16550_SERIAL
 #define CFG_NS16550_REG_SIZE    1
@@ -140,17 +136,23 @@
 
 /* The following #defines are needed to get flash environment right */
 #define	CFG_MONITOR_BASE	TEXT_BASE
-#define	CFG_MONITOR_LEN		(192 << 10)
+#define	CFG_MONITOR_LEN		(192 << 11)
 
 #define CFG_INIT_SP_OFFSET	0x400000
 
 /* We boot from this flash, selected with dip switch */
 #define CFG_FLASH_BASE		0xbfc00000
-
-#define	CFG_ENV_IS_NOWHERE	1
-
+#define	CFG_MAX_FLASH_BANKS	1
+#define	CFG_MAX_FLASH_SECT	128
+#define	CFG_FLASH_CFI		1	/* Flash memory is CFI compliant */
+#define CFG_FLASH_CFI_DRIVER	1
+#define CFG_FLASH_USE_BUFFER_WRITE    1
+
+#define	CFG_ENV_IS_IN_FLASH	1
+#define CFG_ENV_ADDR		(CFG_FLASH_BASE+0x60000)
 /* Address and size of Primary Environment Sector	*/
-#define CFG_ENV_SIZE		0x10000
+#define CFG_ENV_SIZE		0x8000
+
 #undef CONFIG_NET_MULTI
 
 #define MEM_SIZE 128
-- 
1.5.4.5

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [U-Boot-Users] [PATCH] qemu-mips: add CFI support
  2008-04-10  8:31 [U-Boot-Users] [PATCH] qemu-mips: add CFI support Jean-Christophe PLAGNIOL-VILLARD
@ 2008-04-10 14:44 ` Shinya Kuribayashi
  2008-04-18  7:54 ` Wolfgang Denk
  1 sibling, 0 replies; 3+ messages in thread
From: Shinya Kuribayashi @ 2008-04-10 14:44 UTC (permalink / raw)
  To: u-boot

Hi Jean,

Jean-Christophe PLAGNIOL-VILLARD wrote:
> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
> 
> diff --git a/include/configs/qemu-mips.h b/include/configs/qemu-mips.h
> index e164019..7ee6fd4 100644
> --- a/include/configs/qemu-mips.h
> +++ b/include/configs/qemu-mips.h
> @@ -33,7 +33,7 @@
>  #define CONFIG_MISC_INIT_R
>  
>  /*IP address is default used by Qemu*/
> -#define CONFIG_IPADDR		10.0.2.15    	     /* Our IP address */
> +#define CONFIG_IPADDR		10.0.2.15	     /* Our IP address */
>  #define CONFIG_SERVERIP		10.0.2.2	     /* Server IP address*/
>  
>  #define CONFIG_BOOTDELAY	10	/* autoboot after 10 seconds	*/
> @@ -74,16 +74,12 @@
>  #define CONFIG_CMD_ELF
>  #define CONFIG_CMD_FAT
>  #define CONFIG_CMD_EXT2
> -#undef  CONFIG_CMD_IMLS
> -#undef  CONFIG_CMD_FLASH
> -#undef  CONFIG_CMD_LOADB
> -#undef  CONFIG_CMD_LOADS
>  #define CONFIG_CMD_DHCP
> +#define CONFIG_CMD_PING
>  
>  #define CONFIG_DRIVER_NE2000

This patch contains as many fixes as CFI related changes (above).
In that case, please add some notes about them or change the subject.

I applied the patch below. If something wrong, please let me know.
Or will push in a week or two :-)

  Shinya

----------------------------------------------------------------
[MIPS] qemu-mips.h: Update config header

From: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>

- Add CFI support
- Add CONFIG_CMD_PING since qemu-mips has NE2000 driver enabled
- Cleanup whitespaces and remove #undef CMD lines

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Shinya Kuribayashi <skuribay@ruby.dti.ne.jp>
---

 include/configs/qemu-mips.h |   24 +++++++++++++-----------
 1 files changed, 13 insertions(+), 11 deletions(-)


diff --git a/include/configs/qemu-mips.h b/include/configs/qemu-mips.h
index e164019..7ee6fd4 100644
--- a/include/configs/qemu-mips.h
+++ b/include/configs/qemu-mips.h
@@ -33,7 +33,7 @@
 #define CONFIG_MISC_INIT_R
 
 /*IP address is default used by Qemu*/
-#define CONFIG_IPADDR		10.0.2.15    	     /* Our IP address */
+#define CONFIG_IPADDR		10.0.2.15	     /* Our IP address */
 #define CONFIG_SERVERIP		10.0.2.2	     /* Server IP address*/
 
 #define CONFIG_BOOTDELAY	10	/* autoboot after 10 seconds	*/
@@ -74,16 +74,12 @@
 #define CONFIG_CMD_ELF
 #define CONFIG_CMD_FAT
 #define CONFIG_CMD_EXT2
-#undef  CONFIG_CMD_IMLS
-#undef  CONFIG_CMD_FLASH
-#undef  CONFIG_CMD_LOADB
-#undef  CONFIG_CMD_LOADS
 #define CONFIG_CMD_DHCP
+#define CONFIG_CMD_PING
 
 #define CONFIG_DRIVER_NE2000
 #define CONFIG_DRIVER_NE2000_BASE	(0xb4000300)
 
-#define CFG_NO_FLASH
 #define CFG_NS16550
 #define CFG_NS16550_SERIAL
 #define CFG_NS16550_REG_SIZE    1
@@ -140,17 +136,23 @@
 
 /* The following #defines are needed to get flash environment right */
 #define	CFG_MONITOR_BASE	TEXT_BASE
-#define	CFG_MONITOR_LEN		(192 << 10)
+#define	CFG_MONITOR_LEN		(192 << 11)
 
 #define CFG_INIT_SP_OFFSET	0x400000
 
 /* We boot from this flash, selected with dip switch */
 #define CFG_FLASH_BASE		0xbfc00000
-
-#define	CFG_ENV_IS_NOWHERE	1
-
+#define	CFG_MAX_FLASH_BANKS	1
+#define	CFG_MAX_FLASH_SECT	128
+#define	CFG_FLASH_CFI		1	/* Flash memory is CFI compliant */
+#define CFG_FLASH_CFI_DRIVER	1
+#define CFG_FLASH_USE_BUFFER_WRITE    1
+
+#define	CFG_ENV_IS_IN_FLASH	1
+#define CFG_ENV_ADDR		(CFG_FLASH_BASE+0x60000)
 /* Address and size of Primary Environment Sector	*/
-#define CFG_ENV_SIZE		0x10000
+#define CFG_ENV_SIZE		0x8000
+
 #undef CONFIG_NET_MULTI
 
 #define MEM_SIZE 128

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [U-Boot-Users] [PATCH] qemu-mips: add CFI support
  2008-04-10  8:31 [U-Boot-Users] [PATCH] qemu-mips: add CFI support Jean-Christophe PLAGNIOL-VILLARD
  2008-04-10 14:44 ` Shinya Kuribayashi
@ 2008-04-18  7:54 ` Wolfgang Denk
  1 sibling, 0 replies; 3+ messages in thread
From: Wolfgang Denk @ 2008-04-18  7:54 UTC (permalink / raw)
  To: u-boot

In message <1207816295-9586-1-git-send-email-plagnioj@jcrosoft.com> you wrote:
> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
...
> @@ -74,16 +74,12 @@
>  #define CONFIG_CMD_ELF
>  #define CONFIG_CMD_FAT
>  #define CONFIG_CMD_EXT2
> -#undef  CONFIG_CMD_IMLS
> -#undef  CONFIG_CMD_FLASH
> -#undef  CONFIG_CMD_LOADB
^^^^^^^^^^^^^^^^^^^^^^^^^^^
> -#undef  CONFIG_CMD_LOADS
^^^^^^^^^^^^^^^^^^^^^^^^^^^
>  #define CONFIG_CMD_DHCP
> +#define CONFIG_CMD_PING
^^^^^^^^^^^^^^^^^^^^^^^^^^^

These changes are neither related to CFI support nor mentioned in the
subject. This is misleading.

> -#define	CFG_MONITOR_LEN		(192 << 10)
> +#define	CFG_MONITOR_LEN		(192 << 11)

It would be much better readable if you wrote "384 << 10" instead -
everybody will then see immediately that this is 384 KiB.

But - is this really needed? Has your image become that big?
Please check!!

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
Prepare for tomorrow -- get ready.
	-- Edith Keeler, "The City On the Edge of Forever",
	   stardate unknown

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2008-04-18  7:54 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-04-10  8:31 [U-Boot-Users] [PATCH] qemu-mips: add CFI support Jean-Christophe PLAGNIOL-VILLARD
2008-04-10 14:44 ` Shinya Kuribayashi
2008-04-18  7:54 ` Wolfgang Denk

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox