RE: [PATCH] hw/arm/virt: Default enable the virtualization option(VHE) on A64FX

2022-01-16 Thread ishii.shuuic...@fujitsu.com
> a64fx isn't the only CPU type the virt machine type supports which has > EL2 support. In fact, all the CPU types supported by mach-virt do, unless > KVM is enabled. So, while I understand the sentiment of this patch, it > doesn't fit the current model. And, since we don't want to start > accumula

Re: [PATCH v11 4/4] softmmu/dirtylimit: implement dirty page rate limit

2022-01-16 Thread Peter Xu
On Wed, Jan 05, 2022 at 01:14:09AM +0800, huang...@chinatelecom.cn wrote: > ## > +# @set-vcpu-dirty-limit: > +# > +# Set the upper limit of dirty page rate for virtual CPU. > +# > +# Requires KVM with accelerator property "dirty-ring-size" set. > +# A virtual CPU's dirty page rate is a measure of

Re: [PATCH v11 3/4] softmmu/dirtylimit: implement virtual CPU throttle

2022-01-16 Thread Peter Xu
On Wed, Jan 05, 2022 at 01:14:08AM +0800, huang...@chinatelecom.cn wrote: > ## > +# @DirtyLimitInfo: > +# > +# Dirty page rate limit information of virtual CPU. > +# > +# @cpu-index: index of virtual CPU. > +# > +# @limit-rate: upper limit of dirty page rate for virtual CPU. > +# > +# @current-rat

[Bug 1921664] Re: Coroutines are racy for risc64 emu on arm64 - crash on Assertion

2022-01-16 Thread Tommy Thorn
No, as I described in great detail it has nothing to do with the attached devices. I just noticed that the bug was excused away as being do to the “slow” RPi 4. I’ll share that I originally hit it on Apple’s M1 but as I expect my environment might be too unusual I replicated it on RPi 4. I have s

Re: [PATCH 0/2] Improved support for AMD SEV firmware loading

2022-01-16 Thread Dov Murik
[+cc Tom, Brijesh, Ashish - see SEV-related changes in this series] On 13/01/2022 18:55, Daniel P. Berrangé wrote: > The AMD SEV build of EDK2 only emits a single file, intended to be > > mapped readonly. There is explicitly no separate writable VARS > > store for persisting non-volatile firmwa

Re: [PATCH 24/30] bsd-user/signal.c: setup_frame

