[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [RFC v2 4/8] qcow2: extract image creation option parsi
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [RFC v2 4/8] qcow2: extract image creation option parsing |
Date: |
Mon, 20 Mar 2017 15:40:15 +0000 |
User-agent: |
Mutt/1.7.1 (2016-10-04) |
On Sat, Mar 18, 2017 at 08:14:45PM +0000, Nir Soffer wrote:
> > @@ -2235,7 +2284,7 @@ static int qcow2_create2(const char *filename,
> > int64_t total_size,
> > *header = (QCowHeader) {
> > .magic = cpu_to_be32(QCOW_MAGIC),
> > .version = cpu_to_be32(version),
> > - .cluster_bits = cpu_to_be32(cluster_bits),
> > + .cluster_bits = cpu_to_be32(ctz32(cluster_size)),
> >
>
> Is this related?
Yes, the main cluster_bits code was extracted into
qcow2_opt_get_cluster_size_del() above.
This is now the only place in qcow2_create2() the needs this value so I
inlined the expression and dropped the variable.
signature.asc
Description: PGP signature
- [Qemu-devel] [RFC v2 2/8] raw-format: add bdrv_measure() support, (continued)
- [Qemu-devel] [RFC v2 2/8] raw-format: add bdrv_measure() support, Stefan Hajnoczi, 2017/03/15
- [Qemu-devel] [RFC v2 3/8] qcow2: extract preallocation calculation function, Stefan Hajnoczi, 2017/03/15
- [Qemu-devel] [RFC v2 5/8] qcow2: add bdrv_measure() support, Stefan Hajnoczi, 2017/03/15
- [Qemu-devel] [RFC v2 4/8] qcow2: extract image creation option parsing, Stefan Hajnoczi, 2017/03/15
- [Qemu-devel] [RFC v2 6/8] qemu-img: add measure subcommand, Stefan Hajnoczi, 2017/03/15
- [Qemu-devel] [RFC v2 7/8] qemu-iotests: support per-format golden output files, Stefan Hajnoczi, 2017/03/15
- [Qemu-devel] [RFC v2 8/8] iotests: add test 178 for qemu-img measure, Stefan Hajnoczi, 2017/03/15
- Re: [Qemu-devel] [RFC v2 0/8] qemu-img: add measure sub-command, Nir Soffer, 2017/03/17