Re: [PATCH v17 04/11] hw/misc/pvpanic: Add MMIO interface

2025-03-03 Thread Phil Dennis-Jordan
On Mon, 3 Mar 2025 at 18:54, Philippe Mathieu-Daudé wrote: > On 12/1/25 22:00, Phil Dennis-Jordan wrote: > > From: Alexander Graf > > > > In addition to the ISA and PCI variants of pvpanic, let's add an MMIO > > platform device that we can use in embedded arm env

Re: [PATCH v17 11/11] hw/vmapple/vmapple: Add vmapple machine type

2025-03-03 Thread Phil Dennis-Jordan
On Mon, 3 Mar 2025 at 19:20, Philippe Mathieu-Daudé wrote: > On 12/1/25 22:00, Phil Dennis-Jordan wrote: > > From: Alexander Graf > > > > Apple defines a new "vmapple" machine type as part of its proprietary > > macOS Virtualization.Framework vmm. This ma

Re: [PATCH] meson: Display summary of Darwin libraries detected

2025-02-19 Thread Phil Dennis-Jordan
On Wed, 19 Feb 2025 at 11:28, Paolo Bonzini wrote: > On Tue, Feb 18, 2025 at 3:55 PM Phil Dennis-Jordan > wrote: > > It is not cross-architecture. So, the PVG guest drivers with x86-64 > macOS don't > > give useful results with the aarch64 macOS host PVG framework. (

Re: [PATCH] meson: Display summary of Darwin libraries detected

2025-02-18 Thread Phil Dennis-Jordan
On Mon, 17 Feb 2025 at 19:37, Paolo Bonzini wrote: > On 2/12/25 12:29, Philippe Mathieu-Daudé wrote: > > Signed-off-by: Philippe Mathieu-Daudé > > --- > > meson.build | 7 +++ > > 1 file changed, 7 insertions(+) > > > > diff --git a/meson.build b/meson.build > > index 18cf9e2913b..10f4c9f

Re: [PATCH 01/11] hvf: Add facility for initialisation code prior to first vCPU run

2025-02-09 Thread Phil Dennis-Jordan
On Wed, 5 Feb 2025 at 22:02, Philippe Mathieu-Daudé wrote: > +Igor > > On 9/12/24 21:36, p...@philjordan.eu wrote: > > From: Phil Dennis-Jordan > > > > Some VM state required for fully configuring vCPUs is only available > > after all devices have been thr

Re: [RFC PATCH 6/7] tests/qtest/migration: Run aarch64/HVF tests using GICv2

2025-02-09 Thread Phil Dennis-Jordan
On Tue, 28 Jan 2025 at 14:55, Philippe Mathieu-Daudé wrote: > GICv3 isn't supported on aarch64/HVF, but GICv2 is. Hmm. I'm still trying to get my head around this patch series and QTest in general, but in my experience GICv3 works fine with HVF? (Device name "arm-gicv3") Can you clarify what yo

Re: [PATCH v4 4/9] meson: Disallow 64-bit on 32-bit HVF/NVMM/WHPX emulation

2025-02-09 Thread Phil Dennis-Jordan
86_64: > > http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/dev/nvmm/Makefile?rev=1.1.6.2;content-type=text%2Fplain > > For WHPX, we have already dropped support for 32-bit Windows. > > Signed-off-by: Richard Henderson > Reviewed-by: Phil Dennis-Jordan > --- > meson.build

Re: [PATCH 2/2] hw/pci: Assert a bar is not registered multiple times

2025-01-19 Thread Phil Dennis-Jordan
. Add an assertion to prevent misuse. > > Signed-off-by: Nicholas Piggin > Reviewed-by: Phil Dennis-Jordan > --- > hw/pci/pci.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/hw/pci/pci.c b/hw/pci/pci.c > index 2afa423925c..b067a55c5bc 100644 > --- a/hw/

Re: [PATCH 1/2] hw/pci/msix: Warn on PBA writes

2025-01-19 Thread Phil Dennis-Jordan
UEST_ERROR message if the PBA is written to by software. > > Cc: Michael S. Tsirkin > Cc: Marcel Apfelbaum > Cc: Dmitry Fleytman > Cc: Akihiko Odaki > Cc: Sriram Yagnaraman > Signed-off-by: Nicholas Piggin > Reviewed-by: Phil Dennis-Jordan > --- > hw/pci/m

Re: [PULL 0/8] Xen regression fixes and cleanups

2025-01-17 Thread Phil Dennis-Jordan
On Thu, 16 Jan 2025 at 23:10, Stefan Hajnoczi wrote: > Applied, thanks. > > Please update the changelog at https://wiki.qemu.org/ChangeLog/10.0 for > any user-visible changes. > This note made me realise that my feature addition (macOS PV graphics device) that caused the regression requiring my

Re: [PATCH v4 1/3] coreaudio: Commit the result of init in the end

2025-01-17 Thread Phil Dennis-Jordan
On Fri, 17 Jan 2025 at 07:48, Akihiko Odaki wrote: > init_out_device may only commit some part of the result and leave the > state inconsistent when it encounters a fatal error or the device gets > unplugged during the operation, which is expressed by > kAudioHardwareBadObjectError or kAudioHardw

Re: [PATCH v4 3/3] coreaudio: Initialize the buffer for device change

