Eric Blake writes:
> On 11/09/2015 10:46 AM, Markus Armbruster wrote:
>> From: Eric Blake
>>
>> We have several tests that perform multiple sub-actions that are
>> expected to fail. Asserting that an error occurred, then clearing
>> it up to prepare for the next action, turned into enough
>> b
Eric Blake writes:
> On 11/06/2015 08:52 AM, Markus Armbruster wrote:
>> Eric Blake writes:
>>
>>> qapi-code-gen.txt already claims that types, commands, and
>>> events share a common namespace; set this in stone by further
>>> documenting that our introspection output will never have
>>> colli
On 11/10/2015 01:26 PM, Tkid wrote:
> Hi,all
>
> We are planning to reimplement colo proxy in userspace (Here is in
> qemu) to
> cache and compare net packets.This module is one of the important
> components
> of COLO project and now it is still in early stage, so any comments and
> feedback are
On 11/09/2015 10:42 PM, Alberto Garcia wrote:
> Sorry again for the late review, here are my comments:
>
> On Fri 16 Oct 2015 10:57:45 AM CEST, Wen Congyang wrote:
>> +void qmp_x_blockdev_change(ChangeOperation op, const char *parent,
>> + bool has_child, const char *chil
v2:
* PATCH 07: fix a comment typo [Eric]
* PATCH 12: tweak commit message [Eric]
The following changes since commit 9d5c1dc117d1ad881bbc76f6990ee1f9e9f8ef7f:
Merge remote-tracking branch 'remotes/stefanha/tags/block-pull-request' into
staging (2015-11-09 11:20:51 +)
are available in the
On 11/10/2015 03:46 PM, Sukadev Bhattiprolu wrote:
Alexey Kardashevskiy [a...@ozlabs.ru] wrote:
| >| When exactly does a socket become a module? The SPAPR spec uses "sockets"
here.
| >
| >I am trying to get the terminology too :-) Is socket a slot where a
| >module is attached?
|
| Sorry, no i
Hi,all
We are planning to reimplement colo proxy in userspace (Here is in qemu) to
cache and compare net packets.This module is one of the important components
of COLO project and now it is still in early stage, so any comments and
feedback are warmly welcomed,thanks in advance.
## Background
CO
On 2015/11/9 21:57, Stefan Hajnoczi wrote:
> On Mon, Nov 09, 2015 at 05:03:30PM +0800, arei.gong...@huawei.com wrote:
>> From: Gonglei
>>
>> 1. avoid possible superflous checking
>> 2. make code more robustness
>>
>> Signed-off-by: Gonglei
>> Reviewed-by: Fam Zheng
>> ---
>> v3: change the third
On 11/09/2015 10:59 PM, Leonid Bloch wrote:
> This series fixes issues with packet/octet counting in e1000's Statistic
> registers, fixes a bug in the packet address filtering procedure, and
> implements many MAC registers that were absent before, some Statistic
> counters among them.
>
> Besides
On Mon, 11/09 17:29, Kevin Wolf wrote:
> Am 09.11.2015 um 17:18 hat Paolo Bonzini geschrieben:
> >
> >
> > On 09/11/2015 17:04, Kevin Wolf wrote:
> > > Am 06.11.2015 um 11:22 hat Fam Zheng geschrieben:
> > >> The "pnum < nb_sectors" condition in deciding whether to actually copy
> > >> data is un
> Rather than trying to cater to multiple assembly instruction implementations
> ourselves, have you tried taking the ideas in this earlier thread?
> https://lists.gnu.org/archive/html/qemu-devel/2015-10/msg05298.html
>
> Ideally, libc's memcmp() will already be using the most efficient assembly
>
On 11/09/2015 10:59 PM, Leonid Bloch wrote:
> The array of uint8_t's which is introduced here, contains useful metadata
> about the MAC registers: if a register should be always accessible, or if
> it is accessible, but partly implemented, or if the register requires a
> certain compatibility fla
On 11/09/2015 06:07 AM, Markus Armbruster wrote:
> Eric Blake writes:
>
>> Checking that a given QAPISchemaObjectTypeVariant.name is a
>> member of the corresponding QAPISchemaEnumType of the owning
>> QAPISchemaObjectTypeVariants.tag_member ensures that there are
>> no collisions in the generate
On 11/09/2015 07:49 AM, Markus Armbruster wrote:
> Eric Blake writes:
>
>> Consolidate two common sequences of clash detection into a
>> new QAPISchemaObjectType.check_clash() helper method.
>>
>> No change to generated code.
>>
>> Signed-off-by: Eric Blake
>>
>> @@ -980,11 +980,7 @@ class QAPI
On Tue, Nov 10, 2015 at 12:13:50PM +1100, Alexey Kardashevskiy wrote:
> On 11/07/2015 08:12 AM, Benjamin Herrenschmidt wrote:
> >On Fri, 2015-11-06 at 13:12 +0530, Bharata B Rao wrote:
> >>Commit aa4bb5875231 (ppc: Add mmu_model defines for arch 2.03 and
> >>2.07)
> >>removed the mmu_model definiti
KVM_PPC_ALLOCATE_HTAB ioctl can return -ENOMEM for KVM guests and QEMU
never handled this correctly. But this didn't cause any problems till
now as KVM_PPC_ALLOCATE_HTAB ioctl returned with smaller than requested
HTAB when enough contiguous memory wasn't available in the host.
After the proposed ke
KVM_PPC_ALLOCATE_HTAB ioctl can now return errors and handle that
correctly in QEMU.
Also fix !CONFIG_KVM implementation of kvmppc_reset_htab() to return
0 instead of -1.
Changes in v1
- Add a patch to fix !CONFIG_KVM implementation of kvmppc_reset_htab()
so that make check passes fo
The !CONFIG_KVM implementation of kvmppc_reset_htab() returns -1
by default. Change this to return 0 so that we fall back to user space
HTAB allocation for emulated guests.
This fixes the make check failures for ppc64 emulated target.
Signed-off-by: Bharata B Rao
---
target-ppc/kvm_ppc.h | 2 +-
On 11/09/2015 12:11 PM, Markus Armbruster wrote:
> Eric Blake writes:
>
>> On 11/09/2015 06:00 AM, Markus Armbruster wrote:
>>> Eric Blake writes:
>>>
Consolidate two common sequences of clash detection into a
new QAPISchemaObjectType.check_clash() helper method.
No change to
On 11/09/2015 08:13 AM, Markus Armbruster wrote:
> Markus Armbruster writes:
>
>> Eric Blake writes:
>>
>>> Right now, our ad hoc parser ensures that we cannot have a
>>> flat union that introduces any qapi member names that would
>>> conflict with the non-variant qapi members already present
>>
On 11/09/2015 05:56 AM, Markus Armbruster wrote:
> Eric Blake writes:
>
>> Right now, our ad hoc parser ensures that we cannot have a
>> flat union that introduces any qapi member names that would
>> conflict with the non-variant qapi members already present
>> from the union's base type (see fla
On 11/09/2015 05:38 AM, Markus Armbruster wrote:
> Eric Blake writes:
>
>> From: Markus Armbruster
>>
>> Reduce the ugly flat union / simple union conditional by doing just
>> the essential work here, namely setting self.tag_member.
>> Move the rest to callers.
>>
>> @@ -1052,8 +1053,6 @@ class
Alexey Kardashevskiy [a...@ozlabs.ru] wrote:
| >| When exactly does a socket become a module? The SPAPR spec uses "sockets"
here.
| >
| >I am trying to get the terminology too :-) Is socket a slot where a
| >module is attached?
|
| Sorry, no idea.
Ok.
|
|
| >
| >I will change the variable n
On 11/10/2015 02:57 PM, Sukadev Bhattiprolu wrote:
Alexey Kardashevskiy [a...@ozlabs.ru] wrote:
| On 11/05/2015 10:06 AM, Sukadev Bhattiprolu wrote:
| >Implement RTAS_SYSPARM_PROCESSOR_MODULE_INFO parameter to rtas_get_sysparm()
| >call in qemu. This call returns the processor module (socket), ch
David Gibson [da...@gibson.dropbear.id.au] wrote:
| On Wed, Nov 04, 2015 at 03:06:05PM -0800, Sukadev Bhattiprolu wrote:
| > Implement RTAS_SYSPARM_PROCESSOR_MODULE_INFO parameter to rtas_get_sysparm()
| > call in qemu. This call returns the processor module (socket), chip and core
| > information
Alexey Kardashevskiy [a...@ozlabs.ru] wrote:
| On 11/05/2015 10:06 AM, Sukadev Bhattiprolu wrote:
| >Implement RTAS_SYSPARM_PROCESSOR_MODULE_INFO parameter to rtas_get_sysparm()
| >call in qemu. This call returns the processor module (socket), chip and core
| >information as specified in section 7.
On 11/09/2015 08:44 PM, Max Reitz wrote:
> Just specifying a custom string is simpler in basically all places that
> used it, and in addition, specifying the BB or node name is something we
> generally do not do in other error messages when opening a BDS, so we
> should not do it here.
>
> This ch
On Tue, Nov 10, 2015 at 04:49:12AM +0100, Max Reitz wrote:
> On 10.11.2015 04:45, Eric Blake wrote:
> > [side question]
> >
> > On 11/09/2015 08:27 PM, Max Reitz wrote:
> >> Overall, this series adds more uses for BlockBackends and makes the code
> >> follow the "reference theory" more closely, in
On 10.11.2015 04:45, Eric Blake wrote:
> [side question]
>
> On 11/09/2015 08:27 PM, Max Reitz wrote:
>> Overall, this series adds more uses for BlockBackends and makes the code
>> follow the "reference theory" more closely, in that any BlockBackend
>> created (through -drive or blockdev-add) has
It is unused now, so we may just as well drop it.
Signed-off-by: Max Reitz
---
block.c | 5 -
include/block/block.h | 1 -
2 files changed, 6 deletions(-)
diff --git a/block.c b/block.c
index 395b7b0..0531992 100644
--- a/block.c
+++ b/block.c
@@ -243,11 +243,6 @@ void bdrv_re
[side question]
On 11/09/2015 08:27 PM, Max Reitz wrote:
> Overall, this series adds more uses for BlockBackends and makes the code
> follow the "reference theory" more closely, in that any BlockBackend
> created (through -drive or blockdev-add) has a reference count of 1, and
> that reference sho
Its only caller is blk_new_open(), so we can just inline it there. Since
bdrv_new_root() is only a wrapper around bdrv_new(), we can just use
bdrv_new() instead.
Signed-off-by: Max Reitz
---
block/block-backend.c | 29 +++--
1 file changed, 7 insertions(+), 22 deletions(-
There are no callers to bdrv_open() or bdrv_open_inherit() left that
pass a pointer to a non-NULL BDS pointer as the first argument of these
functions, so we can finally drop that parameter and just make them
return the new BDS.
Generally, the following pattern is applied:
bs = NULL;
ret
If bdrv_open_inherit() creates a snapshot BDS and *pbs is NULL, that
snapshot BDS should be returned instead of the BDS under it.
To this end, bdrv_append_temp_snapshot() now returns the snapshot BDS
instead of just appending it on top of the snapshotted BDS, and that
function is made static since
Just specifying a custom string is simpler in basically all places that
used it, and in addition, specifying the BB or node name is something we
generally do not do in other error messages when opening a BDS, so we
should not do it here.
This changes the output for iotest 036 (to the better, in my
The only caller of bdrv_close() left is bdrv_delete(). We may as well
assert that, in a way (there are some things in bdrv_close() that make
more sense under that assumption, such as the call to
bdrv_release_all_dirty_bitmaps() which in turn assumes that no frozen
bitmaps are attached to the BDS).
After a lot has been restructed in the block layer in the past, we can
now reap at least one of the fruits: Make bdrv_open() return a BDS!
I tried to squeeze patch 8 of this series into my bdrv_close_all()
series but noticed that won't work because bdrv_open_inherit() still has
one instance of bdr
The information which BB is concerned does not seem useful enough to
justify its existence in most other place (which may be related to qemu
printing the -drive parameter in question anyway, and for blockdev-add
the attribution is naturally unambiguous). Furthermore, as of a future
patch, bdrv_get_
bdrv_append_temp_snapshot() uses bdrv_new() to create an empty BDS
before invoking bdrv_open() on that BDS. This is probably a relict from
when it used to do some modifications on that empty BDS, but now that is
unnecessary, so we can just set bs_snapshot to NULL and let bdrv_open()
do the rest.
T
On 11/09/2015 07:51 PM, Liang Li wrote:
> buffer_find_nonzero_offset() is a hot function during live migration.
> Now it use SSE2 intructions for optimization. For platform supports
> AVX2 instructions, use the AVX2 instructions for optimization can help
> to improve the performance about 30% compa
buffer_find_nonzero_offset() is a hot function during live migration.
Now it use SSE2 intructions for optimization. For platform supports
AVX2 instructions, use the AVX2 instructions for optimization can help
to improve the performance about 30% comparing to SSE2.
Zero page check can be faster with
Add the '--enable-avx2' & '--disable-avx2' option so as to config
the AVX2 instruction optimization.
By default, avx2 optimization is enabled, if '--disable-avx2' is not
set, configure will detect if the compiler can support AVX2 option,
if yes, AVX2 optimization is eabled, else disabled.
Signed-
buffer_find_nonzero_offset() is a hot function during live migration.
Now it use SSE2 intructions for optimization. For platform supports
AVX2 instructions, use the AVX2 instructions for optimization can help
to improve the performance about 30% comparing to SSE2.
Zero page check can be faster with
This function first removed the BlockBackend from the blk_backends list
and cleared its name so it would no longer be found by blk_name(); since
blk_next() now iterates through monitor_block_backends (which the BB is
removed from in hmp_drive_del()), this is no longer necessary.
Second, bdrv_make_
Every entry in this list should be a root BDS and as such either be
anchored to a BlockBackend or be owned by the monitor.
Signed-off-by: Max Reitz
---
block.c | 30 +-
blockdev.c| 8
include/block/block.h | 1 -
includ
Replace bdrv_drain_all(), bdrv_commmit_all(), bdrv_flush_all(),
bdrv_invalidate_cache_all(), bdrv_next() and occurrences of bdrv_states
by their BlockBackend equivalents.
Signed-off-by: Max Reitz
---
block.c | 10
block/block-backend.c | 8 +++
block/qapi.c |
Move bdrv_drain_all(), bdrv_commit_all(), bdrv_flush_all() and
bdrv_invalidate_cache_all() to BB.
The only operation left is bdrv_close_all(), which cannot be moved to
the BB because it should not only close all BBs, but also all
monitor-owned BDSs.
Signed-off-by: Max Reitz
---
block.c
Overall, this series adds more uses for BlockBackends and makes the code
follow the "reference theory" more closely, in that any BlockBackend
created (through -drive or blockdev-add) has a reference count of 1, and
that reference should be held by the monitor. This is reflected here by
introducing
The monitor does hold references to some BlockBackends so it should have
a list of those BBs; blk_backends is a different list, as it contains
references to all BBs (after a follow-up patch, that is), and that
should not be changed because we do need such a list.
monitor_remove_blk() is idempotent
This function skips to the next BlockBackend for which blk_is_inserted()
is true.
Signed-off-by: Max Reitz
Reviewed-by: Eric Blake
---
block/block-backend.c | 15 +++
include/sysemu/block-backend.h | 1 +
2 files changed, 16 insertions(+)
diff --git a/block/block-backend.
There may be BlockBackends which are not returned by blk_by_name(), but
do exist and have a name. blk_name_taken() allows testing whether a
specific name is in use already, independent of whether the BlockBackend
with that name is accessible through blk_by_name().
Signed-off-by: Max Reitz
Reviewe
These functions will be changed to iterate through the BDS trees as
defined by the BlockBackends instead of the list of root BDS, therefore
prepare moving their code to the BlockBackend level.
Signed-off-by: Max Reitz
Reviewed-by: Eric Blake
---
block/block-backend.c | 10 ++
i
buffer_find_nonzero_offset() is a hot function during live migration.
Now it use SSE2 intructions for optimization. For platform supports
AVX2 instructions, use the AVX2 instructions for optimization can help
to improve the performance about 30% comparing to SSE2.
Zero page check can be faster with
Add the '--enable-avx2' & '--disable-avx2' option so as to config
the AVX2 instruction optimization.
By default, avx2 optimization is enabled, if '--disable-avx2' is not
set, configure will detect if the compiler can support AVX2 option,
if yes, AVX2 optimization is eabled, else disabled.
Signed-
buffer_find_nonzero_offset() is a hot function during live migration.
Now it use SSE2 intructions for optimization. For platform supports
AVX2 instructions, use the AVX2 instructions for optimization can help
to improve the performance about 30% comparing to SSE2.
Zero page check can be faster with
On 11/09/2015 09:14 PM, Cornelia Huck wrote:
> On Fri, 6 Nov 2015 16:02:49 +0800
> Jason Wang wrote:
>
>> Guest always get zero when reading queue_enable. This violates
>> spec. Fixing this by setting the queue_enable to true during any guest
>> writing and setting it to zero during reset.
>>
>
On Mon, 11/09 08:09, Peter Lieven wrote:
> recent libnfs versions support logging debug messages. Add
> support for it in qemu through an URL parameter.
>
> Example:
> qemu -cdrom nfs://127.0.0.1/iso/my.iso?debug=2
>
> Signed-off-by: Peter Lieven
> ---
> v4->v5: add a comment in the code why we
On 11/09/2015 08:56 PM, Cornelia Huck wrote:
> On Fri, 6 Nov 2015 16:02:44 +0800
> Jason Wang wrote:
>
>> We don't migrate the followings fields for virtio-pci:
>>
>> uint32_t dfselect;
>> uint32_t gfselect;
>> uint32_t guest_features[2];
>> struct {
>> uint16_t num;
>> bool enabled;
>>
On 11/10/2015 12:04 AM, Kevin Wolf wrote:
> Am 16.10.2015 um 10:57 hat Wen Congyang geschrieben:
>> +##
>> +# @ChangeOperation:
>> +#
>> +# An enumeration of block device change operation.
>> +#
>> +# @add: Add a new block driver state to a existed block driver state.
>> +#
>> +# @delete: Delete a
On 09.11.2015 23:39, Max Reitz wrote:
> Signed-off-by: Max Reitz
> Reviewed-by: Kevin Wolf
> ---
> blockdev.c | 25 +
> include/block/block_int.h | 4
> stubs/Makefile.objs| 1 +
> stubs/blockdev-close-al
On 11/07/2015 08:12 AM, Benjamin Herrenschmidt wrote:
On Fri, 2015-11-06 at 13:12 +0530, Bharata B Rao wrote:
Commit aa4bb5875231 (ppc: Add mmu_model defines for arch 2.03 and
2.07)
removed the mmu_model definition POWERPC_MMU_2_06a which is needed by
PR KVM. Reintroduce it and also add POWERPC_
On 11/09/15 14:01, Eduardo Habkost wrote:
> On Mon, Nov 09, 2015 at 08:33:55AM +0800, haozhong.zh...@intel.com wrote:
> > On 11/06/15 13:12, Eduardo Habkost wrote:
> > > On Fri, Nov 06, 2015 at 10:32:24AM +0800, haozhong.zh...@intel.com wrote:
> > > > On 11/05/15 14:05, Eduardo Habkost wrote:
> > >
Just noticed this while grepping TARGET_PAGE_SIZE for an unrelated
reason. I didn't use qemu_real_host_page_size as kvm_set_phys_mem()
does, because we'd need to make sure page_size_init() has run first.
Signed-off-by: Andrew Jones
---
kvm-all.c | 6 --
1 file changed, 4 insertions(+), 2 del
Hi,
For future revisions, could you send all patches in the series (even
if unchanged)? It makes it much easier to know which patches are the
latest.
Also, if you can rebase each release on the qemu master branch, that
would be preferred (or on a submaintainers tree, just mention that in
the cov
Organize the prototypes into nice little sections.
Signed-off-by: John Snow
---
tests/libqos/ahci.h | 36
1 file changed, 24 insertions(+), 12 deletions(-)
diff --git a/tests/libqos/ahci.h b/tests/libqos/ahci.h
index 2c2d2fc..69dc4d7 100644
--- a/tests/libqo
As part of streamlining the AHCI tests interface, it'd be nice
if specying a size of zero could be handled without special branches
and the allocator could handle this special case gracefully.
This lets me use the "ahci_io" macros for non-data commands, too,
which moves me forward towards shepherd
Simple I/O tests for DMA and PIO pathways in the AHCI HBA.
I believe at this point in time all of the common, major IO pathways
in BMDMA and AHCI are covered by qtests now.
Signed-off-by: John Snow
---
tests/ahci-test.c | 97 +++
1 file change
On 11/06/2015 03:42 AM, Peter Lieven wrote:
> PIO read requests on the ATAPI interface used to be sync blk requests.
> This has two significant drawbacks. First the main loop hangs util an
> I/O request is completed and secondly if the I/O request does not
> complete (e.g. due to an unresponsive
These variants try to set a data offset, even if you don't specify one.
In the cases where the offset is zero and it's a nondata command, just
ignore the instruction.
Signed-off-by: John Snow
---
tests/ahci-test.c | 14 ++
tests/libqos/ahci.c | 3 +++
2 files changed, 5 insertions
add ahci_exec, which is a standard purpose flexible command dispatcher
and tester for the AHCI device. The intent is to eventually cut down on
the absurd amount of boilerplate inside of the AHCI qtest.
Signed-off-by: John Snow
---
tests/libqos/ahci.c | 76
Add pathways to tolerate ATAPI commands.
Notably, unlike ATA, each SCSI command's layout is a little different,
so support will have to be patched in for each command as we want to
test them in e.g. ahci_command_set_sizes and ahci_command_set_offset.
For now, I'm adding support for 0x28, READ (10
Add ATAPI support into libqos/ahci, and write a few tests for it.
I intend this for 2.5, as it's just a test and might help unearth
some bugs during release candidate testing.
This is the last "batch" of planned qtests for s/ata -- basic i/o
testing of HDDs and CDROMs on both PCI and AHCI should b
Use the proper free command to detroy an AHCICommand.
Signed-off-by: John Snow
---
tests/ahci-test.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/ahci-test.c b/tests/ahci-test.c
index 59d387c..8370fa3 100644
--- a/tests/ahci-test.c
+++ b/tests/ahci-test.c
@@ -103
We need to say "hello!" to our ATAPI friends
in a slightly different manner.
Signed-off-by: John Snow
---
tests/ahci-test.c | 8 +++-
tests/libqos/ahci.c | 5 +
tests/libqos/ahci.h | 1 +
3 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/tests/ahci-test.c b/tests/ahci-test
ATAPI commands are, unfortunately, weird in that they can
be either DMA or PIO depending on a header bit. In order to
accommodate them, I'll need to make AHCI command properties
mutable so we can toggle between which "flavor" of ATAPI command
we want to test.
The default ATAPI transfer mechanism i
Bandan Das writes:
> Gerd Hoffmann writes:
>
>> On Di, 2015-11-03 at 19:00 -0500, Bandan Das wrote:
>>> +/* Add a new watch asap so as to not lose events
>>> */
>>
>> This comment sounds like there is a race ("asap"). There isn't one,
>> correct ordering (adding the watch be
Gerd Hoffmann writes:
> On Di, 2015-11-03 at 19:00 -0500, Bandan Das wrote:
>> +case IN_DELETE:
>> +/*
>> + * The kernel issues a IN_IGNORED event
>> + * when a dir containing a watchpoint is
>> + * deleted
>> +
Gerd Hoffmann writes:
> On Di, 2015-11-03 at 19:00 -0500, Bandan Das wrote:
>> +/* Add a new watch asap so as to not lose events
>> */
>
> This comment sounds like there is a race ("asap"). There isn't one,
> correct ordering (adding the watch before reading the directory) is
This patch rewrites bdrv_close_all(): Until now, all root BDSs have been
force-closed. This is bad because it can lead to cached data not being
flushed to disk.
Instead, try to make all reference holders relinquish their reference
voluntarily:
1. All BlockBackend users are handled by making all B
We need this list so that bdrv_close_all() can keep track of which BDSs
are still open after having removed the BDSs from all of the BBs and
having released all monitor BDS references.
Signed-off-by: Max Reitz
Reviewed-by: Kevin Wolf
---
block.c | 7 +++
include/block/bloc
Suggested-by: Paolo Bonzini
Signed-off-by: Max Reitz
---
tests/qemu-iotests/141 | 166 +
tests/qemu-iotests/141.out | 47 +
tests/qemu-iotests/group | 1 +
3 files changed, 214 insertions(+)
create mode 100755 tests/qemu-iotests/1
There are no users of bdrv_close() left, except for one of bdrv_open()'s
failure paths, bdrv_close_all() and bdrv_delete(), and that is good.
Make bdrv_close() static so nobody makes the mistake of directly using
bdrv_close() again.
Signed-off-by: Max Reitz
Reviewed-by: Eric Blake
Reviewed-by: A
Signed-off-by: Max Reitz
Reviewed-by: Kevin Wolf
---
block/block-backend.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/block/block-backend.c b/block/block-backend.c
index a00486c..4523387 100644
--- a/block/block-backend.c
+++ b/block/block-backend.c
@@ -165,10 +16
The NBD code uses the BDS close notifier to determine when a medium is
ejected. However, now it should use the BB's BDS removal notifier for
that instead of the BDS's close notifier.
Signed-off-by: Max Reitz
---
blockdev-nbd.c | 37 +
nbd.c | 13 +
This adds a test for having multiple BlockBackends in one BDS tree. In
this case, there is one BB for the protocol BDS and one BB for the
format BDS in a simple two-BDS tree (with the protocol BDS and BB added
first).
When bdrv_close_all() is executed, no cached data from any BDS should be
lost; t
It is unused now, so we can remove it.
Signed-off-by: Max Reitz
---
block.c| 7 ---
block/block-backend.c | 7 ---
include/block/block.h | 1 -
include/block/block_int.h | 2 --
include/sysemu/block-backend.h | 1 -
5 files changed, 18 delet
bdrv_close() no longer signifies ejection of a medium, this is now done
by removing the BDS from the BB. Therefore, we want to have a notifier
for that in the BB instead of a close notifier in the BDS. The former is
added now, the latter is removed later.
Symmetrically, another notifier list is ad
Signed-off-by: Max Reitz
Reviewed-by: Kevin Wolf
---
blockdev.c | 25 +
include/block/block_int.h | 4
stubs/Makefile.objs| 1 +
stubs/blockdev-close-all-bdrv-states.c | 5 +
4 files changed, 35 inse
Redirecting qemu's stderr to stdout makes working with the stderr output
difficult due to the other file descriptor magic performed in
_launch_qemu ("ambiguous redirect").
Add an option which specifies whether stderr should be redirected to
stdout or not (allowing for other modes to be added in th
In order to be able to move _filter_nbd to common.filter in the next
patch, its coding style needs to be adapted to that of common.filter.
That means, we have to convert tabs to four spaces, adjust the alignment
of the last line (done with spaces already, assuming one tab equals
eight spaces), fix
Signed-off-by: Max Reitz
Reviewed-by: Kevin Wolf
---
blockdev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/blockdev.c b/blockdev.c
index 3185808..a70a684 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -2509,7 +2509,7 @@ void hmp_drive_del(Monitor *mon, const QDict *qdict)
When bdrv_close_all() is called, instead of force-closing all root
BlockDriverStates, it is better to just drop the reference from all
BlockBackends and let them be closed automatically. This prevents BDS
from getting closed that are still referenced by other BDS, which may
result in loss of cached
This function should support URLs of the "nbd://" format (without
swallowing the export name), and for "nbd:///" URLs it should replace
"?socket=$TEST_DIR" by "?socket=TEST_DIR" because putting the Unix
socket files into the test directory makes sense.
Signed-off-by: Max Reitz
---
tests/qemu-iot
This patch adds a test for ejecting the BlockBackend an NBD server is
connected to (the NBD server is supposed to stop).
Signed-off-by: Max Reitz
---
tests/qemu-iotests/140 | 92 ++
tests/qemu-iotests/140.out | 16
tests/qemu-iotests/group
In the patch after the next, this function is moved to common.filter.
Therefore, its name should be preceded by an underscore to signify its
global availability.
To keep the code motion patch clean, we cannot rename it in the same
patch, so we need to choose some order of renaming vs. motion. It i
Make use of the BDS-BB removal and insertion notifiers to remove or set
up, respectively, virtio-scsi's op blockers.
Signed-off-by: Max Reitz
---
hw/scsi/virtio-scsi.c | 59 +
include/hw/virtio/virtio-scsi.h | 10 +++
2 files changed, 69 inse
If block_job_create() fails, it should release its reference to the
job's BDS. Normally, this is done in the callback provided by the
caller, but that callback will not be invoked if the block job failed to
be created.
Signed-off-by: Max Reitz
Reviewed-by: Alberto Garcia
Reviewed-by: Kevin Wolf
The NBD log lines ("/your/source/dir/nbd.c:function():line: error")
should not be converted to empty lines but removed altogether.
Signed-off-by: Max Reitz
---
tests/qemu-iotests/083.out | 10 --
tests/qemu-iotests/common.filter | 2 +-
2 files changed, 1 insertion(+), 11 deletion
_filter_nbd can be useful for other NBD tests, too, therefore it should
reside in common.filter.
Signed-off-by: Max Reitz
---
tests/qemu-iotests/083 | 12
tests/qemu-iotests/common.filter | 12
2 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/t
Put the code for setting up and removing op blockers into an own
function, respectively. Then, we can invoke those functions whenever a
BDS is removed from an virtio-blk BB or inserted into it.
Signed-off-by: Max Reitz
---
hw/block/dataplane/virtio-blk.c | 77 +++-
1 - 100 of 465 matches
Mail list logo