From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from 1.mo2.mail-out.ovh.net ([46.105.63.121] helo=mo2.mail-out.ovh.net) by casper.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1S73S0-0006n4-UX for barebox@lists.infradead.org; Mon, 12 Mar 2012 11:30:06 +0000 Received: from mail621.ha.ovh.net (b6.ovh.net [213.186.33.56]) by mo2.mail-out.ovh.net (Postfix) with SMTP id BD04ADC6A97 for ; Mon, 12 Mar 2012 12:33:12 +0100 (CET) From: Jean-Christophe PLAGNIOL-VILLARD Date: Mon, 12 Mar 2012 12:17:59 +0100 Message-Id: <1331551082-7730-11-git-send-email-plagnioj@jcrosoft.com> In-Reply-To: <1331551082-7730-1-git-send-email-plagnioj@jcrosoft.com> References: <1331551082-7730-1-git-send-email-plagnioj@jcrosoft.com> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: barebox-bounces@lists.infradead.org Errors-To: barebox-bounces+u.kleine-koenig=pengutronix.de@lists.infradead.org Subject: [PATCH 11/14] at91sam9m10g45ek: update partition layout To: barebox@lists.infradead.org, Nicolas Ferre Cc: Patrice VILCHEZ This will allow to boot from nand with the bootstrap. Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD --- arch/arm/boards/at91sam9m10g45ek/env/config | 4 ++-- arch/arm/boards/at91sam9m10g45ek/init.c | 9 +++++++-- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/arch/arm/boards/at91sam9m10g45ek/env/config b/arch/arm/boards/at91sam9m10g45ek/env/config index 3dea724..9be6331 100644 --- a/arch/arm/boards/at91sam9m10g45ek/env/config +++ b/arch/arm/boards/at91sam9m10g45ek/env/config @@ -25,8 +25,8 @@ kernelimage=uImage #kernelimage=Image.lzo nand_device=atmel_nand -nand_parts="256k(barebox)ro,64k(bareboxenv),1536k(kernel),-(root)" -rootfs_mtdblock_nand=3 +nand_parts="128k(at91bootstrap),256k(barebox)ro,128k(bareboxenv),128k(bareboxenv2),4M(kernel),120M(rootfs),-(data)" +rootfs_mtdblock_nand=5 autoboot_timeout=3 diff --git a/arch/arm/boards/at91sam9m10g45ek/init.c b/arch/arm/boards/at91sam9m10g45ek/init.c index eff2769..1525795 100644 --- a/arch/arm/boards/at91sam9m10g45ek/init.c +++ b/arch/arm/boards/at91sam9m10g45ek/init.c @@ -33,6 +33,7 @@ #include #include #include +#include #include #include #include @@ -141,10 +142,14 @@ static int at91sam9m10g45ek_devices_init(void) at91_add_device_eth(&macb_pdata); ek_add_device_mci(); - devfs_add_partition("nand0", 0x00000, 0x80000, PARTITION_FIXED, "self_raw"); + devfs_add_partition("nand0", 0x00000, SZ_128K, PARTITION_FIXED, "at91bootstrap_raw"); + dev_add_bb_dev("at91bootstrap_raw", "at91bootstrap"); + devfs_add_partition("nand0", SZ_128K, SZ_256K, PARTITION_FIXED, "self_raw"); dev_add_bb_dev("self_raw", "self0"); - devfs_add_partition("nand0", 0x80000, 0x20000, PARTITION_FIXED, "env_raw"); + devfs_add_partition("nand0", SZ_256K + SZ_128K, SZ_128K, PARTITION_FIXED, "env_raw"); dev_add_bb_dev("env_raw", "env0"); + devfs_add_partition("nand0", SZ_512K, SZ_128K, PARTITION_FIXED, "env_raw1"); + dev_add_bb_dev("env_raw1", "env1"); armlinux_set_bootparams((void *)(AT91_CHIPSELECT_6 + 0x100)); armlinux_set_architecture(MACH_TYPE_AT91SAM9M10G45EK); -- 1.7.7 _______________________________________________ barebox mailing list barebox@lists.infradead.org http://lists.infradead.org/mailman/listinfo/barebox