2025-01-17 Thread Phil Dennis-Jordan
On Fri, 17 Jan 2025 at 07:48, Akihiko Odaki wrote: > Reallocate buffers when the active device change as the required buffer > size may differ. Signed-off-by: Akihiko Odaki > Reviewed-by: Phil Dennis-Jordan --- > audio/coreaudio.m | 1 + > 1 file changed, 1 insertion(+) &

Re: [PATCH v4 2/3] audio: Add functions to initialize buffers

2025-01-17 Thread Phil Dennis-Jordan
On Fri, 17 Jan 2025 at 07:48, Akihiko Odaki wrote: > These functions can be used to re-initialize buffers when hardware > parameters change due to device hotplug, for example. > > Signed-off-by: Akihiko Odaki > Reviewed-by: Phil Dennis-Jordan > --- > audio/audio_i

Re: [PATCH] system/runstate: Fix regression, clarify BQL status of exit notifiers

2025-01-15 Thread Phil Dennis-Jordan
On Wed 15. Jan 2025 at 20:05, Paolo Bonzini wrote: > On 1/12/25 22:26, Phil Dennis-Jordan wrote: > > By changing the way the main QEMU event loop is invoked, I inadvertently > > changed the BQL status of exit notifiers: some of them implicitly > > assumed they would be cal

Re: [PATCH v17 00/11] New vmapple machine type and xhci fixes

2025-01-15 Thread Phil Dennis-Jordan
On Wed, 15 Jan 2025 at 16:08, Michael S. Tsirkin wrote: > On Sun, Jan 12, 2025 at 10:00:45PM +0100, Phil Dennis-Jordan wrote: > > This patch set introduces a new ARM and macOS HVF specific machine type > > called "vmapple". There are also some patches for fixing XHCI s

Re: [PATCH v17 00/11] New vmapple machine type and xhci fixes

2025-01-15 Thread Phil Dennis-Jordan
On Wed, 15 Jan 2025 at 14:05, Michael Tokarev wrote: > 13.01.2025 00:00, Phil Dennis-Jordan wrote: > > This patch set introduces a new ARM and macOS HVF specific machine type > > called "vmapple". There are also some patches for fixing XHCI spec > > compliance issu

Re: [PATCH v17 00/11] New vmapple machine type and xhci fixes

2025-01-14 Thread Phil Dennis-Jordan
On Mon, 13 Jan 2025 at 18:31, Philippe Mathieu-Daudé wrote: > On 12/1/25 22:00, Phil Dennis-Jordan wrote: > > This patch set introduces a new ARM and macOS HVF specific machine type > > called "vmapple". There are also some patches for fixing XHCI spec > >

[PATCH] system/runstate: Fix regression, clarify BQL status of exit notifiers

2025-01-12 Thread Phil Dennis-Jordan
. Fixes: f5ab12caba4f ("ui & main loop: Redesign of system-specific main thread event handling") Resolves: https://gitlab.com/qemu-project/qemu/-/issues/2771 Reported-by: David Woodhouse Signed-off-by: Phil Dennis-Jordan --- include/system/system.h | 1 + system/runstate.c

[PATCH v17 08/11] hw/vmapple/virtio-blk: Add support for apple virtio-blk

2025-01-12 Thread Phil Dennis-Jordan
7;variant' property. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki v4: * Use recommended object type declaration pattern. * Correctly log unimplemented code paths. * Most header code moved to .c, type name #defin

[PATCH v17 09/11] hw/usb/hcd-xhci-pci: Adds property for disabling mapping in IRQ mode

2025-01-12 Thread Phil Dennis-Jordan
s. Signed-off-by: Phil Dennis-Jordan Resolves: https://gitlab.com/qemu-project/qemu/-/issues/2705 --- hw/usb/hcd-xhci-pci.c | 24 hw/usb/hcd-xhci-pci.h | 1 + hw/usb/hcd-xhci.c | 3 ++- hw/usb/hcd-xhci.h | 5 + 4 files changed, 32 insertions(+), 1 deletio

[PATCH v17 10/11] hw/intc: Remove TCG dependency on ARM_GICV3

2025-01-12 Thread Phil Dennis-Jordan
ippe Mathieu-Daudé Reviewed-by: Phil Dennis-Jordan --- hw/intc/Kconfig | 6 +++--- hw/intc/meson.build | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/intc/Kconfig b/hw/intc/Kconfig index dd405bdb5d..7547528f2c 100644 --- a/hw/intc/Kconfig +++ b/hw/intc/Kconfi

[PATCH v17 11/11] hw/vmapple/vmapple: Add vmapple machine type

2025-01-12 Thread Phil Dennis-Jordan
all these in place, you should be able to see macOS booting successfully. Known issues: - Currently only macOS 12 guests are supported. The boot process for 13+ will need further investigation and adjustment. Signed-off-by: Alexander Graf Co-authored-by: Phil Dennis-Jordan Signed-off-by: P

[PATCH v17 07/11] hw/vmapple/cfg: Introduce vmapple cfg region

2025-01-12 Thread Phil Dennis-Jordan
device which we can then map at the fixed location in the address space. That way, we can influence and annotate all configuration fields easily. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v3: * Replaced legacy device

[PATCH v17 04/11] hw/misc/pvpanic: Add MMIO interface

2025-01-12 Thread Phil Dennis-Jordan
From: Alexander Graf In addition to the ISA and PCI variants of pvpanic, let's add an MMIO platform device that we can use in embedded arm environments. Signed-off-by: Alexander Graf Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé Signed-off-by: Phil Dennis-J

