forked from HW42/qubes-vmm-xen-stubdom-linux
-
-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
16 changed files
with
76 additions
and
102 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,11 @@ | ||
From e66aa97dca5120f22e015c19710b2ff04f525720 Mon Sep 17 00:00:00 2001 | ||
Message-Id: <e66aa97dca5120f22e015c19710b2ff04f525720.1711505965.git-series.marmarek@invisiblethingslab.com> | ||
In-Reply-To: <cover.23e6b4d5c3fde23f2b53481b6d2b159fbed14513.1711505965.git-series.marmarek@invisiblethingslab.com> | ||
References: <cover.23e6b4d5c3fde23f2b53481b6d2b159fbed14513.1711505965.git-series.marmarek@invisiblethingslab.com> | ||
From: Marek Marczykowski-Górecki <[email protected]> | ||
From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= | ||
<[email protected]> | ||
Date: Sat, 17 Feb 2024 03:51:44 +0100 | ||
Subject: [PATCH v3 1/2] hw/xen: detect when running inside stubdomain | ||
Subject: [PATCH 1/2] hw/xen: detect when running inside stubdomain | ||
MIME-Version: 1.0 | ||
Content-Type: text/plain; charset=UTF-8 | ||
Content-Transfer-Encoding: 8bit | ||
|
||
Introduce global xen_is_stubdomain variable when qemu is running inside | ||
a stubdomain instead of dom0. This will be relevant for subsequent | ||
|
@@ -22,11 +23,11 @@ Changes in v2: | |
--- | ||
hw/i386/xen/xen-hvm.c | 22 ++++++++++++++++++++++ | ||
include/hw/xen/xen.h | 1 + | ||
softmmu/globals.c | 1 + | ||
system/globals.c | 1 + | ||
3 files changed, 24 insertions(+) | ||
|
||
diff --git a/hw/i386/xen/xen-hvm.c b/hw/i386/xen/xen-hvm.c | ||
index 7745cb3..3291c17 100644 | ||
index 7745cb3963..3291c177d3 100644 | ||
--- a/hw/i386/xen/xen-hvm.c | ||
+++ b/hw/i386/xen/xen-hvm.c | ||
@@ -583,6 +583,26 @@ static void xen_wakeup_notifier(Notifier *notifier, void *data) | ||
|
@@ -66,7 +67,7 @@ index 7745cb3..3291c17 100644 | |
xen_read_physmap(state); | ||
|
||
diff --git a/include/hw/xen/xen.h b/include/hw/xen/xen.h | ||
index 37ecc91..ecb89ec 100644 | ||
index 37ecc91fc3..ecb89ecfc1 100644 | ||
--- a/include/hw/xen/xen.h | ||
+++ b/include/hw/xen/xen.h | ||
@@ -36,6 +36,7 @@ enum xen_mode { | ||
|
@@ -77,10 +78,10 @@ index 37ecc91..ecb89ec 100644 | |
|
||
int xen_pci_slot_get_pirq(PCIDevice *pci_dev, int irq_num); | ||
int xen_set_pci_link_route(uint8_t link, uint8_t irq); | ||
diff --git a/softmmu/globals.c b/softmmu/globals.c | ||
index e353584..d602a04 100644 | ||
--- a/softmmu/globals.c | ||
+++ b/softmmu/globals.c | ||
diff --git a/system/globals.c b/system/globals.c | ||
index e353584201..d602a04fa2 100644 | ||
--- a/system/globals.c | ||
+++ b/system/globals.c | ||
@@ -60,6 +60,7 @@ bool qemu_uuid_set; | ||
uint32_t xen_domid; | ||
enum xen_mode xen_mode = XEN_DISABLED; | ||
|
@@ -90,4 +91,5 @@ index e353584..d602a04 100644 | |
struct gnttab_backend_ops *xen_gnttab_ops; | ||
struct foreignmem_backend_ops *xen_foreignmem_ops; | ||
-- | ||
git-series 0.9.1 | ||
2.45.2 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,11 @@ | ||
From 35049e99da634a74578a1ff2cb3ae4cc436ede33 Mon Sep 17 00:00:00 2001 | ||
Message-Id: <35049e99da634a74578a1ff2cb3ae4cc436ede33.1711506237.git-series.marmarek@invisiblethingslab.com> | ||
In-Reply-To: <cover.527f002866de2be7c275c5000b6e5edfeb7e8368.1711506237.git-series.marmarek@invisiblethingslab.com> | ||
References: <cover.527f002866de2be7c275c5000b6e5edfeb7e8368.1711506237.git-series.marmarek@invisiblethingslab.com> | ||
From: Marek Marczykowski-Górecki <[email protected]> | ||
From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= | ||
<[email protected]> | ||
Date: Wed, 27 Mar 2024 03:23:28 +0100 | ||
Subject: [PATCH v3 2/2] xen: fix stubdom PCI addr | ||
Subject: [PATCH 2/2] xen: fix stubdom PCI addr | ||
MIME-Version: 1.0 | ||
Content-Type: text/plain; charset=UTF-8 | ||
Content-Transfer-Encoding: 8bit | ||
|
||
When running in a stubdomain, the config space access via sysfs needs to | ||
use BDF as seen inside stubdomain (connected via xen-pcifront), which is | ||
|
@@ -24,12 +25,12 @@ Changes in v2: | |
- use %d instead of %u to read values written as %d | ||
- add a comment from another iteration of this patch by Jason Andryuk | ||
--- | ||
hw/xen/xen-host-pci-device.c | 76 ++++++++++++++++++++++++++++++++++++- | ||
hw/xen/xen-host-pci-device.h | 6 +++- | ||
hw/xen/xen-host-pci-device.c | 76 +++++++++++++++++++++++++++++++++++- | ||
hw/xen/xen-host-pci-device.h | 6 +++ | ||
2 files changed, 81 insertions(+), 1 deletion(-) | ||
|
||
diff --git a/hw/xen/xen-host-pci-device.c b/hw/xen/xen-host-pci-device.c | ||
index 8c6e9a1..eaf32f2 100644 | ||
index 8c6e9a1716..eaf32f2710 100644 | ||
--- a/hw/xen/xen-host-pci-device.c | ||
+++ b/hw/xen/xen-host-pci-device.c | ||
@@ -9,6 +9,8 @@ | ||
|
@@ -136,7 +137,7 @@ index 8c6e9a1..eaf32f2 100644 | |
if (*errp) { | ||
goto error; | ||
diff --git a/hw/xen/xen-host-pci-device.h b/hw/xen/xen-host-pci-device.h | ||
index 4d8d34e..270dcb2 100644 | ||
index 4d8d34ecb0..270dcb27f7 100644 | ||
--- a/hw/xen/xen-host-pci-device.h | ||
+++ b/hw/xen/xen-host-pci-device.h | ||
@@ -23,6 +23,12 @@ typedef struct XenHostPCIDevice { | ||
|
@@ -153,4 +154,5 @@ index 4d8d34e..270dcb2 100644 | |
uint16_t device_id; | ||
uint32_t class_code; | ||
-- | ||
git-series 0.9.1 | ||
2.45.2 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.