qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] How do you -sd squashfs.img without truncating?


From: Peter Maydell
Subject: Re: [Qemu-devel] How do you -sd squashfs.img without truncating?
Date: Tue, 30 May 2017 13:17:04 +0100

On 8 May 2017 at 06:08, Rob Landley <address@hidden> wrote:
> As far as I can tell "qemu-system-arm -M vexpress-a9" only implements sd
> card, not any conventional hard drive, and it uses an sdcard block size
> of 262144 bytes rounded down. This means when I create a squashfs image
> and feed it in through the sd card, it truncates it.
>
> Wouldn't -sd rounding _up_ be more useful?

This vaguely rings a bell but I forget exactly. I think the
intention is that you're supposed to pass it a file of
exactly the right length, not one that's too short. If we
rounded up, then it would create the awkward question of
"what happens when the guest writes into the bit of the
sd card image that doesn't actually exist in the image file".

I'm not strongly attached to the current behaviour (especially
if the behaviour for sd card images doesn't match that for
hd images and other kinds of disk), but I think that may have
been the "this is more complicated than it appears on the surface"
reason that nobody's got round to trying to change the behaviour.
It's been years though, so I might just be completely misremembering.

thanks
-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]