[PATCH v17 02/11] hw/usb/hcd-xhci-pci: Use event ring 0 if mapping unsupported

2025-01-12 Thread Phil Dennis-Jordan
nts targeted at Interrupter 0." QEMU's XHCI device has so far not specially addressed this case, so we add a check to xhci_event() to redirect to event ring and interrupt 0 if mapping is disabled. Signed-off-by: Phil Dennis-Jordan Reviewed-by: Philippe Mathieu-Daudé --- hw/usb/hc

[PATCH v17 05/11] hw/vmapple/aes: Introduce aes engine

2025-01-12 Thread Phil Dennis-Jordan
From: Alexander Graf VMApple contains an "aes" engine device that it uses to encrypt and decrypt its nvram. It has trivial hard coded keys it uses for that purpose. Add device emulation for this device model. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan R

[PATCH v17 01/11] hw/usb/hcd-xhci-pci: Use modulo to select MSI vector as per spec

2025-01-12 Thread Phil Dennis-Jordan
ange introduces that modulo calculation, fixing the failed assertion. This makes the device work correctly in MSI mode with macOS's XHCI driver, which only allocates a single vector. Signed-off-by: Phil Dennis-Jordan Reviewed-by: Philippe Mathieu-Daudé --- v2: * Switch to modulo arithme

[PATCH v17 03/11] hw: Add vmapple subdir

2025-01-12 Thread Phil Dennis-Jordan
From: Alexander Graf We will introduce a number of devices that are specific to the vmapple target machine. To keep them all tidily together, let's put them into a single target directory. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Test

[PATCH v17 06/11] hw/vmapple/bdif: Introduce vmapple backdoor interface

2025-01-12 Thread Phil Dennis-Jordan
; they're only needed for guest recovery and I don't understand the protocol yet. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v4: * Moved most header code to .c, rest to vmapple.h * Better compliance with codi

[PATCH v17 00/11] New vmapple machine type and xhci fixes

