Now that the PIIX IDE device models check for presence of an ISABus before
using it, this fix isn't needed any longer.
This reverts commit 9405d87be25db6dff4d7b5ab48a81bbf6d083e47.
Signed-off-by: Bernhard Beschow
---
hw/ide/ioport.c | 16 ++--
hw/ide/piix.c |
This is an alternative solution to commit
9405d87be25db6dff4d7b5ab48a81bbf6d083e47 'hw/ide: Fix crash when plugging a
piix3-ide device into the x-remote machine' which allows for cleaning up the
ISA API while keeping PIIX IDE functions user-createable for an arbitrarily
long deprecation period.
Si
This series resolves the global "isabus" variable and is basically a v2 of [1].
Note that the majority of the work consists of fixing ISA API calls in PIIX IDE
which implicitly rely on the usage of the isabus global.
Rather than adding an ISABus pointer in PCIIDEState as in "v1" this series uses
a
This should fix the last caller causing a NULL ISADev to be passed to
isa_register_portio_list() which now allows for disusing the isabus global
there.
Signed-off-by: Bernhard Beschow
---
hw/ide/piix.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/ide/piix.c b/hw/ide/pii
The next patch will introduce a quirk for user-created PIIX IDE devices for
backwards compatibility. In order to opt-in to new behavior for builtin
devices a property will need to be set until a deprecation period is over.
Signed-off-by: Bernhard Beschow
---
hw/i386/pc_piix.c | 3 ++-
1 file cha
ide_init_ioport() takes an ISADevice* parameter which eventually gets passed
to isa_address_space_io(). Unfortunately, there is no ISADevice in hw/ide/
piix, so NULL gets passed instead. This causes isa_address_space_io() to
resort to using the isabus global - which we want to get rid of.
To resol
Now that all call sites of these functions are fixed to pass non-NULL
ISADevices, the ISABus can be determined from the ISADevice argument.
Patch based on https://lists.nongnu.org/archive/html/qemu-devel/2021-05/
msg05785.html.
Signed-off-by: Bernhard Beschow
---
hw/ide/ioport.c | 4 ++--
Now that only isa_bus_new() accesses the isabus global it can be removed
assuming that all call sites take care of not passing the same address
spaces twice to different isa_bus_new() invocations.
Signed-off-by: Bernhard Beschow
---
hw/isa/isa-bus.c | 8 ++--
1 file changed, 2 insertions(+),
pci_ide_init_ioport() and pci_register_portio_list() are introduced which
mirror their ISA counterparts. But rather than asking for an ISADevice, the
functions ask for PCIDevice which can be used in hw/ide/piix which fixes
having to pass a NULL ISADevice which is not avialable there.
Passing NULL
Now that all call-sites have been fixed to pass non-NULL ISADevices, we can
assert() on NULL ISADevices to catch regressions.
Signed-off-by: Bernhard Beschow
---
hw/isa/isa-bus.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/hw/isa/isa-bus.c b/hw/isa/isa-bus.c
index 05
isa_get_irq() currently always uses the "isabus" global to get the
desired qemu_irq. In order to resolve this global, we want
isa_get_irq() to determine the ISABus from its *dev parameter using
isa_bus_from_device(). As a preparation, all callers who pass NULL
as *dev need to be resolved which seem
On 6/27/22 02:19, Sam Li wrote:
By adding zone management operations in BlockDriver, storage
controller emulation can use the new block layer APIs including
zone_report and zone_mgmt(open, close, finish, reset).
---
block/block-backend.c| 56
block/coroutines.h
On 6/27/22 02:19, Sam Li wrote:
Use sysfs attribute files to get the zoned device information in case
that ioctl() commands of zone management interface won't work. It can
return long type of value like chunk_sectors, zoned_append_max_bytes,
max_open_zones, max_active_zones.
---
block/file-posi
On 6/27/22 02:19, Sam Li wrote:
---
Good coding style would advise to add some text here what the patch does.
block/io.c | 21 +++
include/block/block-io.h | 13 +
qemu-io-cmds.c | 121 +++
3 files changed, 155 inserti
On 6/27/22 02:19, Sam Li wrote:
---
block/file-posix.c | 60
include/block/block-common.h | 4 +--
2 files changed, 62 insertions(+), 2 deletions(-)
diff --git a/block/file-posix.c b/block/file-posix.c
index 73c2cdfbca..74c0245e0f 100644
--- a/
On 6/27/22 02:19, Sam Li wrote:
---
tests/qemu-iotests/tests/zoned.sh | 49 +++
1 file changed, 49 insertions(+)
create mode 100755 tests/qemu-iotests/tests/zoned.sh
diff --git a/tests/qemu-iotests/tests/zoned.sh
b/tests/qemu-iotests/tests/zoned.sh
new file mode
Hi Hannes,
Hannes Reinecke 于2022年6月27日周一 15:21写道:
>
> On 6/27/22 02:19, Sam Li wrote:
> > By adding zone management operations in BlockDriver, storage
> > controller emulation can use the new block layer APIs including
> > zone_report and zone_mgmt(open, close, finish, reset).
> > ---
> > bloc
Hannes Reinecke 于2022年6月27日周一 15:30写道:
>
> On 6/27/22 02:19, Sam Li wrote:
> > ---
>
> Good coding style would advise to add some text here what the patch does.
>
> > block/io.c | 21 +++
> > include/block/block-io.h | 13 +
> > qemu-io-cmds.c | 121 ++
Hannes Reinecke 于2022年6月27日周一 15:31写道:
>
> On 6/27/22 02:19, Sam Li wrote:
> > Use sysfs attribute files to get the zoned device information in case
> > that ioctl() commands of zone management interface won't work. It can
> > return long type of value like chunk_sectors, zoned_append_max_bytes,
>
On Mon, Jun 27, 2022 at 12:45 PM Markus Armbruster wrote:
>
> Kevin Wolf writes:
>
> > From: Xie Yongji
> >
> > VDUSE [1] is a linux framework that makes it possible to implement
> > software-emulated vDPA devices in userspace. This adds a library
> > as a subproject to help implementing VDUSE b
Hannes Reinecke 于2022年6月27日周一 15:41写道:
>
> On 6/27/22 02:19, Sam Li wrote:
> > ---
> > block/file-posix.c | 60
> > include/block/block-common.h | 4 +--
> > 2 files changed, 62 insertions(+), 2 deletions(-)
> >
> > diff --git a/block/file-posix.
Coverity reported a string overflow issue since we copied
"name" to "dev_config->name" without checking the length.
This should be a false positive since we already checked
the length of "name" in vduse_name_is_invalid(). But anyway,
let's replace strcpy() with strncpy() to fix the coverity
complai
In vduse_name_is_valid(), we actually check whether
the name is invalid or not. So let's change the
function name to vduse_name_is_invalid() to match
the behavior.
Signed-off-by: Xie Yongji
---
subprojects/libvduse/libvduse.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --gi
This series fixes some issues reported by coverity.
Patch 1 fixes an incorrect function name.
Patch 2 fixes Coverity CID 1490224.
Patch 3 fixes Coverity CID 1490226, 1490223.
Patch 4 fixes Coverity CID 1490222, 1490227.
Xie Yongji (4):
libvduse: Fix the incorrect function name
libvduse: Re
Coverity pointed out (CID 1490222, 1490227) that we called
ioctl somewhere without checking the return value. This
patch fixes these issues.
Fixes: Coverity CID 1490222, 1490227
Signed-off-by: Xie Yongji
---
subprojects/libvduse/libvduse.c | 10 --
1 file changed, 8 insertions(+), 2 dele
The value passed to strerror() should be positive.
So let's fix it.
Fixes: Coverity CID 1490226, 1490223
Signed-off-by: Xie Yongji
---
subprojects/libvduse/libvduse.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/subprojects/libvduse/libvduse.c b/subprojects/libvduse/li
On 6/24/22 20:30, Iris Chen wrote:
Signed-off-by: Iris Chen
Reviewed-by: Cédric Le Goater
Thanks,
C.
---
Adding Signed Off By tag -- sorry I missed that !
tests/qtest/aspeed_smc-test.c | 62 +++
1 file changed, 62 insertions(+)
diff --git a/tests/qtest
CRMS.CRWMS bit shall be set to 1 on controllers compliant with versions
later than NVMe 1.4.
The first version later than NVMe 1.4 is NVMe 2.0
Let's claim compliance with NVMe 2.0 such that a follow up patch can
set the CRMS.CRWMS bit.
This is needed since CC.CRIME is only writable when both CRM
Hello there,
considering that Linux v5.19 will include support for NVMe TP4084:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/drivers/nvme/host/core.c?id=354201c53e61e493017b15327294b0c8ab522d69
I thought that it might be nice to have QEMU support for the same.
TP4084
Since we verify that "ready_delay" parameter has to be smaller than CRWMT,
we know that the namespace will always become ready.
Therefore the "Namespace Not Ready" status code will never have the DNR
bit set.
Add a new parameter "never_ready" that can be used to emulate a namespace
that never gets
Each NvmeNamespace can be used by serveral controllers,
but a NvmeNamespace can at most belong to a single NvmeSubsystem.
Store a pointer to the NvmeSubsystem, if the namespace was realized
with a NvmeSubsystem.
This will be used by a follow up patch.
Signed-off-by: Niklas Cassel
---
hw/nvme/ns
TP4084 adds a new mode, CC.CRIME, that can be used to mark a namespace
as ready independently from the controller.
When CC.CRIME is 0 (default), things behave as before, all namespaces
are ready when CSTS.RDY gets set to 1.
When CC.CRIME is 1, the controller will become ready when CSTS.RDY gets
s
* Daniel P. Berrangé (berra...@redhat.com) wrote:
> This directly implements the get_buffer logic using QIOChannel APIs.
>
> Reviewed-by: Dr. David Alan Gilbert
> Signed-off-by: Daniel P. Berrangé
Coverity is pointing out a fun deadcode path from this:
> diff --git a/migration/qemu-file.c b/mi
The serial prop on the controller is actually describing the nvme
subsystem serial, which has to be identical for all controllers within
the same nvme subsystem.
This is enforced since commit a859eb9f8f64 ("hw/nvme: enforce common
serial per subsystem").
Fix the documentation, so that people copy
With REPLY_NEEDED, libvhost-user sends both the acutal result and an
additional ACK reply for VHOST_USER_ADD_MEM_REG. This is incorrect, the
spec mandates that it behave the same with and without REPLY_NEEDED
because it always sends a reply.
Fixes: ec94c8e621de96c50c2d381c8c9ec94f5beec7c1
Signed-o
This reverts commit 76b1b64370007234279ea4cc8b09c98cbd2523de.
The commit only duplicated some text that had already been merged in
commit 31009d13cc5.
Signed-off-by: Kevin Wolf
---
docs/interop/vhost-user.rst | 16
1 file changed, 16 deletions(-)
diff --git a/docs/interop/vhos
With REPLY_NEEDED, libvhost-user sends both the acutal result and an
additional ACK reply for VHOST_USER_GET_MAX_MEM_SLOTS. This is
incorrect, the spec mandates that it behave the same with and without
REPLY_NEEDED because it always sends a reply.
Fixes: 6fb2e173d20c9bbb5466183d33a3ad7dcd0375fa
Si
On Mon, 27 Jun 2022 at 14:49, Kevin Wolf wrote:
>
> This reverts commit 76b1b64370007234279ea4cc8b09c98cbd2523de.
>
> The commit only duplicated some text that had already been merged in
> commit 31009d13cc5.
>
> Signed-off-by: Kevin Wolf
> ---
> docs/interop/vhost-user.rst | 16
Command handlers shouldn't send replies themselves, but just prepare the
message and let vu_dispatch() send it. Otherwise, vu_dispatch() will add
a second reply as an ACK when NEED_REPLY was requested.
QEMU's vhost-user devices are not affected by these bugs because they
don't set NEED_REPLY for t
On Jun 27 14:39, Niklas Cassel wrote:
> The serial prop on the controller is actually describing the nvme
> subsystem serial, which has to be identical for all controllers within
> the same nvme subsystem.
>
> This is enforced since commit a859eb9f8f64 ("hw/nvme: enforce common
> serial per subsys
On Mon, Jun 27, 2022 at 01:47:28PM +0200, Niklas Cassel via wrote:
> CRMS.CRWMS bit shall be set to 1 on controllers compliant with versions
> later than NVMe 1.4.
>
> The first version later than NVMe 1.4 is NVMe 2.0
>
> Let's claim compliance with NVMe 2.0 such that a follow up patch can
> set
Signed-off-by: Iris Chen
---
tests/qtest/aspeed_smc-test.c | 111 ++
1 file changed, 111 insertions(+)
diff --git a/tests/qtest/aspeed_smc-test.c b/tests/qtest/aspeed_smc-test.c
index 1258687eac..05ce941566 100644
--- a/tests/qtest/aspeed_smc-test.c
+++ b/tests/qt
Hey everyone,
Adding the 3 block protection bits and top bottom bits which configure which
parts
of the flash are writable and read-only.
These patches are based on previous patches I just submitted:
hw: m25p80: fixing individual test failure when tests are running in isolation
hw: m25p80: add W
Signed-off-by: Iris Chen
---
hw/block/m25p80.c | 74 +++
1 file changed, 62 insertions(+), 12 deletions(-)
diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c
index 50b523e5b1..0156a70f5e 100644
--- a/hw/block/m25p80.c
+++ b/hw/block/m25p80.c
@@ -38,21
On 6/25/22 00:49, Stefan Hajnoczi wrote:
> On Fri, Jun 24, 2022 at 11:14:32AM +0800, Sam Li wrote:
>> Hi Stefan,
>>
>> Stefan Hajnoczi 于2022年6月20日周一 15:55写道:
>>>
>>> On Mon, Jun 20, 2022 at 11:36:11AM +0800, Sam Li wrote:
>>>
>>> Hi Sam,
>>> Is this version 2 of "[RFC v1] Add support for zoned dev
On 6/27/22 14:32, Xie Yongji wrote:
-strcpy(dev_config->name, name);
+strncpy(dev_config->name, name, VDUSE_NAME_MAX);
+dev_config->name[VDUSE_NAME_MAX - 1] = '\0';
g_strlcpy
r~
On 6/27/22 14:32, Xie Yongji wrote:
The value passed to strerror() should be positive.
So let's fix it.
Fixes: Coverity CID 1490226, 1490223
Signed-off-by: Xie Yongji
---
subprojects/libvduse/libvduse.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
Reviewed-by: Richard Henderson
On Tue, Jun 28, 2022 at 8:26 AM Richard Henderson
wrote:
>
> On 6/27/22 14:32, Xie Yongji wrote:
> > -strcpy(dev_config->name, name);
> > +strncpy(dev_config->name, name, VDUSE_NAME_MAX);
> > +dev_config->name[VDUSE_NAME_MAX - 1] = '\0';
>
> g_strlcpy
>
Now we don't have a dependency
48 matches
Mail list logo