DistroKit Mailinglist
 help / color / mirror / Atom feed
* [DistroKit] [PATCH] v7a: image-vexpress: remove unneeded partition
@ 2019-02-11 13:29 Roland Hieber
  2019-02-11 13:33 ` Robert Schwebel
  0 siblings, 1 reply; 6+ messages in thread
From: Roland Hieber @ 2019-02-11 13:29 UTC (permalink / raw)
  To: distrokit
  Cc: Michael Olbrich, Alexander Dahl, Roland Hieber, Rouven Czerwinski

The additional partition at the end results in an hdimage of ~1 GB in
size; compared to the ~60 MB of the other hdimages created by
platform-v7a, this seems out of proportion as the image will consist
mainly of zeroes. It is not clear to me why this partition was added at
all in commit cc1fee168d ("platform-v7a: vexpress: add board support"),
but it turns out that qemu-vexpress boots fine without it.

Reported-by: Alexander Dahl <post@lespocky.de>
Signed-off-by: Roland Hieber <rhi@pengutronix.de>
---
 configs/platform-v7a/config/images/vexpress.config | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/configs/platform-v7a/config/images/vexpress.config b/configs/platform-v7a/config/images/vexpress.config
index 7cfaaaa..8ca2f9c 100644
--- a/configs/platform-v7a/config/images/vexpress.config
+++ b/configs/platform-v7a/config/images/vexpress.config
@@ -12,13 +12,6 @@ image @IMAGE@ {
 		partition-type = 0x83
 		size = 512M
 	}
-	/* expand image size to 64 MiB; dummy size, results in 0 bytes length */
-	partition end {
-		image = /dev/null
-		size = 1M
-		offset = 1025M
-		in-partition-table = false
-	}
 }
 
 /* vim: set tabstop=8 noexpandtab : */
-- 
2.20.1


_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* Re: [DistroKit] [PATCH] v7a: image-vexpress: remove unneeded partition
  2019-02-11 13:29 [DistroKit] [PATCH] v7a: image-vexpress: remove unneeded partition Roland Hieber
@ 2019-02-11 13:33 ` Robert Schwebel
  2019-02-11 14:46   ` Michael Olbrich
  2019-02-11 16:18   ` [DistroKit] [PATCH v2] v7a: image-vexpress: fix comment in image config Roland Hieber
  0 siblings, 2 replies; 6+ messages in thread
From: Robert Schwebel @ 2019-02-11 13:33 UTC (permalink / raw)
  To: Roland Hieber
  Cc: Michael Olbrich, distrokit, Alexander Dahl, Rouven Czerwinski

On Mon, Feb 11, 2019 at 02:29:32PM +0100, Roland Hieber wrote:
> The additional partition at the end results in an hdimage of ~1 GB in
> size; compared to the ~60 MB of the other hdimages created by
> platform-v7a, this seems out of proportion as the image will consist
> mainly of zeroes. It is not clear to me why this partition was added at
> all in commit cc1fee168d ("platform-v7a: vexpress: add board support"),
> but it turns out that qemu-vexpress boots fine without it.
> 
> Reported-by: Alexander Dahl <post@lespocky.de>
> Signed-off-by: Roland Hieber <rhi@pengutronix.de>
> ---
>  configs/platform-v7a/config/images/vexpress.config | 7 -------
>  1 file changed, 7 deletions(-)
> 
> diff --git a/configs/platform-v7a/config/images/vexpress.config b/configs/platform-v7a/config/images/vexpress.config
> index 7cfaaaa..8ca2f9c 100644
> --- a/configs/platform-v7a/config/images/vexpress.config
> +++ b/configs/platform-v7a/config/images/vexpress.config
> @@ -12,13 +12,6 @@ image @IMAGE@ {
>  		partition-type = 0x83
>  		size = 512M
>  	}
> -	/* expand image size to 64 MiB; dummy size, results in 0 bytes length */
> -	partition end {
> -		image = /dev/null
> -		size = 1M
> -		offset = 1025M
> -		in-partition-table = false
> -	}
>  }
>  
>  /* vim: set tabstop=8 noexpandtab : */
> -- 
> 2.20.1

Applied to next.

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

_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* Re: [DistroKit] [PATCH] v7a: image-vexpress: remove unneeded partition
  2019-02-11 13:33 ` Robert Schwebel
@ 2019-02-11 14:46   ` Michael Olbrich
  2019-02-11 15:06     ` Robert Schwebel
  2019-02-11 16:18   ` [DistroKit] [PATCH v2] v7a: image-vexpress: fix comment in image config Roland Hieber
  1 sibling, 1 reply; 6+ messages in thread
From: Michael Olbrich @ 2019-02-11 14:46 UTC (permalink / raw)
  To: distrokit

On Mon, Feb 11, 2019 at 02:33:03PM +0100, Robert Schwebel wrote:
> On Mon, Feb 11, 2019 at 02:29:32PM +0100, Roland Hieber wrote:
> > The additional partition at the end results in an hdimage of ~1 GB in
> > size; compared to the ~60 MB of the other hdimages created by
> > platform-v7a, this seems out of proportion as the image will consist
> > mainly of zeroes. It is not clear to me why this partition was added at
> > all in commit cc1fee168d ("platform-v7a: vexpress: add board support"),
> > but it turns out that qemu-vexpress boots fine without it.