2025-01-12 Thread Phil Dennis-Jordan
and removing its TCG dependency. (It's needed with HVF too.) * vmapple machine type: Dropped Tested-by tag because of above changes Alexander Graf (7): hw: Add vmapple subdir hw/misc/pvpanic: Add MMIO interface hw/vmapple/aes: Introduce aes engine hw/vmapple/bdif: Introduce vmapple ba

Re: [PATCH] system: Try hardware accelerators (KVM, HVF) before software one (TCG)

2025-01-08 Thread Phil Dennis-Jordan
On Mon, 6 Jan 2025 at 19:43, Daniel P. Berrangé wrote: > On Sat, Jan 04, 2025 at 12:28:14PM +0100, Phil Dennis-Jordan wrote: > > On Fri, 3 Jan 2025 at 16:16, Daniel P. Berrangé > wrote: > > > > > On Fri, Jan 03, 2025 at 04:05:58PM +0100, Philippe Mathieu-Daudé wrote:

Re: [PATCH 2/2] hw/intc: Have ARM_GIC select ARM_GICV3 when KVM is not available

2025-01-07 Thread Phil Dennis-Jordan
On Sat, 28 Dec 2024 at 11:48, Phil Dennis-Jordan wrote: > > > On Fri, 27 Dec 2024 at 21:24, Philippe Mathieu-Daudé > wrote: > >> When the KVM accelerator is selected, the Kconfig ARM_GIC key >> selects the KVM GIC implementation (ARM_GIC_KVM). >> For other acc

Re: [PATCH v16 14/14] hw/vmapple/vmapple: Add vmapple machine type

2025-01-04 Thread Phil Dennis-Jordan
On Sat, 4 Jan 2025 at 16:15, Akihiko Odaki wrote: > On 2024/12/28 5:36, Philippe Mathieu-Daudé wrote: > > On 23/12/24 23:16, Phil Dennis-Jordan wrote: > > > >> Known issues: > >> - Keyboard and mouse/tablet input is laggy. The reason for this is > >

Re: [PATCH] system: Try hardware accelerators (KVM, HVF) before software one (TCG)

2025-01-04 Thread Phil Dennis-Jordan
On Fri, 3 Jan 2025 at 16:16, Daniel P. Berrangé wrote: > On Fri, Jan 03, 2025 at 04:05:58PM +0100, Philippe Mathieu-Daudé wrote: > > As Daniel suggested [*]: > > > > > We should consider to rank HVF above TCG, on the basis > > > that HW acceleration is faster and should provide a > > > host<->gue

Re: [PATCH v16 00/14] macOS PV Graphics and new vmapple machine type

2024-12-30 Thread Phil Dennis-Jordan
On Mon, 30 Dec 2024 at 19:55, Philippe Mathieu-Daudé wrote: > Cc'ing Joelle (FYI https://github.com/utmapp/UTM/issues/3491) > > On 23/12/24 23:16, Phil Dennis-Jordan wrote: > > This patch set introduces a new ARM and macOS HVF specific machine type > > called "v

Re: [PATCH 3/8] qemu-thread: Avoid futex abstraction for non-Linux

2024-12-28 Thread Phil Dennis-Jordan
This fix makes sense. I've also successfully tested with this new "pure" pthread-based QemuEvent in the apple-gfx code where we initially considered using QemuEvent and ran into the destruction issue on macOS. Tested-by: Phil Dennis-Jordan Reviewed-by: Phil Dennis-Jordan (Unre

Re: [PATCH 1/8] futex: Check value after qemu_futex_wait()

2024-12-28 Thread Phil Dennis-Jordan
ue (i.e., > > the user-space synchronization scheme) to decide whether to continue > > to block or not. > > Signed-off-by: Akihiko Odaki > In any case, for the specific issue addressed here: Reviewed-by: Phil Dennis-Jordan > --- > include/qemu/futex.h

Re: [PATCH 2/2] hw/intc: Have ARM_GIC select ARM_GICV3 when KVM is not available

2024-12-28 Thread Phil Dennis-Jordan
On Fri, 27 Dec 2024 at 21:24, Philippe Mathieu-Daudé wrote: > When the KVM accelerator is selected, the Kconfig ARM_GIC key > selects the KVM GIC implementation (ARM_GIC_KVM). > For other accelerators (TCG, HVF, ...), select the generic > implementation. > > Signed-off-by: Philippe Mathieu-Daudé

Re: [PATCH 1/2] hw/intc: Remove TCG dependency on ARM_GICV3

2024-12-28 Thread Phil Dennis-Jordan
M_GIC_TCG > Kconfig selector") > Signed-off-by: Philippe Mathieu-Daudé > Reviewed-by: Phil Dennis-Jordan Tested-by: Phil Dennis-Jordan > --- > hw/intc/Kconfig | 6 +++--- > hw/intc/meson.build | 4 ++-- > 2 files changed, 5 insertions(+), 5 deletions(-) >

Re: [PATCH v3 1/6] hw/usb/hcd-xhci-pci: Use modulo to select MSI vector as per spec

2024-12-28 Thread Phil Dennis-Jordan
On Fri, 27 Dec 2024 at 21:27, Philippe Mathieu-Daudé wrote: > On 27/12/24 20:45, Phil Dennis-Jordan wrote: > > > > > > On Fri 27. Dec 2024 at 18:45, Philippe Mathieu-Daudé > <mailto:phi...@linaro.org>> wrote: > > > > On 27/12/24 13:13, Phil Den

Re: [PATCH v16 14/14] hw/vmapple/vmapple: Add vmapple machine type

2024-12-28 Thread Phil Dennis-Jordan
On Fri, 27 Dec 2024 at 21:41, Philippe Mathieu-Daudé wrote: > On 27/12/24 21:12, Phil Dennis-Jordan wrote: > > > > diff --git a/hw/vmapple/Kconfig b/hw/vmapple/Kconfig > > > index bcd1be63e3..6a4c4a7fa2 100644 > > > --- a/hw/vmapple/Kconfig &g

Re: [PATCH v16 14/14] hw/vmapple/vmapple: Add vmapple machine type

2024-12-28 Thread Phil Dennis-Jordan
On Fri, 27 Dec 2024 at 21:36, Philippe Mathieu-Daudé wrote: > On 23/12/24 23:16, Phil Dennis-Jordan wrote: > > > Known issues: > > - Keyboard and mouse/tablet input is laggy. The reason for this is > > that macOS's XHCI driver seems to expect interrupter mappin

Re: [PATCH v16 14/14] hw/vmapple/vmapple: Add vmapple machine type

2024-12-27 Thread Phil Dennis-Jordan
On Fri 27. Dec 2024 at 20:23, Philippe Mathieu-Daudé wrote: > On 23/12/24 23:16, Phil Dennis-Jordan wrote: > > From: Alexander Graf > > > > Apple defines a new "vmapple" machine type as part of its proprietary > > macOS Virtualization.Framework vmm. This ma

Re: [PATCH v3 1/6] hw/usb/hcd-xhci-pci: Use modulo to select MSI vector as per spec

2024-12-27 Thread Phil Dennis-Jordan
On Fri 27. Dec 2024 at 18:45, Philippe Mathieu-Daudé wrote: > On 27/12/24 13:13, Phil Dennis-Jordan wrote: > > QEMU would crash with a failed assertion if the XHCI controller > > attempted to raise the interrupt on a higher vector than the > > highest configured for th

[PATCH v3 4/6] hw/usb/hcd-xhci: Unimplemented/guest error logging for port MMIO

2024-12-27 Thread Phil Dennis-Jordan
LOG_UNIMP or LOG_GUEST_ERROR, as appropriate in each case. Signed-off-by: Phil Dennis-Jordan --- hw/usb/hcd-xhci.c | 25 ++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c index 011c445443..00d5bc3779 100644 --- a/hw/usb/hcd

Re: [PATCH v16 00/14] macOS PV Graphics and new vmapple machine type

2024-12-27 Thread Phil Dennis-Jordan
On Mon, 23 Dec 2024 at 23:58, Philippe Mathieu-Daudé wrote: > On 23/12/24 23:16, Phil Dennis-Jordan wrote: > > This patch set introduces a new ARM and macOS HVF specific machine type > > called "vmapple", as well as a family of display devices based on the > > Pa

[PATCH v3 6/6] hw/vmapple: XHCI controller's interrupt mapping workaround for macOS

2024-12-27 Thread Phil Dennis-Jordan
annel available. With conditional interrupt mapping enabled, the XHCI controller will only schedule events on interrupter 0 in PCI pin mode. Signed-off-by: Phil Dennis-Jordan --- v2: * Set the "conditional-intr-mapping" property via compat_props, not directly on the created XHCI control

[PATCH v3 2/6] hw/usb/hcd-xhci-pci: Move msi/msix properties from NEC to superclass

2024-12-27 Thread Phil Dennis-Jordan
XHCI device variants. Signed-off-by: Phil Dennis-Jordan Reviewed-by: Philippe Mathieu-Daudé --- v3: * In line with recent upstream changes, the property table is now const and no longer carries an end-of-list marker. hw/usb/hcd-xhci-nec.c | 2 -- hw/usb/hcd-xhci-pci.c | 6 ++ 2

[PATCH v3 3/6] hw/usb/hcd-xhci-pci: Use event ring 0 if mapping unsupported

2024-12-27 Thread Phil Dennis-Jordan
nts targeted at Interrupter 0." QEMU's XHCI device has so far not specially addressed this case, so we add a check to xhci_event() to redirect to event ring and interrupt 0 if mapping is disabled. Signed-off-by: Phil Dennis-Jordan --- hw/usb/hcd-xhci.c | 4 1 file changed, 4 inser

[PATCH v3 0/6] hw/usb/hcd-xhci: Fixes, improvements, and macOS workaround

2024-12-27 Thread Phil Dennis-Jordan
property table into vmapple patch set -v16; we now just add the conditional-intr-mapping property to it in this patch. We also set the property on any device implementing the abstract TYPE_XHCI_PCI rather than only the TYPE_QEMU_XHCI device specifically. Phil Dennis-Jordan (6): hw/usb/hc

[PATCH v3 5/6] hw/usb/hcd-xhci-pci: Adds property for disabling mapping in IRQ mode

2024-12-27 Thread Phil Dennis-Jordan
s. Signed-off-by: Phil Dennis-Jordan Resolves: https://gitlab.com/qemu-project/qemu/-/issues/2705 --- hw/usb/hcd-xhci-pci.c | 24 hw/usb/hcd-xhci-pci.h | 1 + hw/usb/hcd-xhci.c | 3 ++- hw/usb/hcd-xhci.h | 5 + 4 files changed, 32 insertions(+), 1 deletio

[PATCH v3 1/6] hw/usb/hcd-xhci-pci: Use modulo to select MSI vector as per spec

2024-12-27 Thread Phil Dennis-Jordan
controller signal the MSI vector with the number computed by taking the interrupter number modulo the number of enabled MSI vectors. This change introduces that modulo calculation, fixing the failed assertion and making the device work correctly in MSI mode with macOS's XHCI driver. Signed-off-

[PATCH v16 11/14] hw/vmapple/cfg: Introduce vmapple cfg region

2024-12-23 Thread Phil Dennis-Jordan
device which we can then map at the fixed location in the address space. That way, we can influence and annotate all configuration fields easily. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v3: * Replaced legacy device

[PATCH v16 08/14] gpex: Allow more than 4 legacy IRQs

2024-12-23 Thread Phil Dennis-Jordan
n 4 legacy IRQ lines. In this mode, GPEX will export more IRQ lines, one for each device. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki Reviewed-by: Philippe Mathieu-Daudé --- v4: * Turned pair of IRQ arrays i

[PATCH v16 07/14] hw/misc/pvpanic: Add MMIO interface

2024-12-23 Thread Phil Dennis-Jordan
From: Alexander Graf In addition to the ISA and PCI variants of pvpanic, let's add an MMIO platform device that we can use in embedded arm environments. Signed-off-by: Alexander Graf Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé Signed-off-by: Phil Dennis-J

[PATCH v16 03/14] hw/display/apple-gfx: Adds PCI implementation

2024-12-23 Thread Phil Dennis-Jordan
This change wires up the PCI variant of the paravirtualised graphics device, mainly useful for x86-64 macOS guests, implemented by macOS's ParavirtualizedGraphics.framework. It builds on code shared with the vmapple/mmio variant of the PVG device. Signed-off-by: Phil Dennis-Jordan Review

[PATCH v16 12/14] hw/vmapple/virtio-blk: Add support for apple virtio-blk

2024-12-23 Thread Phil Dennis-Jordan
7;variant' property. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v4: * Use recommended object type declaration pattern. * Correctly log unimplemented code paths. * Most header code moved to .c, type name #defin

[PATCH v16 13/14] hw/block/virtio-blk: Replaces request free function with g_free

2024-12-23 Thread Phil Dennis-Jordan
The virtio_blk_free_request() function has been a 1-liner forwarding to g_free() for a while now. We may as well call g_free on the request pointer directly. Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- hw/block/virtio-blk.c | 43

[PATCH v16 09/14] hw/vmapple/aes: Introduce aes engine

2024-12-23 Thread Phil Dennis-Jordan
From: Alexander Graf VMApple contains an "aes" engine device that it uses to encrypt and decrypt its nvram. It has trivial hard coded keys it uses for that purpose. Add device emulation for this device model. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan R

[PATCH v16 14/14] hw/vmapple/vmapple: Add vmapple machine type

2024-12-23 Thread Phil Dennis-Jordan
Co-authored-by: Phil Dennis-Jordan Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v3: * Rebased on latest upstream, updated affinity and NIC creation API usage * Included Apple-variant virtio-blk in build dependency * Updated API usage for setting

[PATCH v16 05/14] MAINTAINERS: Add myself as maintainer for apple-gfx, reviewer for HVF

2024-12-23 Thread Phil Dennis-Jordan
I'm happy to take responsibility for the macOS PV graphics code. As HVF patches don't seem to get much attention at the moment, I'm also adding myself as designated reviewer for HVF and x86 HVF to try and improve that. Signed-off-by: Phil Dennis-Jordan Reviewed-by: Roman Bolshak

[PATCH v16 02/14] hw/display/apple-gfx: Introduce ParavirtualizedGraphics.Framework support

2024-12-23 Thread Phil Dennis-Jordan
Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v2: * Cherry-pick/rebase conflict fixes * BQL function renaming * Moved from hw/vmapple/ (useful outside that machine type) * Code review comments: Switched to DEFINE_TYPES macro & little endian MMIO. * Removed

Re: [PATCH v15 15/15] hw/vmapple/vmapple: Add vmapple machine type

2024-12-23 Thread Phil Dennis-Jordan
On Mon, 23 Dec 2024 at 18:38, Phil Dennis-Jordan wrote: > Hi Philippe, > > > On 23.12.2024, at 17:36, Philippe Mathieu-Daudé > wrote: > > > > Hi Phil, > > > >> On 23/12/24 14:53, Phil Dennis-Jordan wrote: > >> On Thu, 19 Dec 2024 at 11:

[PATCH v16 06/14] hw: Add vmapple subdir

2024-12-23 Thread Phil Dennis-Jordan
From: Alexander Graf We will introduce a number of devices that are specific to the vmapple target machine. To keep them all tidily together, let's put them into a single target directory. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Test

[PATCH v16 04/14] hw/display/apple-gfx: Adds configurable mode list

2024-12-23 Thread Phil Dennis-Jordan
iver":"apple-gfx-pci", "display-modes":["1920x1080@60", "3840x2160@60"]}' Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v4: * Switched to the native array property type, which recently gained

[PATCH v16 10/14] hw/vmapple/bdif: Introduce vmapple backdoor interface

2024-12-23 Thread Phil Dennis-Jordan
; they're only needed for guest recovery and I don't understand the protocol yet. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v4: * Moved most header code to .c, rest to vmapple.h * Better compliance with codi

[PATCH v16 01/14] ui & main loop: Redesign of system-specific main thread event handling

2024-12-23 Thread Phil Dennis-Jordan
any UI or even none at all.) Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v5: * Simplified the way of setting/clearing the main loop by going back to setting qemu_main directly, but narrowing the scope of what it needs to do

