All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Alexander Aring <alex.aring@gmail.com>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH 02/22] ARM: phyCARD-i.MX27: increase barebox partition
Date: Mon, 20 Jan 2014 10:28:50 +0100	[thread overview]
Message-ID: <20140120092850.GJ16215@pengutronix.de> (raw)
In-Reply-To: <20140118191625.GB3624@omega>

On Sat, Jan 18, 2014 at 08:16:27PM +0100, Alexander Aring wrote:
> Hi,
> 
> On Fri, Jan 17, 2014 at 04:03:12PM +0100, Sascha Hauer wrote:
> > More place for barebox.
> > 
> > Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> > ---
> >  arch/arm/boards/phycard-i.MX27/env/config | 2 +-
> >  arch/arm/boards/phycard-i.MX27/pca100.c   | 5 +++--
> >  2 files changed, 4 insertions(+), 3 deletions(-)
> > 
> > diff --git a/arch/arm/boards/phycard-i.MX27/env/config b/arch/arm/boards/phycard-i.MX27/env/config
> > index 9596311..9f10e7d 100644
> > --- a/arch/arm/boards/phycard-i.MX27/env/config
> > +++ b/arch/arm/boards/phycard-i.MX27/env/config
> > @@ -39,7 +39,7 @@ autoboot_timeout=3
> >  
> >  bootargs="console=ttymxc0,115200"
> >  
> > -nand_parts="256k(barebox)ro,128k(bareboxenv),2M(kernel),-(root)"
> > +nand_parts="512k(barebox)ro,512k(bareboxenv),2M(kernel),-(root)"
> 
> First I through "2 MB for kernel?", but then I see you change this to 4MB
> in another patch which introduce the new barebox env, so thats pretty cool.

I changed this patch to increase both partitions now. It makes no sense
to wreck the partition layout twice in a single series.

> >  	nand = get_device_by_name("nand0");
> 
> I know, you don't make any change here but I though "What the hell do this
> function here? Increase some reference count, because nand is never used
> in this function?" Then I look a little bit deeper and it simple does
> nothing... - Maybe we should remove this and the nand variable?

Added a patch to remove the unused variable. Thanks for spotting this.

Sascha

----------------8<--------------------

From a25dd5cd482c80e1c3be75568ee0a16df3b3d78d Mon Sep 17 00:00:00 2001
From: Sascha Hauer <s.hauer@pengutronix.de>
Date: Mon, 20 Jan 2014 10:18:48 +0100
Subject: [PATCH 02/23] ARM: phyCARD-i.MX27: remove unused variable

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
reported-by: Alexander Aring <alex.aring@gmail.com>
---
 arch/arm/boards/phycard-i.MX27/pca100.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/arch/arm/boards/phycard-i.MX27/pca100.c b/arch/arm/boards/phycard-i.MX27/pca100.c
