From patchwork Fri Jun 24 15:37:18 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Lo=C3=AFc_Minier?= X-Patchwork-Id: 101822 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id C4BB1B6F82 for ; Sat, 25 Jun 2011 01:47:34 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 06CCA28082; Fri, 24 Jun 2011 17:47:31 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id FrI7Sn7LmR0l; Fri, 24 Jun 2011 17:47:30 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 87F8528083; Fri, 24 Jun 2011 17:47:28 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 0228D28083 for ; Fri, 24 Jun 2011 17:47:26 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id CB4Oyt4cQG3a for ; Fri, 24 Jun 2011 17:47:24 +0200 (CEST) X-Greylist: delayed 597 seconds by postgrey-1.27 at theia; Fri, 24 Jun 2011 17:47:22 CEST X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from pig2.dooz.org (pig2.dooz.org [88.191.118.219]) by theia.denx.de (Postfix) with ESMTPS id 1F93528082 for ; Fri, 24 Jun 2011 17:47:22 +0200 (CEST) Received: from bee.dooz.org (serris.dooz.org [88.166.229.232]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "bee.dooz.org", Issuer "CA Cert Signing Authority" (verified OK)) by pig2.dooz.org (Postfix) with ESMTPS id 994A0C0034; Fri, 24 Jun 2011 15:37:25 +0000 (UTC) Received: by bee.dooz.org (Postfix, from userid 1000) id 79700171F; Fri, 24 Jun 2011 17:37:18 +0200 (CEST) Date: Fri, 24 Jun 2011 17:37:18 +0200 From: =?iso-8859-1?Q?Lo=EFc?= Minier To: Stefano Babic Message-ID: <20110624153718.GA2609@bee.dooz.org> References: <1308920678-7013-1-git-send-email-sbabic@denx.de> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1308920678-7013-1-git-send-email-sbabic@denx.de> Cc: u-boot@lists.denx.de, Alessandro Rubini Subject: Re: [U-Boot] [PATCH] ARM: versatile: fix board support X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.9 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de On Fri, Jun 24, 2011, Stefano Babic wrote: > Versatile board is used as example to run u-boot under qemu. > The patch fixes relocation for all versatile boards and adds > a versatileqemu target to be used under qemu. Thanks a lot! > Patch tested only under qemu, not on real boards. > Tested with QEMU emulator version 0.14.50. I've built u-boot tip with your patch with: make CROSS_COMPILE=arm-linux-gnueabi- O=$PWD/obj-versatileqemu \ versatileqemu_config make CROSS_COMPILE=arm-linux-gnueabi- O=$PWD/obj-versatileqemu -j3 using the Ubuntu (Linaro-based, 4.6.0-14ubuntu1cross1.52) armel cross-compiler but couldn't get this to start with my incantations of: qemu-system-arm -M versatilepb -kernel obj-versatileqemu/u-boot \ -m 128 -serial stdio and other combinations I've tried However, inspired by your changes I added these changes: and built with: make CROSS_COMPILE=arm-linux-gnueabi- O=$PWD/obj-qemuvexpressa9 \ qemuvexpressa9_config make CROSS_COMPILE=arm-linux-gnueabi- O=$PWD/obj-qemuvexpressa9 -j3 \ $PWD/obj-qemuvexpressa9/u-boot and this started fine with: qemu-system-arm -M vexpress-a9 -kernel obj-qemuvexpressa9/u-boot \ -m 1024 -serial stdio I wonder whether it would make sense to use the same ifdef for versatile and vexpress boards (QEMU_NO_FLASH?) and prefix the board names with qemu; e.g. qemu_versatile_foo? Could you share your recipe for getting the versatileqemu config to start? I'm using Ubuntu's qemu (Linaro-based, 0.14.50-2011.06-0-0ubuntu1). --- a/boards.cfg +++ b/boards.cfg @@ -138,6 +138,7 @@ omap5912osk arm arm926ejs - ti edminiv2 arm arm926ejs - LaCie orion5x dkb arm arm926ejs - Marvell pantheon ca9x4_ct_vxp arm armv7 vexpress armltd +qemuvexpressa9 arm armv7 vexpress armltd - ca9x4_ct_vxp:ARCH_QEMU_VEXPRESS efikamx arm armv7 efikamx - mx5 mx51evk:IMX_CONFIG=board/efikamx/imximage.cfg mx51evk arm armv7 mx51evk freescale mx5 mx51evk:IMX_CONFIG=board/freescale/mx51evk/imximage.cfg mx53evk arm armv7 mx53evk freescale mx5 mx53evk:IMX_CONFIG=board/freescale/mx53evk/imximage.cfg --- a/include/configs/ca9x4_ct_vxp.h +++ b/include/configs/ca9x4_ct_vxp.h @@ -148,6 +148,12 @@ "cp ${initrdaddr} ${initrd} ${maxinitrd}; " \ "bootm ${kerneladdr} ${initrd}\0" +#ifdef CONFIG_ARCH_QEMU_VEXPRESS +#define CONFIG_ENV_SIZE 8192 +#define CONFIG_SYS_NO_FLASH +#define CONFIG_ENV_IS_NOWHERE +#define CONFIG_SYS_MONITOR_LEN 0x80000 +#else /* FLASH and environment organization */ #define PHYS_FLASH_SIZE 0x04000000 /* 64MB */ #define CONFIG_SYS_FLASH_CFI 1 @@ -187,6 +193,7 @@ #define CONFIG_SYS_FLASH_EMPTY_INFO /* flinfo indicates empty blocks */ #define CONFIG_SYS_FLASH_BANKS_LIST { CONFIG_SYS_FLASH_BASE0, \ CONFIG_SYS_FLASH_BASE1 } +#endif /* Monitor Command Prompt */ #define CONFIG_SYS_CBSIZE 512 /* Console I/O Buffer Size */