[PATCH v16 00/14] macOS PV Graphics and new vmapple machine type

2024-12-23 Thread Phil Dennis-Jordan
Introduce aes engine hw/vmapple/bdif: Introduce vmapple backdoor interface hw/vmapple/cfg: Introduce vmapple cfg region hw/vmapple/virtio-blk: Add support for apple virtio-blk hw/vmapple/vmapple: Add vmapple machine type Phil Dennis-Jordan (6): ui & main loop: Redesign of system-spec

Re: [PATCH v15 15/15] hw/vmapple/vmapple: Add vmapple machine type

2024-12-23 Thread Phil Dennis-Jordan
Hi Philippe, > On 23.12.2024, at 17:36, Philippe Mathieu-Daudé wrote: > > Hi Phil, > >> On 23/12/24 14:53, Phil Dennis-Jordan wrote: >> On Thu, 19 Dec 2024 at 11:50, Akihiko Odaki > <mailto:akihiko.od...@daynix.com>> wrote: >>Reviewing &qu

Re: [PATCH v15 15/15] hw/vmapple/vmapple: Add vmapple machine type

2024-12-23 Thread Phil Dennis-Jordan
On Thu, 19 Dec 2024 at 11:50, Akihiko Odaki wrote: > Reviewing "[PATCH v2 6/6] hw/vmapple: XHCI controller's interrupt > mapping workaround for macOS", I found a few problems so I'm adding > comments for them: > > On 2024/12/19 5:20, Phil Dennis-Jor