No it doesn't:

[...]
[    1.601963] mmcblk0: p1 size 1048576 extends beyond EOD, truncated
[    1.603317] mmcblk0: p2 start 1050624 is beyond EOD, truncated
[...]

The disk size in qemu is the file size. Without this partition the image
is too small because the ext4 image for the first partition is smaller than
the partition size and the second partition has no content.

> > Reported-by: Alexander Dahl <post@lespocky.de>
> > Signed-off-by: Roland Hieber <rhi@pengutronix.de>
> > ---
> >  configs/platform-v7a/config/images/vexpress.config | 7 -------
> >  1 file changed, 7 deletions(-)
> > 
> > diff --git a/configs/platform-v7a/config/images/vexpress.config b/configs/platform-v7a/config/images/vexpress.config
> > index 7cfaaaa..8ca2f9c 100644
> > --- a/configs/platform-v7a/config/images/vexpress.config
> > +++ b/configs/platform-v7a/config/images/vexpress.config
> > @@ -12,13 +12,6 @@ image @IMAGE@ {
> >  		partition-type = 0x83
> >  		size = 512M
> >  	}
> > -	/* expand image size to 64 MiB; dummy size, results in 0 bytes length */
> > -	partition end {
> > -		image = /dev/null
> > -		size = 1M
> > -		offset = 1025M
> > -		in-partition-table = false
> > -	}
> >  }
> >  
> >  /* vim: set tabstop=8 noexpandtab : */
> > -- 
> > 2.20.1
> 
> Applied to next.

Revert please.

Michael

-- 
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 |

_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* Re: [DistroKit] [PATCH] v7a: image-vexpress: remove unneeded partition
  2019-02-11 14:46   ` Michael Olbrich
@ 2019-02-11 15:06     ` Robert Schwebel
  0 siblings, 0 replies; 6+ messages in thread
From: Robert Schwebel @ 2019-02-11 15:06 UTC (permalink / raw)
  To: distrokit

On Mon, Feb 11, 2019 at 03:46:24PM +0100, Michael Olbrich wrote:
> > Applied to next.
> 
> Revert please.
 
Done

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

_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* [DistroKit] [PATCH v2] v7a: image-vexpress: fix comment in image config
  2019-02-11 13:33 ` Robert Schwebel
  2019-02-11 14:46   ` Michael Olbrich
@ 2019-02-11 16:18   ` Roland Hieber
  2019-02-12  6:30     ` Robert Schwebel
  1 sibling, 1 reply; 6+ messages in thread
From: Roland Hieber @ 2019-02-11 16:18 UTC (permalink / raw)
  To: Robert Schwebel
  Cc: Michael Olbrich, distrokit, Alexander Dahl, Rouven Czerwinski

Signed-off-by: Roland Hieber <rhi@pengutronix.de>
---
On Mon, Feb 11, 2019 at 02:33:03PM +0100, Robert Schwebel wrote:
> Applied to next.
> 
> rsc

Ah, mol just explained the reason to me. Robert, please drop my previous
patch in favor of the following:

---
 configs/platform-v7a/config/images/vexpress.config | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/configs/platform-v7a/config/images/vexpress.config b/configs/platform-v7a/config/images/vexpress.config
index 7cfaaaa..1eed95d 100644
--- a/configs/platform-v7a/config/images/vexpress.config
+++ b/configs/platform-v7a/config/images/vexpress.config
@@ -12,7 +12,11 @@ image @IMAGE@ {
 		partition-type = 0x83
 		size = 512M
 	}
-	/* expand image size to 64 MiB; dummy size, results in 0 bytes length */
+	/* genimage does not write zeros at the end of an image to save space,
+	 * but the kernel in qemu will complain if the image file is smaller
+	 * than the partition sizes. work around this by adding an empty
+	 * partition at the end.
+	 */
 	partition end {
 		image = /dev/null
 		size = 1M
-- 
2.20.1


_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* Re: [DistroKit] [PATCH v2] v7a: image-vexpress: fix comment in image config
  2019-02-11 16:18   ` [DistroKit] [PATCH v2] v7a: image-vexpress: fix comment in image config Roland Hieber
@ 2019-02-12  6:30     ` Robert Schwebel
  0 siblings, 0 replies; 6+ messages in thread
From: Robert Schwebel @ 2019-02-12  6:30 UTC (permalink / raw)
  To: Roland Hieber
  Cc: Michael Olbrich, distrokit, Alexander Dahl, Rouven Czerwinski

On Mon, Feb 11, 2019 at 05:18:24PM +0100, Roland Hieber wrote:
> Ah, mol just explained the reason to me. Robert, please drop my previous
> patch in favor of the following:

Done.

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

_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

end of thread, other threads:[~2019-02-12  6:30 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-11 13:29 [DistroKit] [PATCH] v7a: image-vexpress: remove unneeded partition Roland Hieber
2019-02-11 13:33 ` Robert Schwebel
2019-02-11 14:46   ` Michael Olbrich
2019-02-11 15:06     ` Robert Schwebel
2019-02-11 16:18   ` [DistroKit] [PATCH v2] v7a: image-vexpress: fix comment in image config Roland Hieber
2019-02-12  6:30     ` Robert Schwebel

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