2022-01-16 Thread Warner Losh
On Sun, Jan 16, 2022 at 11:58 PM Warner Losh wrote: > > +if (!lock_user_struct(VERIFY_WRITE, frame, frame_addr, 0)) { >> > +goto give_sigsegv; >> >> FreeBSD for Arm (haven't checked other BSDs or other archs) >> gives a SIGILL for the "can't write signal frame to stack" >> case, I thi

Re: [PATCH 0/2] Introduce printer subsystem and USB printer device

2022-01-16 Thread Gerd Hoffmann
Hi, > If I want to expose some Virtual Device Interfaces (VDI) on USB-IPP printer > device to remote desktop service like spice-server, is it rational to > register these interfaces to the printer subsystem which will play as a > middle layer? I'd suggest to implement the usb printer in the spi

Re: [PATCH v4 4/4] target/riscv: add support for svpbmt extension

2022-01-16 Thread Guo Ren
On Sun, Jan 16, 2022 at 11:08 AM Weiwei Li wrote: > > - add PTE_PBMT bits: It uses two PTE bits, but otherwise has no effect on > QEMU, since QEMU is sequentially consistent and doesn't model PMAs currently > - add PTE_PBMT bits check for inner PTE > - add reserved bits check for all PTE > > Sign

[PATCH] target/riscv: Ignore reserved bits in PTE for RV64

2022-01-16 Thread guoren
From: Guo Ren Highest bits of PTE has been used for svpbmt, ref: [1], [2], so we need to ignore them. They cannot be a part of ppn. 1: The RISC-V Instruction Set Manual, Volume II: Privileged Architecture 4.4 Sv39: Page-Based 39-bit Virtual-Memory System 4.5 Sv48: Page-Based 48-bit Virtual

Re: [PATCH 24/30] bsd-user/signal.c: setup_frame

2022-01-16 Thread Warner Losh
On Fri, Jan 14, 2022 at 4:40 AM Peter Maydell wrote: > On Sun, 9 Jan 2022 at 16:36, Warner Losh wrote: > > > > setup_frame sets up a signalled stack frame. Associated routines to > > extract the pointer to the stack frame and to support alternate stacks. > > > > Signed-off-by: Stacey Son > > Si

Re: unable to execute QEMU command 'qom-get': Property 'sgx-epc.unavailable-features' not found

2022-01-16 Thread Jarkko Sakkinen
On Mon, Jan 17, 2022 at 02:09:00PM +0800, Yang Zhong wrote: > On Mon, Jan 17, 2022 at 04:53:45AM +0200, Jarkko Sakkinen wrote: > > On Tue, Nov 30, 2021 at 08:15:36PM +0800, Yang Zhong wrote: > > > On Thu, Nov 25, 2021 at 08:47:22PM +0800, Yang Zhong wrote: > > > > Hello Paolo, > > > > > > > > Our

[Bug 1921664] Re: Coroutines are racy for risc64 emu on arm64 - crash on Assertion

2022-01-16 Thread Dana Goyette
I've been having crashes with the same assertion message, when trying to run Windows 10 ARM under a VM. But I finally figured out that what's actually crashing it is not the fact that it's Windows, it's the fact that I was attaching the virtual drive via virtual USB. If I do the same thing to an

Re: [PATCH 1/2] hw/virtio: add boilerplate for vhost-user-gpio device

2022-01-16 Thread Viresh Kumar
On 14-01-22, 14:06, Alex Bennée wrote: > > Viresh Kumar writes: > > > This creates the QEMU side of the vhost-user-gpio device which connects > > to the remote daemon. It is based of vhost-user-i2c code. > > > > Signed-off-by: Viresh Kumar > > > +++ b/include/hw/virtio/vhost-user-gpio.h > > @@

Re: unable to execute QEMU command 'qom-get': Property 'sgx-epc.unavailable-features' not found

2022-01-16 Thread Jarkko Sakkinen
On Mon, Jan 17, 2022 at 04:53:48AM +0200, Jarkko Sakkinen wrote: > On Tue, Nov 30, 2021 at 08:15:36PM +0800, Yang Zhong wrote: > > On Thu, Nov 25, 2021 at 08:47:22PM +0800, Yang Zhong wrote: > > > Hello Paolo, > > > > > > Our customer used the Libvirt XML to start a SGX VM, but failed. > > > > >

Re: unable to execute QEMU command 'qom-get': Property 'sgx-epc.unavailable-features' not found

2022-01-16 Thread Yang Zhong
On Mon, Jan 17, 2022 at 04:53:45AM +0200, Jarkko Sakkinen wrote: > On Tue, Nov 30, 2021 at 08:15:36PM +0800, Yang Zhong wrote: > > On Thu, Nov 25, 2021 at 08:47:22PM +0800, Yang Zhong wrote: > > > Hello Paolo, > > > > > > Our customer used the Libvirt XML to start a SGX VM, but failed. > > > > >

Re: [PATCH 3/3] intel-iommu: PASID support

2022-01-16 Thread Jason Wang
On Fri, Jan 14, 2022 at 8:59 PM Liu Yi L wrote: > > On 2022/1/14 15:22, Jason Wang wrote: > > On Fri, Jan 14, 2022 at 3:13 PM Peter Xu wrote: > >> > >> On Fri, Jan 14, 2022 at 01:58:07PM +0800, Jason Wang wrote: > > Right, but I think you meant to do this only when scalable mode is > > d

Re: ppc pbr403 vmstate

2022-01-16 Thread David Gibson
On Fri, Jan 14, 2022 at 08:07:21AM +0100, Cédric le Goater wrote: > On 1/14/22 00:41, David Gibson wrote: > > On Thu, Jan 13, 2022 at 06:51:56PM +, Dr. David Alan Gilbert wrote: > > > Hi, > > >Is there any easy way of getting a machine where the pbr403 vmstate > > > would be generated? > >

Re: [PATCH v1] libvhost-user: Map shared RAM with MAP_NORESERVE to support virtio-mem with hugetlb

2022-01-16 Thread Raphael Norwitz
On Tue, Jan 11, 2022 at 01:39:39PM +0100, David Hildenbrand wrote: > For fd-based shared memory, MAP_NORESERVE is only effective for hugetlb, > otherwise it's ignored. Older Linux versions that didn't support > reservation of huge pages ignored MAP_NORESERVE completely. > > The first client to mma

[PATCH v3 1/6] libvhost-user: Add vu_rem_mem_reg input validation

2022-01-16 Thread Raphael Norwitz
Today if multiple FDs are sent from the VMM to the backend in a VHOST_USER_REM_MEM_REG message, one FD will be unmapped and the remaining FDs will be leaked. Therefore if multiple FDs are sent we report an error and fail the operation, closing all FDs in the message. Likewise in case the VMM sends

[PATCH v3 6/6] libvhost-user: handle removal of identical regions

2022-01-16 Thread Raphael Norwitz
Today if QEMU (or any other VMM) has sent multiple copies of the same region to a libvhost-user based backend and then attempts to remove the region, only one instance of the region will be removed, leaving stale copies of the region in dev->regions[]. This change resolves this by having vu_rem_me

[PATCH v3 4/6] libvhost-user: fix VHOST_USER_REM_MEM_REG not closing the fd

2022-01-16 Thread Raphael Norwitz
From: David Hildenbrand We end up not closing the file descriptor, resulting in leaking one file descriptor for each VHOST_USER_REM_MEM_REG message. Fixes: 875b9fd97b34 ("Support individual region unmap in libvhost-user") Cc: Michael S. Tsirkin Cc: Raphael Norwitz Cc: "Marc-André Lureau" Cc:

Re: [PATCH 06/30] bsd-user/arm/target_arch_cpu.h: Correct code pointer

2022-01-16 Thread Warner Losh
On Fri, Jan 14, 2022 at 3:22 AM Peter Maydell wrote: > On Fri, 14 Jan 2022 at 06:38, Warner Losh wrote: > > > > > > > > On Thu, Jan 13, 2022 at 10:15 AM Peter Maydell > wrote: > >> > >> On Sun, 9 Jan 2022 at 16:26, Warner Losh wrote: > >> > > >> > The code has moved in FreeBSD since the emulat

[PATCH v3 2/6] libvhost-user: Add vu_add_mem_reg input validation

2022-01-16 Thread Raphael Norwitz
Today if multiple FDs are sent from the VMM to the backend in a VHOST_USER_ADD_MEM_REG message, one FD will be mapped and the remaining FDs will be leaked. Therefore if multiple FDs are sent we report an error and fail the operation, closing all FDs in the message. Likewise in case the VMM sends a

[PATCH v3 0/6] Clean up error handling in libvhost-user memory mapping

2022-01-16 Thread Raphael Norwitz
Hey Stefan, Marc-Andre, MST, David - As promised here is a series cleaning up error handling in the libvhost-user memory mapping path. Most of these cleanups are straightforward and have been discussed on the mailing list in threads [1] and [2]. [1] https://lore.kernel.org/qemu-devel/20211018143

[PATCH v3 5/6] libvhost-user: prevent over-running max RAM slots

2022-01-16 Thread Raphael Norwitz
When VHOST_USER_PROTOCOL_F_CONFIGURE_MEM_SLOTS support was added to libvhost-user, no guardrails were added to protect against QEMU attempting to hot-add too many RAM slots to a VM with a libvhost-user based backed attached. This change adds the missing error handling by introducing a check on the

[PATCH v3 3/6] libvhost-user: Simplify VHOST_USER_REM_MEM_REG

2022-01-16 Thread Raphael Norwitz
From: David Hildenbrand Let's avoid having to manually copy all elements. Copy only the ones necessary to close the hole and perform the operation in-place without a second array. Reviewed-by: Stefan Hajnoczi Signed-off-by: David Hildenbrand Signed-off-by: Raphael Norwitz --- subprojects/lib

Re: [PATCH] softmmu: Provide a clue as to why device tree loading failed

2022-01-16 Thread David Gibson
On Sun, Jan 16, 2022 at 12:46:49PM +0100, Bernhard Beschow wrote: > fdt_open_into() obligingly returns an error code in case the operation > failed. So be obliging as well and use it in the error message. > > Signed-off-by: Bernhard Beschow Reviewed-by: David Gibson > --- > softmmu/device_tre

Re: [PATCH 11/30] bsd-user/host/arm/host-signal.h: Implement host_signal_*

2022-01-16 Thread Warner Losh
On Thu, Jan 13, 2022 at 12:32 PM Peter Maydell wrote: > On Sun, 9 Jan 2022 at 16:33, Warner Losh wrote: > > > > Implement host_signal_pc, host_signal_set_pc and host_signal_write for > > arm. > > > > Signed-off-by: Kyle Evans > > Signed-off-by: Warner Losh > > > +static inline bool host_signal

Re: unable to execute QEMU command 'qom-get': Property 'sgx-epc.unavailable-features' not found

2022-01-16 Thread Jarkko Sakkinen
On Tue, Nov 30, 2021 at 08:15:36PM +0800, Yang Zhong wrote: > On Thu, Nov 25, 2021 at 08:47:22PM +0800, Yang Zhong wrote: > > Hello Paolo, > > > > Our customer used the Libvirt XML to start a SGX VM, but failed. > > > > libvirt.libvirtError: internal error: unable to execute QEMU command > > 'qo

Re: [PATCH v11 2/4] softmmu/dirtylimit: implement vCPU dirtyrate calculation periodically

2022-01-16 Thread Peter Xu
On Wed, Jan 05, 2022 at 01:14:07AM +0800, huang...@chinatelecom.cn wrote: > From: Hyman Huang(黄勇) > > Introduce the third method GLOBAL_DIRTY_LIMIT of dirty > tracking for calculate dirtyrate periodly for dirty page > rate limit. > > Add dirtylimit.c to implement dirtyrate calculation periodly,

Re: [PATCH v11 1/4] migration/dirtyrate: refactor dirty page rate calculation

2022-01-16 Thread Peter Xu
On Wed, Jan 05, 2022 at 01:14:06AM +0800, huang...@chinatelecom.cn wrote: > From: Hyman Huang(黄勇) > > abstract out dirty log change logic into function > global_dirty_log_change. > > abstract out dirty page rate calculation logic via > dirty-ring into function vcpu_calculate_dirtyrate. > > abst

Re: [PATCH 27/30] bsd-user/signal.c: process_pending_signals

2022-01-16 Thread Warner Losh
On Fri, Jan 14, 2022 at 4:55 AM Peter Maydell wrote: > On Sun, 9 Jan 2022 at 16:57, Warner Losh wrote: > > > > Process the currently queued signals. > > > > Signed-off-by: Stacey Son > > Signed-off-by: Kyle Evans > > Signed-off-by: Warner Losh > > --- > > bsd-user/signal.c | 34 +

Re: [RFC PATCH v4 00/30] Add LoongArch softmmu support.

2022-01-16 Thread yangxiaojuan
Hi, Mark On 01/15/2022 10:11 PM, Mark Cave-Ayland wrote: > On 08/01/2022 09:13, Xiaojuan Yang wrote: > >> This series patch add softmmu support for LoongArch. >> Base on the linux-user emulation support V14 patch. >>* https://patchew.org/QEMU/20220106094200.1801206-1-gaos...@loongson.cn/ >> T

Re: [PATCH 2/3] intel-iommu: drop VTDBus

2022-01-16 Thread Peter Xu
On Mon, Jan 17, 2022 at 09:27:03AM +0800, Peter Xu wrote: > On Fri, Jan 14, 2022 at 05:15:35PM +0800, Jason Wang wrote: > > > > 在 2022/1/14 上午10:32, Jason Wang 写道: > > > > > dressSpace *as) > > > > >   /* GHashTable functions */ > > > > >   static gboolean vtd_uint64_equal(gconstpointer v1, gconst

Re: [PATCH 2/3] intel-iommu: drop VTDBus

2022-01-16 Thread Peter Xu
On Fri, Jan 14, 2022 at 05:15:35PM +0800, Jason Wang wrote: > > 在 2022/1/14 上午10:32, Jason Wang 写道: > > > > dressSpace *as) > > > >   /* GHashTable functions */ > > > >   static gboolean vtd_uint64_equal(gconstpointer v1, gconstpointer v2) > > > >   { > > > > -    return *((const uint64_t *)v1) ==

[RFC PATCH 2/2] hw/i386/sgx: Attach SGX-EPC to its memory backend

2022-01-16 Thread Philippe Mathieu-Daudé via
We have one SGX-EPC address/size/node per memory backend, make it child of the backend in the QOM composition tree. Cc: Yang Zhong Signed-off-by: Philippe Mathieu-Daudé --- hw/i386/sgx.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/i386/sgx.c b/hw/i386/sgx.c index 5de5dd08936..6362

[PATCH 1/2] hw/i386/x86: Attach CPUs to machine

2022-01-16 Thread Philippe Mathieu-Daudé via
Avoid having CPUs objects dangling as unattached QOM ones, directly attach them to the machine. Signed-off-by: Philippe Mathieu-Daudé --- hw/i386/x86.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/i386/x86.c b/hw/i386/x86.c index b84840a1bb9..50bf249c700 100644 --- a/hw/i386/x86.c +++

[PATCH 0/2] hw/i386: QOM-attach CPUs/SGX-EPC objects to their parents

2022-01-16 Thread Philippe Mathieu-Daudé via
Trying to fix the issue reported here: https://lists.nongnu.org/archive/html/qemu-devel/2021-11/msg05670.html First attach the CPUs to the machine, then the SGX-EPC to its memory backend. Philippe Mathieu-Daudé (2): hw/i386/x86: Attach CPUs to machine hw/i386/sgx: Attach SGX-EPC to its memory

Re: [PATCH v1 19/34] tests/tcg: use CONFIG_LINUX_USER, not CONFIG_LINUX

2022-01-16 Thread Warner Losh
On Mon, Jan 10, 2022 at 2:58 AM Philippe Mathieu-Daudé wrote: > +Warner > > On 1/5/22 14:49, Alex Bennée wrote: > > From: Paolo Bonzini > > > > The two more or less overlap, because CONFIG_LINUX is a requirement for > Linux > > user-mode emulation. However, CONFIG_LINUX is technically a host sy

Re: [PATCH v2 0/3] Support fd-based KVM stats

2022-01-16 Thread Mark Kanda
(+ Daniel and Markus) Thank you Paolo, I'm in the midst of implementing various API changes as requested by Daniel [1] and was planning to send out v3 this week. Could you please take a look at his response and comment on the proposal? Or, perhaps I should publish v3 (based on Daniel's propos

Re: [PATCH 1/2] linx-user: Remove MAX_SIGQUEUE_SIZE

2022-01-16 Thread Peter Maydell
On Sun, 16 Jan 2022 at 20:44, Warner Losh wrote: > > It's been unused for 7 years since 907f5fddaa67 when linux-user stopped > queueing any signals. > > Signed-off-by: Warner Losh > --- Typo in subject (should be 'linux-user'); otherwise Reviewed-by: Peter Maydell thanks -- PMM

Re: [PATCH 2/2] linxu-user: Change return type of queue_signal to void

2022-01-16 Thread Peter Maydell
On Sun, 16 Jan 2022 at 20:44, Warner Losh wrote: > > queue_signal always returns 1, and nobody checks it. This is better > expressed as a void function return type. > > Signed-off-by: Warner Losh > --- > linux-user/signal-common.h | 4 ++-- > linux-user/signal.c| 5 ++--- > 2 files chang

Re: [PATCH 1/2] linx-user: Remove MAX_SIGQUEUE_SIZE

2022-01-16 Thread Philippe Mathieu-Daudé via
On 16/1/22 21:44, Warner Losh wrote: It's been unused for 7 years since 907f5fddaa67 when linux-user stopped queueing any signals. Signed-off-by: Warner Losh --- linux-user/qemu.h | 2 -- 1 file changed, 2 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH 4/5] usb/ohci: Merge ohci_async_cancel_device() into ohci_child_detach()

2022-01-16 Thread Philippe Mathieu-Daudé via
On 16/1/22 14:20, BALATON Zoltan wrote: These two do the same and only used once so no need to have two functions, simplify by merging them. Signed-off-by: BALATON Zoltan --- hw/usb/hcd-ohci.c | 13 - 1 file changed, 4 insertions(+), 9 deletions(-) Reviewed-by: Philippe Mathieu

Re: [PATCH 3/5] usb/ohci: Move USBPortOps related functions together

2022-01-16 Thread Philippe Mathieu-Daudé via
On 16/1/22 14:20, BALATON Zoltan wrote: This also allows removing two forward declarations Signed-off-by: BALATON Zoltan --- hw/usb/hcd-ohci.c | 204 +++--- 1 file changed, 100 insertions(+), 104 deletions(-) +static const MemoryRegionOps ohci_mem_o

Re: [PATCH] intc: Unexport InterruptStatsProviderClass-related functions

2022-01-16 Thread Philippe Mathieu-Daudé via
On 16/1/22 13:23, Bernhard Beschow wrote: The functions are only used within their respective source files, so no need for exporting. Signed-off-by: Bernhard Beschow --- hw/intc/i8259_common.c| 6 +++--- hw/intc/ioapic_common.c | 2 +- include/hw/i386/ioapic_internal.h

Re: [PATCH] softmmu: Provide a clue as to why device tree loading failed

2022-01-16 Thread Philippe Mathieu-Daudé via
On 16/1/22 12:46, Bernhard Beschow wrote: fdt_open_into() obligingly returns an error code in case the operation failed. So be obliging as well and use it in the error message. Signed-off-by: Bernhard Beschow --- softmmu/device_tree.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(

Re: [PATCH 2/2] hw/i386: support loading OVMF using -bios too

2022-01-16 Thread Philippe Mathieu-Daudé via
On 14/1/22 19:07, Michael S. Tsirkin wrote: On Thu, Jan 13, 2022 at 04:55:11PM +, Daniel P. Berrangé wrote: Traditionally the OVMF firmware has been loaded using the pflash mechanism. This is because it is usually provided as a pair of files, one read-only containing the code and one writabl

Re: [PATCH 18/30] bsd-user/signal.c: Implement host_signal_handler

2022-01-16 Thread Warner Losh
On Thu, Jan 13, 2022 at 1:17 PM Peter Maydell wrote: > On Sun, 9 Jan 2022 at 16:40, Warner Losh wrote: > > > > Implement host_signal_handler to handle signals generated by the host > > and to do safe system calls. > > > > Signed-off-by: Stacey Son > > Signed-off-by: Kyle Evans > > Signed-off-b

[PATCH 0/2] linux-user: Two minor patches

2022-01-16 Thread Warner Losh
There's two, almost trivial patches that arose out of the review of bsd-user. There's a chance that one or both of these were submitted already... Warner Losh (2): linx-user: Remove MAX_SIGQUEUE_SIZE linxu-user: Change return type of queue_signal to void linux-user/qemu.h | 2 -- li

[PATCH 2/2] linxu-user: Change return type of queue_signal to void

2022-01-16 Thread Warner Losh
queue_signal always returns 1, and nobody checks it. This is better expressed as a void function return type. Signed-off-by: Warner Losh --- linux-user/signal-common.h | 4 ++-- linux-user/signal.c| 5 ++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/linux-user/signal

[PATCH 1/2] linx-user: Remove MAX_SIGQUEUE_SIZE

2022-01-16 Thread Warner Losh
It's been unused for 7 years since 907f5fddaa67 when linux-user stopped queueing any signals. Signed-off-by: Warner Losh --- linux-user/qemu.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/linux-user/qemu.h b/linux-user/qemu.h index 5c713fa8ab2..7910ce59cc8 100644 --- a/linux-user/qemu.h

Re: [PULL 0/9] qemu-ga-win patches

2022-01-16 Thread Peter Maydell
On Sat, 15 Jan 2022 at 22:13, Konstantin Kostiuk wrote: > Hi. I uploaded my GPG key to keys.openpgp.org. You can find it by my RedHat > email. > Unfortunately, for now, this key can not be signed by other RedHat developers. > I signed my tag and pushed it to GitHub. Should I resend this set of pa

Re: [PATCH qemu] spapr: Force 32bit when resetting a core

2022-01-16 Thread Peter Maydell
On Fri, 7 Jan 2022 at 07:29, Alexey Kardashevskiy wrote: > > "PowerPC Processor binding to IEEE 1275" says in > "8.2.1. Initial Register Values" that the initial state is defined as > 32bit so do it for both SLOF and VOF. > > This should not cause behavioral change as SLOF switches to 64bit very >

[PATCH 4/5] usb/ohci: Merge ohci_async_cancel_device() into ohci_child_detach()

2022-01-16 Thread BALATON Zoltan
These two do the same and only used once so no need to have two functions, simplify by merging them. Signed-off-by: BALATON Zoltan --- hw/usb/hcd-ohci.c | 13 - 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/hw/usb/hcd-ohci.c b/hw/usb/hcd-ohci.c index d1907afd3f..e87f5

[PATCH 5/5] usb/ohci: Don't use packet from OHCIState for isochronous transfers

2022-01-16 Thread BALATON Zoltan
Since isochronous transfers cannot be handled async (the function returns error in that case) we don't need to remember the packet. Avoid using the usb_packet field in OHCIState (as that can be a waiting async packet on another endpoint) and allocate and use a local USBPacket for the iso transfer i

[PATCH 3/5] usb/ohci: Move USBPortOps related functions together

2022-01-16 Thread BALATON Zoltan
This also allows removing two forward declarations Signed-off-by: BALATON Zoltan --- hw/usb/hcd-ohci.c | 204 +++--- 1 file changed, 100 insertions(+), 104 deletions(-) diff --git a/hw/usb/hcd-ohci.c b/hw/usb/hcd-ohci.c index 6d762973eb..d1907afd3f 100644

[PATCH 2/5] usb/ohci: Move cancelling async packet to ohci_stop_endpoints()

2022-01-16 Thread BALATON Zoltan
This is always done before calling this function so remove duplicated code and do it within the function at one place. Signed-off-by: BALATON Zoltan --- hw/usb/hcd-ohci.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/hw/usb/hcd-ohci.c b/hw/usb/hcd-ohci.c index

[PATCH 1/5] usb/ohci: Move trace point and log ep number to help debugging

2022-01-16 Thread BALATON Zoltan
Signed-off-by: BALATON Zoltan --- hw/usb/hcd-ohci.c | 14 +++--- hw/usb/trace-events | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/hw/usb/hcd-ohci.c b/hw/usb/hcd-ohci.c index a93d6b2e98..f915cc5473 100644 --- a/hw/usb/hcd-ohci.c +++ b/hw/usb/hcd-ohci.c @@ -1033

[PATCH 0/5] Misc OHCI clean ups

2022-01-16 Thread BALATON Zoltan
Hello, I have these patches from last October when we've looked at what causes problems with mac99 and USB. We've found the main problem is likely not allowing pending packets per endpoint which we did not fix but these patches came out of debugging that and trying to improve the device model so e

Re: [PATCH] intc: Unexport InterruptStatsProviderClass-related functions

2022-01-16 Thread Michael S. Tsirkin
On Sun, Jan 16, 2022 at 01:23:26PM +0100, Bernhard Beschow wrote: > The functions are only used within their respective source files, so no > need for exporting. > > Signed-off-by: Bernhard Beschow Acked-by: Michael S. Tsirkin > --- > hw/intc/i8259_common.c| 6 +++--- > hw/intc/ioa

[PATCH] intc: Unexport InterruptStatsProviderClass-related functions

2022-01-16 Thread Bernhard Beschow
The functions are only used within their respective source files, so no need for exporting. Signed-off-by: Bernhard Beschow --- hw/intc/i8259_common.c| 6 +++--- hw/intc/ioapic_common.c | 2 +- include/hw/i386/ioapic_internal.h | 1 - include/hw/isa/i8259_internal.h | 3 -

[PATCH] softmmu: Provide a clue as to why device tree loading failed

2022-01-16 Thread Bernhard Beschow
fdt_open_into() obligingly returns an error code in case the operation failed. So be obliging as well and use it in the error message. Signed-off-by: Bernhard Beschow --- softmmu/device_tree.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/softmmu/device_tree.c b/softm