Re: [PATCH 5/8] hw/usb/xhci: Move HCD constants to a header and add register constants

2024-12-20 Thread Phil Dennis-Jordan
On Thu, 19 Dec 2024 at 02:50, Nicholas Piggin wrote: > On Thu Dec 19, 2024 at 1:08 AM AEST, Phil Dennis-Jordan wrote: > > This looks sensible to me overall. > > > > For the new symbolic constants for MMIO register offsets such as > > XHCI_OPER_*, XHCI_INTR_* and so on

Re: [PATCH v2 1/2] hw/usb/hcd-xhci-pci: Make PCI device more configurable

2024-12-18 Thread Phil Dennis-Jordan
On Wed, 18 Dec 2024 at 02:19, Nicholas Piggin wrote: > On Thu Dec 12, 2024 at 8:41 PM AEST, Phil Dennis-Jordan wrote: > > Hey Nicholas, > > > > I'm not an XHCI & PCI expert (yet?) so apologies if I've got some of this > > wrong, but I've aske

[PATCH v15 13/15] hw/vmapple/virtio-blk: Add support for apple virtio-blk

2024-12-18 Thread Phil Dennis-Jordan
7;variant' property. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v4: * Use recommended object type declaration pattern. * Correctly log unimplemented code paths. * Most header code moved to .c, type name #defin

[PATCH v15 08/15] hvf: arm: Ignore writes to CNTP_CTL_EL0