index 2ff1b79..613a2ee 100644
--- a/arch/arm/boards/phycard-i.MX27/pca100.c
+++ b/arch/arm/boards/phycard-i.MX27/pca100.c
@@ -178,7 +178,6 @@ static void pca100_usb_init(void)
 static int pca100_devices_init(void)
 {
 	int i;
-	struct device_d *nand;
 
 	unsigned int mode[] = {
 		PD0_AIN_FEC_TXD0,
@@ -286,7 +285,6 @@ static int pca100_devices_init(void)
 	pca100_usb_register();
 #endif
 
-	nand = get_device_by_name("nand0");
 	devfs_add_partition("nand0", 0x00000, 0x40000, DEVFS_PARTITION_FIXED, "self_raw");
 	dev_add_bb_dev("self_raw", "self0");
 

---------------------8<----------------


From 955ac6de78aa8f09015f1d7829d66f7e982ecbf4 Mon Sep 17 00:00:00 2001
From: Sascha Hauer <s.hauer@pengutronix.de>
Date: Fri, 17 Jan 2014 08:48:54 +0100
Subject: [PATCH 03/23] ARM: phyCARD-i.MX27: increase barebox and kernel
 partition

More place for barebox and the kernel as both have the tendency to
get bigger.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 arch/arm/boards/phycard-i.MX27/env/config | 2 +-
 arch/arm/boards/phycard-i.MX27/pca100.c   | 5 +++--
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/arch/arm/boards/phycard-i.MX27/env/config b/arch/arm/boards/phycard-i.MX27/env/config
index 9596311..160cbe7 100644
--- a/arch/arm/boards/phycard-i.MX27/env/config
+++ b/arch/arm/boards/phycard-i.MX27/env/config
@@ -39,7 +39,7 @@ autoboot_timeout=3
 
 bootargs="console=ttymxc0,115200"
 
-nand_parts="256k(barebox)ro,128k(bareboxenv),2M(kernel),-(root)"
+nand_parts="512k(barebox)ro,512k(bareboxenv),4M(kernel),-(root)"
 rootfs_mtdblock_nand=7
 
 # set a fancy prompt (if support is compiled in)
diff --git a/arch/arm/boards/phycard-i.MX27/pca100.c b/arch/arm/boards/phycard-i.MX27/pca100.c
index 613a2ee..3c6b727 100644
--- a/arch/arm/boards/phycard-i.MX27/pca100.c
+++ b/arch/arm/boards/phycard-i.MX27/pca100.c
@@ -21,6 +21,7 @@
 #include <mach/imx27-regs.h>
 #include <fec.h>
 #include <gpio.h>
+#include <sizes.h>
 #include <asm/armlinux.h>
 #include <asm/sections.h>
 #include <generated/mach-types.h>
@@ -285,10 +286,10 @@ static int pca100_devices_init(void)
 	pca100_usb_register();
 #endif
 
-	devfs_add_partition("nand0", 0x00000, 0x40000, DEVFS_PARTITION_FIXED, "self_raw");
+	devfs_add_partition("nand0", 0x00000, SZ_512K, DEVFS_PARTITION_FIXED, "self_raw");
 	dev_add_bb_dev("self_raw", "self0");
 
-	devfs_add_partition("nand0", 0x40000, 0x20000, DEVFS_PARTITION_FIXED, "env_raw");
+	devfs_add_partition("nand0", SZ_512K, SZ_512K, DEVFS_PARTITION_FIXED, "env_raw");
 	dev_add_bb_dev("env_raw", "env0");
 
 	armlinux_set_architecture(2149);


-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  parent reply	other threads:[~2014-01-20  9:29 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-17 15:03 phyCARD-i.MX27 patches Sascha Hauer
2014-01-17 15:03 ` [PATCH 01/22] ARM: Karo TX25: register external NAND boot update handler Sascha Hauer
2014-01-17 15:03 ` [PATCH 02/22] ARM: phyCARD-i.MX27: increase barebox partition Sascha Hauer
2014-01-18 19:16   ` Alexander Aring
2014-01-19 14:19     ` Alexander Aring
2014-01-20  9:28     ` Sascha Hauer [this message]
2014-01-17 15:03 ` [PATCH 03/22] ARM: phyCARD-i.MX27: register barebox update handler Sascha Hauer
2014-01-17 15:03 ` [PATCH 04/22] ARM: phyCARD-i.MX27: switch to new environment Sascha Hauer
2014-01-17 15:03 ` [PATCH 05/22] ARM: phyCARD-i.MX27: convert lowlevel init to c code Sascha Hauer
2014-01-17 15:03 ` [PATCH 06/22] ARM: i.MX27: Add missing MPLL clock sources Sascha Hauer
2014-01-17 15:03 ` [PATCH 07/22] ARM: phyCARD-i.MX27: Update defconfig Sascha Hauer
2014-01-17 15:03 ` [PATCH 08/22] ARM: Fix image size calculation for CONFIG_PBL_RELOCATABLE Sascha Hauer
2014-01-17 15:03 ` [PATCH 09/22] ARM: i.MX: external NAND boot: factor out a 2k pagesize detection function Sascha Hauer
2014-01-17 15:03 ` [PATCH 10/22] ARM: i.MX: external NAND boot: create function macro for different SoCs Sascha Hauer
2014-01-17 15:03 ` [PATCH 11/22] ARM: i.MX: external NAND boot: make it work with relocatable PBL Sascha Hauer
2014-01-17 15:03 ` [PATCH 12/22] ARM: dts: Add i.MX27 devicetree files Sascha Hauer
2014-01-17 16:35   ` Alexander Shiyan
2014-01-17 15:03 ` [PATCH 13/22] ARM: dts: Add Phytec phyCARD-i.MX27 " Sascha Hauer
2014-01-17 16:26   ` Alexander Shiyan
2014-01-17 17:56     ` Sascha Hauer
2014-01-17 15:03 ` [PATCH 14/22] ARM: i.MX: external NAND boot: pass boarddata Sascha Hauer
2014-01-17 15:03 ` [PATCH 15/22] pinctrl: Add pinctrl driver for i.MX1/21/27 Sascha Hauer
2014-01-17 15:13   ` Alexander Shiyan
2014-01-17 17:55     ` Sascha Hauer
2014-01-17 15:03 ` [PATCH 16/22] ARM: i.MX clocksource: return successful for multiple instances Sascha Hauer
2014-01-17 15:03 ` [PATCH 17/22] ARM: phycard-i.MX27: Add NAND support to dts Sascha Hauer
2014-01-17 15:03 ` [PATCH 18/22] ARM: phycard-i.MX27: Add stdout-path property Sascha Hauer
2014-01-17 15:03 ` [PATCH 19/22] ARM: dts: phycard-i.MX27: Add environment and NAND partitioning Sascha Hauer
2014-01-17 16:20   ` Alexander Shiyan
2014-01-20  9:50     ` Sascha Hauer
2014-01-17 15:03 ` [PATCH 20/22] ARM: dts: phycard-i.MX27: Add sdhc2 pinctrl Sascha Hauer
2014-01-18 18:09   ` Alexander Aring
2014-01-20  9:52     ` Sascha Hauer
2014-01-17 15:03 ` [PATCH 21/22] mci: imx: Add devicetree probe support Sascha Hauer
2014-01-17 15:03 ` [PATCH 22/22] ARM: phyCARD-i.MX27: Switch to " Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140120092850.GJ16215@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=alex.aring@gmail.com \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.