From: Klaus Jensen
The QSG isn't always initialized, so accounting could be wrong. Issue a
call to blk_acct_start instead with the size taken from the QSG or IOV
depending on the kind of I/O.
Signed-off-by: Klaus Jensen
Reviewed-by: Maxim Levitsky
Reviewed-by: Minwoo Im
---
hw/block/nvme.c |
From: Klaus Jensen
Add nvme_map_addr, nvme_map_addr_cmb and nvme_addr_to_cmb helpers and
use them in nvme_map_prp.
This fixes a bug where in the case of a CMB transfer, the device would
map to the buffer with a wrong length.
Fixes: b2b2b67a00574 ("nvme: Add support for Read Data and Write Data
From: Klaus Jensen
This is preparatory to subsequent patches that change how QSGs/IOVs are
handled. It is important that the qsg and iov members of the NvmeRequest
are initially zeroed.
Signed-off-by: Klaus Jensen
Reviewed-by: Maxim Levitsky
---
hw/block/nvme.c | 2 +-
1 file changed, 1 inser
From: Klaus Jensen
Introduce the nvme_map helper to remove some noise in the main nvme_rw
function.
Signed-off-by: Klaus Jensen
Reviewed-by: Maxim Levitsky
---
hw/block/nvme.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/hw/block/nvme.c b/hw/block/nvme.c
From: Klaus Jensen
Hoist bounds checking into its own function and check for wrap-around.
Signed-off-by: Klaus Jensen
Reviewed-by: Maxim Levitsky
Reviewed-by: Minwoo Im
---
hw/block/nvme.c | 26 +-
1 file changed, 21 insertions(+), 5 deletions(-)
diff --git a/hw/bloc
From: Klaus Jensen
Add tracing to nvme_map_prp.
Signed-off-by: Klaus Jensen
---
hw/block/nvme.c | 2 ++
hw/block/trace-events | 1 +
2 files changed, 3 insertions(+)
diff --git a/hw/block/nvme.c b/hw/block/nvme.c
index 571635ebe9f9..952afbb05175 100644
--- a/hw/block/nvme.c
+++ b/hw/blo
From: Klaus Jensen
This series consists of patches that refactors dma read/write and adds a
number of address mapping helper functions.
v2:
* hw/block/nvme: add mapping helpers
- Add an assert in case of out of bounds array access. (Maxim)
* hw/block/nvme: remove redundant has_sg member
From: Klaus Jensen
Since clean up of the request qsg/iov is now always done post-use, there
is no need to use a stack-allocated qsg/iov in nvme_dma_prp.
Signed-off-by: Klaus Jensen
Acked-by: Keith Busch
Reviewed-by: Maxim Levitsky
---
hw/block/nvme.c | 41 ++--
From: Klaus Jensen
Remove the has_sg member from NvmeRequest since it's redundant.
Signed-off-by: Klaus Jensen
---
hw/block/nvme.c | 7 ++-
hw/block/nvme.h | 1 -
2 files changed, 2 insertions(+), 6 deletions(-)
diff --git a/hw/block/nvme.c b/hw/block/nvme.c
index d60b19e1840f..a9d9a29126
From: Klaus Jensen
Before this patch the device already supported PRP lists in the CMB, but
it did not check for the validity of it nor announced the support in the
Identify Controller data structure LISTS field.
If some of the PRPs in a PRP list are in the CMB, then ALL entries must
be there. T
From: Klaus Jensen
Always destroy the request qsg/iov at the end of request use.
Signed-off-by: Klaus Jensen
---
hw/block/nvme.c | 52 -
1 file changed, 21 insertions(+), 31 deletions(-)
diff --git a/hw/block/nvme.c b/hw/block/nvme.c
index 3d727
From: Klaus Jensen
Add 'mdts' device parameter to control the Maximum Data Transfer Size of
the controller and check that it is respected.
Signed-off-by: Klaus Jensen
Reviewed-by: Maxim Levitsky
Reviewed-by: Minwoo Im
---
hw/block/nvme.c | 30 +-
hw/block/nv
From: Klaus Jensen
Make sure the request iov is destroyed before reuse; fixing a memory
leak.
Signed-off-by: Klaus Jensen
---
hw/block/nvme.c | 4
1 file changed, 4 insertions(+)
diff --git a/hw/block/nvme.c b/hw/block/nvme.c
index a9d9a2912655..8f8257e06eed 100644
--- a/hw/block/nvme.c
From: Klaus Jensen
Refactor the nvme_dma_{read,write}_prp functions into a common function
taking a DMADirection parameter.
Signed-off-by: Klaus Jensen
Reviewed-by: Maxim Levitsky
Reviewed-by: Minwoo Im
---
hw/block/nvme.c | 91 +
1 file change
From: Klaus Jensen
Instead of passing around the NvmeNamespace and the NvmeCmd, add them as
members in the NvmeRequest structure.
Signed-off-by: Klaus Jensen
Reviewed-by: Minwoo Im
Reviewed-by: Maxim Levitsky
---
hw/block/nvme.c | 187 ++--
hw/bloc
Right now we create lock/pid file in /usr/local/var/... and unprivliged
user does not have access to create files there.
So create this file in per user cache dir as queried as specified
by environment variable XDG_RUNTIME_DIR.
Note: "su $USER" does not update XDG_RUNTIME_DIR and it still points
From: Klaus Jensen
Since nvme_map_prp always operate on the request-scoped qsg/iovs, just
pass a single pointer to the NvmeRequest instead of two for each of the
qsg and iov.
Suggested-by: Minwoo Im
Signed-off-by: Klaus Jensen
---
hw/block/nvme.c | 11 +++
1 file changed, 7 insertions
Hi,
Daniel Berrange mentioned that having a unpriviliged mode in virtiofsd
might be useful for certain use cases. Hence I decided to give it
a try.
This is RFC patch series to allow running virtiofsd as unpriviliged
user. This is still work in progress. I am posting it to get
some early feedback
From: Klaus Jensen
The NVM Express specification generally uses 'zeroes' and not 'zeros',
so let us align with it.
Cc: Fam Zheng
Signed-off-by: Klaus Jensen
Reviewed-by: Minwoo Im
Reviewed-by: Maxim Levitsky
---
block/nvme.c | 4 ++--
hw/block/nvme.c | 8
include/block
We need /proc/self/fd descriptor even in sandbox=NONE mode.
Signed-off-by: Vivek Goyal
---
tools/virtiofsd/passthrough_ll.c | 13 -
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/tools/virtiofsd/passthrough_ll.c b/tools/virtiofsd/passthrough_ll.c
index cd91c4a831..76ef
While running as unpriviliged user setup_capabilities() fails for me.
So we are doing some operation which requires priviliges. For now
simply skip it in sandbox=NONE mode.
Signed-off-by: Vivek Goyal
---
tools/virtiofsd/passthrough_ll.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
di
In sandbox=NONE mode, lo->source points to the directory which is being
exported. We have not done any chroot()/pivot_root(). So open lo->source.
Signed-off-by: Vivek Goyal
---
tools/virtiofsd/passthrough_ll.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/tools/virtiofs
At startup if we are running as non-root user, then internall set
unpriviliged mode set. Also add a notion of sandbox NONE and set
that internally in unprivileged mode. setting up namespaces and
chroot() fails when one does not have privileges.
Signed-off-by: Vivek Goyal
---
tools/virtiofsd/pass
pci_dma_rw currently always returns 0, regardless
of the result of dma_memory_rw. Adjusted to return
the correct value.
Signed-off-by: Emanuele Giuseppe Esposito
---
include/hw/pci/pci.h | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/include/hw/pci/pci.h b/include/hw/pci/p
On 29/07/20 09:39, Markus Armbruster wrote:
> Taking a step back, I disagree with the notion that assertions should be
> avoided just because we have an Error **. A programming error doesn't
> become less wrong, and continuing when the program is in disorder
> doesn't become any safer when you add
On Jul 29 15:01, Andrzej Jakowski wrote:
> So far it was not possible to have CMB and PMR emulated on the same
> device, because BAR2 was used exclusively either of PMR or CMB. This
> patch places CMB at BAR4 offset so it not conflicts with MSI-X vectors.
>
> Signed-off-by: Andrzej Jakowski
> ---
On Thu, 16 Jul 2020 08:31:43 -0700
Thanos Makatos wrote:
> This patch introduces the VFIO-over-socket protocol specification, which
> is designed to allow devices to be emulated outside QEMU, in a separate
> process. VFIO-over-socket reuses the existing VFIO defines, structs and
> concepts.
>
>
> -Original Message-
> From: Qemu-devel On
> Behalf Of Klaus Jensen
> Sent: Thursday, July 30, 2020 3:29 AM
> To: Minwoo Im
> Cc: Kevin Wolf ; qemu-bl...@nongnu.org; Klaus Jensen
> ; qemu-devel@nongnu.org; Max Reitz ;
> Keith Busch
> Subject: Re: [PATCH 04/16] hw/block/nvme: remove redun
This likely affects other, less popular host architectures as well.
Less common host architectures under linux get QEMU_VMALLOC_ALIGN (from
which VIRTIO_MEM_MIN_BLOCK_SIZE is derived) define to a variable of
type uintptr, which isn't compatible with the format specifier used to
print a user message
On Tue, Jul 28, 2020 at 09:56:36PM -0300, Thiago Jung Bauermann wrote:
>
> Thiago Jung Bauermann writes:
>
> > The ARM code has a start-powered-off property in ARMCPU, which is a
> > subclass of CPUState. This property causes arm_cpu_reset() to set
> > CPUState::halted to 1, signalling that the
On Wed, Jul 29, 2020 at 09:57:56AM -0300, Daniel Henrique Barboza wrote:
> This patch adds a new documentation file, ppc-spapr-numa.rst,
> informing what developers and user can expect of the NUMA distance
> support for the pseries machine, up to QEMU 5.1.
>
> In the (hopefully soon) future, when
At the end of live migration, QEMU uses msync() to flush the data to
the backend storage. When the backend file is a character device dax,
the pages explicitly avoid the page cache. It will return failure from msync().
The following warning is output.
"warning: qemu_ram_msync: failed to sync m
The i440fx and q35 machines integrate i440FX or MCH PCI device by default.
Refer to i440FX and ICH9-LPC spcifications, there are some reserved
configuration registers can used to save/restore PCIHostState.config_reg.
It's nasty but friendly to old ones.
Reproducer steps:
step 1. Make modifications
> On Tue, Jul 28, 2020 at 11:27:09AM +0800, Hogan Wang wrote:
> > The i440fx and q35 machines integrate i440FX or MCH PCI device by default.
> > Refer to i440FX and ICH9-LPC spcifications, there are some reserved
> > configuration registers can used to save/restore PCIHostState.config_reg.
> > It'
Thanks for the information.
It could be fixed by this commit upstream.
a48aaf882b100b30111b5c7c75e1d9e83fe76cfd ("virtio-pci: fix wrong index in
virtio_pci_queue_enabled")
Please try.
Thanks
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribe
On Wed, Jul 29, 2020 at 12:28:46PM +0100, Sean Mooney wrote:
> On Wed, 2020-07-29 at 16:05 +0800, Yan Zhao wrote:
> > On Mon, Jul 27, 2020 at 04:23:21PM -0600, Alex Williamson wrote:
> > > On Mon, 27 Jul 2020 15:24:40 +0800
> > > Yan Zhao wrote:
> > >
> > > > > > As you indicate, the vendor drive
Hi. This is my first time trying to contribute to qemu. This patch
works correctly for architectures with the same bit-width, for example
32bit arm host and i386 user binary. Here is an example with the sg_simple2
executable from https://github.com/hreinecke/sg3_utils
32-bit ARM native:
strace
This patch implements functionalities of following ioctls:
SG_GET_VERSION_NUM - Returns SG driver version number
The sg version numbers are of the form "x.y.z" and the single number given
by the SG_GET_VERSION_NUM ioctl() is calculated by
(x * 1 + y * 100 + z).
SG_IO - Permits us
How about something like:
"A new feature, VHOST_USER_PROTOCOL_F_CONFIGURE_MEM_SLOTS, has been
added to the vhost-user protocol which, when negotiated, changes the
way QEMU transmit memory regions to backend devices. Instead of
sending all regions in a single VHOST_USER_SET_MEM_TABLE message, QEMU
w
On Wed, Jul 29, 2020 at 01:12:55PM -0600, Alex Williamson wrote:
> On Wed, 29 Jul 2020 12:28:46 +0100
> Sean Mooney wrote:
>
> > On Wed, 2020-07-29 at 16:05 +0800, Yan Zhao wrote:
> > > On Mon, Jul 27, 2020 at 04:23:21PM -0600, Alex Williamson wrote:
> > > > On Mon, 27 Jul 2020 15:24:40 +0800
>
When I compile qemu with such as:
git clone https://git.qemu.org/git/qemu.git
cd qemu
git submodule init
git submodule update --recursive
./configure
make
There is error log:
/home/LiKaige/qemu/target/arm/translate-a64.c: In function ‘disas_ldst’:
/home/LiKaige/qemu/target/arm/translate-a64.c:33
When I compile qemu with such as:
git clone https://git.qemu.org/git/qemu.git
cd qemu
git submodule init
git submodule update --recursive
./configure
make
There is error log:
/home/LiKaige/qemu/hw/virtio/virtio-mem.c: In function
‘virtio_mem_set_block_size’:
/home/LiKaige/qemu/hw/virtio/virtio-
On 29/07/2020 13.42, Viktor Mihajlovski wrote:
>
>
> On 7/28/20 8:37 PM, Thomas Huth wrote:
>> If the user did not specify a "bootindex" property, the s390-ccw bios
>> tries to find a bootable device on its own. Unfortunately, it alwasy
>> stops at the very first device that it can find, no matte
Thanos is on vacation. My comments embedded.
JJ
> On Jul 29, 2020, at 5:48 AM, Stefan Hajnoczi wrote:
>
> On Wed, Jul 22, 2020 at 11:42:26AM +, Thanos Makatos wrote:
diff --git a/docs/devel/vfio-over-socket.rst b/docs/devel/vfio-over
> At the end of live migration, QEMU uses msync() to flush the data to
> the backend storage. When the backend file is a character device dax,
> the pages explicitly avoid the page cache. It will return failure from
> msync().
> The following warning is output.
>
> "warning: qemu_ram_msync: fa
On 2020/7/29 上午12:26, Mauro Matteo Cascella wrote:
On Tue, Jul 28, 2020 at 6:06 AM Jason Wang wrote:
On 2020/7/28 上午1:08, Mauro Matteo Cascella wrote:
This patch introduces a new function in hw/net/net_tx_pkt.{c,h} to check the
current data fragment against the maximum number of data fragme
So, flag is also the paramter index right? ,what about the sync ?
At 2020-07-30 00:16:25, "Richard Henderson"
wrote:
>On 7/29/20 7:27 AM, tugouxp wrote:
>> HI folks:
>> on each tb block start, there are following ir code, and the most confusing
>> me is that the postfix of
201 - 247 of 247 matches
Mail list logo