2024-12-18 Thread Phil Dennis-Jordan
From: Alexander Graf MacOS unconditionally disables interrupts of the physical timer on boot and then continues to use the virtual one. We don't really want to support a full physical timer emulation, so let's just ignore those writes. Signed-off-by: Alexander Graf Signed-off-by: P

[PATCH v15 10/15] hw/vmapple/aes: Introduce aes engine

2024-12-18 Thread Phil Dennis-Jordan
From: Alexander Graf VMApple contains an "aes" engine device that it uses to encrypt and decrypt its nvram. It has trivial hard coded keys it uses for that purpose. Add device emulation for this device model. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan R

[PATCH v15 07/15] hw/misc/pvpanic: Add MMIO interface

2024-12-18 Thread Phil Dennis-Jordan
From: Alexander Graf In addition to the ISA and PCI variants of pvpanic, let's add an MMIO platform device that we can use in embedded arm environments. Signed-off-by: Alexander Graf Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé Signed-off-by: Phil Dennis-J

[PATCH v15 03/15] hw/display/apple-gfx: Adds PCI implementation

2024-12-18 Thread Phil Dennis-Jordan
This change wires up the PCI variant of the paravirtualised graphics device, mainly useful for x86-64 macOS guests, implemented by macOS's ParavirtualizedGraphics.framework. It builds on code shared with the vmapple/mmio variant of the PVG device. Signed-off-by: Phil Dennis-Jordan Review

[PATCH v15 12/15] hw/vmapple/cfg: Introduce vmapple cfg region

2024-12-18 Thread Phil Dennis-Jordan
device which we can then map at the fixed location in the address space. That way, we can influence and annotate all configuration fields easily. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v3: * Replaced legacy device

[PATCH v15 05/15] MAINTAINERS: Add myself as maintainer for apple-gfx, reviewer for HVF

2024-12-18 Thread Phil Dennis-Jordan
contract runs out if it's more than I can manage. Signed-off-by: Phil Dennis-Jordan Reviewed-by: Roman Bolshakov --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 822f34344b0..5aca2833c2d 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -

[PATCH v15 01/15] ui & main loop: Redesign of system-specific main thread event handling

2024-12-18 Thread Phil Dennis-Jordan
any UI or even none at all.) Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v5: * Simplified the way of setting/clearing the main loop by going back to setting qemu_main directly, but narrowing the scope of what it needs to do

[PATCH v15 06/15] hw: Add vmapple subdir

2024-12-18 Thread Phil Dennis-Jordan
From: Alexander Graf We will introduce a number of devices that are specific to the vmapple target machine. To keep them all tidily together, let's put them into a single target directory. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Test

[PATCH v15 02/15] hw/display/apple-gfx: Introduce ParavirtualizedGraphics.Framework support

2024-12-18 Thread Phil Dennis-Jordan
Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v2: * Cherry-pick/rebase conflict fixes * BQL function renaming * Moved from hw/vmapple/ (useful outside that machine type) * Code review comments: Switched to DEFINE_TYPES macro & little endian MMIO. * Removed

[PATCH v15 09/15] gpex: Allow more than 4 legacy IRQs

2024-12-18 Thread Phil Dennis-Jordan
n 4 legacy IRQ lines. In this mode, GPEX will export more IRQ lines, one for each device. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v4: * Turned pair of IRQ arrays into array of structs. * Simplified swizzling l

[PATCH v15 14/15] hw/block/virtio-blk: Replaces request free function with g_free

2024-12-18 Thread Phil Dennis-Jordan
The virtio_blk_free_request() function has been a 1-liner forwarding to g_free() for a while now. We may as well call g_free on the request pointer directly. Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- hw/block/virtio-blk.c | 43

[PATCH v15 00/15] macOS PV Graphics and new vmapple machine type

2024-12-18 Thread Phil Dennis-Jordan
uce aes engine hw/vmapple/bdif: Introduce vmapple backdoor interface hw/vmapple/cfg: Introduce vmapple cfg region hw/vmapple/virtio-blk: Add support for apple virtio-blk hw/vmapple/vmapple: Add vmapple machine type Phil Dennis-Jordan (6): ui & main loop: Redesign of system-specific m

[PATCH v15 04/15] hw/display/apple-gfx: Adds configurable mode list

2024-12-18 Thread Phil Dennis-Jordan
iver":"apple-gfx-pci", "display-modes":["1920x1080@60", "3840x2160@60"]}' Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v4: * Switched to the native array property type, which recently gained

[PATCH v15 11/15] hw/vmapple/bdif: Introduce vmapple backdoor interface

2024-12-18 Thread Phil Dennis-Jordan
; they're only needed for guest recovery and I don't understand the protocol yet. Signed-off-by: Alexander Graf Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v4: * Moved most header code to .c, rest to vmapple.h * Better compliance with codi

[PATCH v15 15/15] hw/vmapple/vmapple: Add vmapple machine type

2024-12-18 Thread Phil Dennis-Jordan
Co-authored-by: Phil Dennis-Jordan Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v3: * Rebased on latest upstream, updated affinity and NIC creation API usage * Included Apple-variant virtio-blk in build dependency * Updated API usage for setting

Re: [PATCH 5/8] hw/usb/xhci: Move HCD constants to a header and add register constants

2024-12-18 Thread Phil Dennis-Jordan
This looks sensible to me overall. For the new symbolic constants for MMIO register offsets such as XHCI_OPER_*, XHCI_INTR_* and so on, I'm wondering if it would be clearer to give them all an _OFFSET suffix. It's not perfectly consistent to do so across the code base, but quite a few device types

Re: [PATCH v14 00/15] macOS PV Graphics and new vmapple machine type

2024-12-13 Thread Phil Dennis-Jordan
Sigh… apologies for re-sending v13 together with v14 here. Please ignore v13 of course. git send-email is not my friend… On Fri, 13 Dec 2024 at 16:24, Phil Dennis-Jordan wrote: > > This patch series has been through months of review and > refinement. It now has end-to-end Reviewed-by:

[PATCH v2 2/6] hw/usb/hcd-xhci-pci: Move msi/msix properties from NEC to superclass

2024-12-13 Thread Phil Dennis-Jordan
XHCI device variants. Signed-off-by: Phil Dennis-Jordan --- hw/usb/hcd-xhci-nec.c | 2 -- hw/usb/hcd-xhci-pci.c | 7 +++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/hw/usb/hcd-xhci-nec.c b/hw/usb/hcd-xhci-nec.c index 0c063b3697d..408bf065e5a 100644 --- a/hw/usb/hcd-xhci-

[PATCH v2 3/6] hw/usb/hcd-xhci-pci: Use event ring 0 if mapping unsupported

2024-12-13 Thread Phil Dennis-Jordan
xhci_event() to redirect to event ring and interrupt 0 if mapping is disabled. Signed-off-by: Phil Dennis-Jordan --- hw/usb/hcd-xhci.c | 4 1 file changed, 4 insertions(+) diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c index d85adaca0dc..5fb140c2382 100644 --- a/hw/usb/hcd-xhci.c +

[PATCH v2 5/6] hw/usb/hcd-xhci-pci: Indentation fix

2024-12-13 Thread Phil Dennis-Jordan
Fixes number of spaces used for indentation on one line. Signed-off-by: Phil Dennis-Jordan --- hw/usb/hcd-xhci-pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/usb/hcd-xhci-pci.c b/hw/usb/hcd-xhci-pci.c index 6027eed2d26..2ac0fd0bf1a 100644 --- a/hw/usb/hcd-xhci

[PATCH v2 4/6] hw/usb/hcd-xhci-pci: Adds property for disabling mapping in IRQ mode

2024-12-13 Thread Phil Dennis-Jordan
s. Signed-off-by: Phil Dennis-Jordan Resolves: https://gitlab.com/qemu-project/qemu/-/issues/2705 --- hw/usb/hcd-xhci-pci.c | 24 hw/usb/hcd-xhci-pci.h | 1 + hw/usb/hcd-xhci.c | 3 ++- hw/usb/hcd-xhci.h | 5 + 4 files changed, 32 insertions(+), 1 deletio

[PATCH v2 6/6] hw/vmapple: XHCI controller's interrupt mapping workaround for macOS

2024-12-13 Thread Phil Dennis-Jordan
annel available. With conditional interrupt mapping enabled, the XHCI controller will only schedule events on interrupter 0 in PCI pin mode. Signed-off-by: Phil Dennis-Jordan --- v2: * Set the "conditional-intr-mapping" property via compat_props, not directly on the created XHCI controll

[PATCH v2 1/6] hw/usb/hcd-xhci-pci: Use modulo to select MSI vector as per spec

2024-12-13 Thread Phil Dennis-Jordan
controller signal the MSI vector with the number computed by taking the interrupter number modulo the number of enabled MSI vectors. This change introduces that modulo calculation, fixing the failed assertion and making the device work correctly in MSI mode with macOS's XHCI driver. Signed-off-

[PATCH v2 0/6] hw/usb/hcd-xhci: Fixes, improvements, and macOS workaround

2024-12-13 Thread Phil Dennis-Jordan
ed by the standard, and one for the conditional disabling workaround. v1 -> v2: * 1/6: Switch to modulo arithmetic for MSI vector number, as per spec. * 6/6: Set the "conditional-intr-mapping" property via compat_props. * Commit message tweaks Phil Dennis-Jordan (6): hw/usb/h

[PATCH v13 08/15] hvf: arm: Ignore writes to CNTP_CTL_EL0

2024-12-13 Thread Phil Dennis-Jordan
From: Alexander Graf MacOS unconditionally disables interrupts of the physical timer on boot and then continues to use the virtual one. We don't really want to support a full physical timer emulation, so let's just ignore those writes. Signed-off-by: Alexander Graf Signed-off-by: P

[PATCH v13 15/15] hw/vmapple/vmapple: Add vmapple machine type

2024-12-13 Thread Phil Dennis-Jordan
S 12 guests are supported. The boot process for 13+ will need further investigation and adjustment. Signed-off-by: Alexander Graf Co-authored-by: Phil Dennis-Jordan Signed-off-by: Phil Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v3: * Rebased on latest upstream, updat

[PATCH v14 02/15] hw/display/apple-gfx: Introduce ParavirtualizedGraphics.Framework support

2024-12-13 Thread Phil Dennis-Jordan
Dennis-Jordan Reviewed-by: Akihiko Odaki Tested-by: Akihiko Odaki --- v2: * Cherry-pick/rebase conflict fixes * BQL function renaming * Moved from hw/vmapple/ (useful outside that machine type) * Code review comments: Switched to DEFINE_TYPES macro & little endian MMIO. * Removed

  1   2   3   4   5   6   >