Compare commits
33 Commits
master
...
pve-kernel
Author | SHA1 | Date | |
---|---|---|---|
|
baaff00068 | ||
|
78c7cd1268 | ||
|
cddb60ba98 | ||
|
190eaba617 | ||
|
5b3d3093ca | ||
|
fc1f1bcf33 | ||
|
0cc6238b6a | ||
|
95f0dbdf95 | ||
|
6d55ef4204 | ||
|
35ae23b799 | ||
|
d560c5ab1f | ||
|
3941d44fc1 | ||
|
8035e345a3 | ||
|
bcc5f56bff | ||
|
5a9bd9e526 | ||
|
194f0e8cd1 | ||
|
5c65ad73e4 | ||
|
555e0089c9 | ||
|
85685cd8cc | ||
|
dd3e28d69a | ||
|
ccc9ec8625 | ||
|
fc515da43f | ||
|
ac522e5498 | ||
|
7a06daf86e | ||
|
924f2ef793 | ||
|
a853ae6e5c | ||
|
c9327c4346 | ||
|
72807eeeb0 | ||
|
7c0c6c37b2 | ||
|
51f08b8f16 | ||
|
996ac366f8 | ||
|
37f415cc04 | ||
|
6607727e2f |
4
Makefile
4
Makefile
@ -4,9 +4,9 @@ KERNEL_MIN=13
|
||||
KERNEL_PATCHLEVEL=19
|
||||
# increment KREL if the ABI changes (abicheck target in debian/rules)
|
||||
# rebuild packages with new KREL and run 'make abiupdate'
|
||||
KREL=2
|
||||
KREL=6
|
||||
|
||||
PKGREL=4
|
||||
PKGREL=14
|
||||
|
||||
KERNEL_MAJMIN=$(KERNEL_MAJ).$(KERNEL_MIN)
|
||||
KERNEL_VER=$(KERNEL_MAJMIN).$(KERNEL_PATCHLEVEL)
|
||||
|
25897
abi-prev-5.13.19-2-pve
25897
abi-prev-5.13.19-2-pve
File diff suppressed because it is too large
Load Diff
25907
abi-prev-5.13.19-6-pve
Normal file
25907
abi-prev-5.13.19-6-pve
Normal file
File diff suppressed because it is too large
Load Diff
69
debian/changelog
vendored
69
debian/changelog
vendored
@ -1,3 +1,72 @@
|
||||
pve-kernel (5.13.19-14) bullseye; urgency=medium
|
||||
|
||||
* update to Ubuntu-5.13.0-36.41
|
||||
|
||||
* bump ABI to 5.13.19-6
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Thu, 10 Mar 2022 16:24:52 +0100
|
||||
|
||||
pve-kernel (5.13.19-13) bullseye; urgency=medium
|
||||
|
||||
* backport "KVM: VMX: prepare sync_pir_to_irr for running with APICv
|
||||
disabled" to avoid breaking some Windows VMs startup
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Tue, 08 Mar 2022 07:32:25 +0100
|
||||
|
||||
pve-kernel (5.13.19-12) bullseye; urgency=medium
|
||||
|
||||
* Revert "PCI/MSI: Mask MSI-X vectors only on success" as it's causing PCI-E
|
||||
initialization failures on some systems.
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Mon, 07 Mar 2022 15:54:28 +0100
|
||||
|
||||
pve-kernel (5.13.19-11) bullseye; urgency=medium
|
||||
|
||||
* backport "lib/iov_iter: initialize "flags" in new pipe_buffer" fixing
|
||||
CVE-2022-0847 "dirty pipe"
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Mon, 07 Mar 2022 13:28:22 +0100
|
||||
|
||||
pve-kernel (5.13.19-10) bullseye; urgency=medium
|
||||
|
||||
* update to Ubuntu-5.13.0-31.34
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Mon, 21 Feb 2022 09:26:12 +0100
|
||||
|
||||
pve-kernel (5.13.19-9) bullseye; urgency=medium
|
||||
|
||||
* update to Ubuntu-5.13.0-30.33
|
||||
revert a problematic patch causing issues with releasing block devices
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Mon, 07 Feb 2022 11:01:14 +0100
|
||||
|
||||
pve-kernel (5.13.19-8) bullseye; urgency=medium
|
||||
|
||||
* update sources to Ubuntu-5.13.0-29.32
|
||||
|
||||
* bump ABI to 5.13.19-4
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Mon, 31 Jan 2022 10:09:37 +0100
|
||||
|
||||
pve-kernel (5.13.19-7) bullseye; urgency=medium
|
||||
|
||||
* backport "vfs: fs_context: fix up param length parsing in
|
||||
legacy_parse_param"
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Thu, 20 Jan 2022 16:37:56 +0100
|
||||
|
||||
pve-kernel (5.13.19-6) bullseye; urgency=medium
|
||||
|
||||
* update sources to Ubuntu-5.13.0-24.24
|
||||
|
||||
* bump ABI to 5.13.19-3
|
||||
|
||||
* update ZFS to 2.1.2
|
||||
|
||||
* ZFS: cherry-pick lock-inversion patch for zvol_open
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Tue, 11 Jan 2022 16:44:47 +0100
|
||||
|
||||
pve-kernel (5.13.19-4) bullseye; urgency=medium
|
||||
|
||||
* update sources to Ubuntu-5.13.0-23.23
|
||||
|
7
debian/control.in
vendored
7
debian/control.in
vendored
@ -32,7 +32,8 @@ Build-Depends: asciidoc-base,
|
||||
sphinx-common,
|
||||
tar,
|
||||
xmlto,
|
||||
zlib1g-dev
|
||||
zlib1g-dev,
|
||||
zstd,
|
||||
Build-Conflicts: pve-headers-@KVNAME@
|
||||
Vcs-Git: git://git.proxmox.com/git/pve-kernel
|
||||
Vcs-Browser: https://git.proxmox.com/?p=pve-kernel.git
|
||||
@ -50,7 +51,7 @@ Package: pve-headers-@KVNAME@
|
||||
Section: devel
|
||||
Priority: optional
|
||||
Architecture: any
|
||||
Provides: linux-headers
|
||||
Provides: linux-headers-@KVNAME@-amd64
|
||||
Depends: coreutils | fileutils (>= 4.0)
|
||||
Description: The Proxmox PVE Kernel Headers
|
||||
This package contains the linux kernel headers
|
||||
@ -59,7 +60,7 @@ Package: pve-kernel-@KVNAME@
|
||||
Section: admin
|
||||
Priority: optional
|
||||
Architecture: any
|
||||
Provides: linux-image
|
||||
Provides: linux-image-@KVNAME@-amd64
|
||||
Suggests: pve-firmware
|
||||
Depends: busybox, initramfs-tools
|
||||
Recommends: grub-pc | grub-efi-amd64 | grub-efi-ia32 | grub-efi-arm64
|
||||
|
@ -990,7 +990,9 @@ mediatek/mt7668pr2h.bin kernel/drivers/bluetooth/btusb.ko
|
||||
mediatek/mt7915_rom_patch.bin kernel/drivers/net/wireless/mediatek/mt76/mt7915/mt7915e.ko
|
||||
mediatek/mt7915_wa.bin kernel/drivers/net/wireless/mediatek/mt76/mt7915/mt7915e.ko
|
||||
mediatek/mt7915_wm.bin kernel/drivers/net/wireless/mediatek/mt76/mt7915/mt7915e.ko
|
||||
mediatek/WIFI_MT7922_patch_mcu_1_1_hdr.bin kernel/drivers/net/wireless/mediatek/mt76/mt7921/mt7921e.ko
|
||||
mediatek/WIFI_MT7961_patch_mcu_1_2_hdr.bin kernel/drivers/net/wireless/mediatek/mt76/mt7921/mt7921e.ko
|
||||
mediatek/WIFI_RAM_CODE_MT7922_1.bin kernel/drivers/net/wireless/mediatek/mt76/mt7921/mt7921e.ko
|
||||
mediatek/WIFI_RAM_CODE_MT7961_1.bin kernel/drivers/net/wireless/mediatek/mt76/mt7921/mt7921e.ko
|
||||
mellanox/mlxsw_spectrum-13.2008.2406.mfa2 kernel/drivers/net/ethernet/mellanox/mlxsw/mlxsw_spectrum.ko
|
||||
mellanox/mlxsw_spectrum2-29.2008.2406.mfa2 kernel/drivers/net/ethernet/mellanox/mlxsw/mlxsw_spectrum.ko
|
||||
|
@ -55,10 +55,10 @@ Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||
2 files changed, 111 insertions(+)
|
||||
|
||||
diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
|
||||
index 8deb4cd7b133..291885ea26dd 100644
|
||||
index 550f341daf99..478530b48cf1 100644
|
||||
--- a/Documentation/admin-guide/kernel-parameters.txt
|
||||
+++ b/Documentation/admin-guide/kernel-parameters.txt
|
||||
@@ -3808,6 +3808,15 @@
|
||||
@@ -3814,6 +3814,15 @@
|
||||
Also, it enforces the PCI Local Bus spec
|
||||
rule that those bits should be 0 in system reset
|
||||
events (useful for kexec/kdump cases).
|
||||
@ -75,7 +75,7 @@ index 8deb4cd7b133..291885ea26dd 100644
|
||||
Safety option to keep boot IRQs enabled. This
|
||||
should never be necessary.
|
||||
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
|
||||
index d44037a6e109..1f576ba148dd 100644
|
||||
index 444ba11f3e79..5843ba2cad8e 100644
|
||||
--- a/drivers/pci/quirks.c
|
||||
+++ b/drivers/pci/quirks.c
|
||||
@@ -193,6 +193,106 @@ static int __init pci_apply_final_quirks(void)
|
||||
@ -185,7 +185,7 @@ index d44037a6e109..1f576ba148dd 100644
|
||||
/*
|
||||
* Decoding should be disabled for a PCI device during BAR sizing to avoid
|
||||
* conflict. But doing so may cause problems on host bridge and perhaps other
|
||||
@@ -4875,6 +4975,8 @@ static const struct pci_dev_acs_enabled {
|
||||
@@ -4876,6 +4976,8 @@ static const struct pci_dev_acs_enabled {
|
||||
{ PCI_VENDOR_ID_CAVIUM, 0xA060, pci_quirk_mf_endpoint_acs },
|
||||
/* APM X-Gene */
|
||||
{ PCI_VENDOR_ID_AMCC, 0xE004, pci_quirk_xgene_acs },
|
||||
|
@ -13,7 +13,7 @@ Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
|
||||
index 3b316cb42554..71aba634a6a8 100644
|
||||
index b86d4bce9793..946643fa1aa1 100644
|
||||
--- a/virt/kvm/kvm_main.c
|
||||
+++ b/virt/kvm/kvm_main.c
|
||||
@@ -78,7 +78,7 @@ module_param(halt_poll_ns, uint, 0644);
|
||||
|
@ -10,10 +10,10 @@ Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/net/core/dev.c b/net/core/dev.c
|
||||
index 156b44f35102..66014d76a61b 100644
|
||||
index 7bac7947d8b8..4196ce468b10 100644
|
||||
--- a/net/core/dev.c
|
||||
+++ b/net/core/dev.c
|
||||
@@ -10521,7 +10521,7 @@ static void netdev_wait_allrefs(struct net_device *dev)
|
||||
@@ -10533,7 +10533,7 @@ static void netdev_wait_allrefs(struct net_device *dev)
|
||||
if (refcnt != 1 &&
|
||||
time_after(jiffies, warning_time +
|
||||
netdev_unregister_timeout_secs * HZ)) {
|
||||
|
@ -15,11 +15,11 @@ Link: https://lore.kernel.org/r/20210709231529.GA3270116@roeck-us.net
|
||||
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
|
||||
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||
---
|
||||
drivers/pci/probe.c | 50 ++++-----------------------------------------
|
||||
1 file changed, 4 insertions(+), 46 deletions(-)
|
||||
drivers/pci/probe.c | 52 +++++----------------------------------------
|
||||
1 file changed, 5 insertions(+), 47 deletions(-)
|
||||
|
||||
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
|
||||
index f6046a16dac1..275204646c68 100644
|
||||
index 59ef93f1d953..b38a345c5df6 100644
|
||||
--- a/drivers/pci/probe.c
|
||||
+++ b/drivers/pci/probe.c
|
||||
@@ -19,7 +19,6 @@
|
||||
@ -92,13 +92,14 @@ index f6046a16dac1..275204646c68 100644
|
||||
-
|
||||
/* Add initial resources to the bus */
|
||||
resource_list_for_each_entry_safe(window, n, &resources) {
|
||||
+ list_move_tail(&window->node, &bridge->windows);
|
||||
offset = window->offset;
|
||||
res = window->res;
|
||||
- offset = window->offset;
|
||||
- res = window->res;
|
||||
- if (!res->end)
|
||||
- continue;
|
||||
-
|
||||
- list_move_tail(&window->node, &bridge->windows);
|
||||
list_move_tail(&window->node, &bridge->windows);
|
||||
+ offset = window->offset;
|
||||
+ res = window->res;
|
||||
|
||||
if (res->flags & IORESOURCE_BUS)
|
||||
pci_bus_insert_busn_res(bus, bus->number, res->end);
|
||||
|
@ -50,12 +50,13 @@ Cc: Guenter Roeck <linux@roeck-us.net>
|
||||
Suggested-by: Bjorn Helgaas <bhelgaas@google.com>
|
||||
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
|
||||
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
|
||||
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||
---
|
||||
drivers/pci/probe.c | 31 +++++++++++++++++++++++++++----
|
||||
1 file changed, 27 insertions(+), 4 deletions(-)
|
||||
drivers/pci/probe.c | 33 ++++++++++++++++++++++++++++-----
|
||||
1 file changed, 28 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
|
||||
index 275204646c68..944c35d87258 100644
|
||||
index b38a345c5df6..485167ca62a1 100644
|
||||
--- a/drivers/pci/probe.c
|
||||
+++ b/drivers/pci/probe.c
|
||||
@@ -877,11 +877,11 @@ static void pci_set_bus_msi_domain(struct pci_bus *bus)
|
||||
@ -99,13 +100,14 @@ index 275204646c68..944c35d87258 100644
|
||||
+
|
||||
/* Add initial resources to the bus */
|
||||
resource_list_for_each_entry_safe(window, n, &resources) {
|
||||
- list_move_tail(&window->node, &bridge->windows);
|
||||
offset = window->offset;
|
||||
res = window->res;
|
||||
+ offset = window->offset;
|
||||
+ res = window->res;
|
||||
+ if (!res->end)
|
||||
+ continue;
|
||||
+
|
||||
+ list_move_tail(&window->node, &bridge->windows);
|
||||
list_move_tail(&window->node, &bridge->windows);
|
||||
- offset = window->offset;
|
||||
- res = window->res;
|
||||
|
||||
if (res->flags & IORESOURCE_BUS)
|
||||
pci_bus_insert_busn_res(bus, bus->number, res->end);
|
||||
|
@ -1,40 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||
Date: Tue, 9 Nov 2021 12:01:12 +0100
|
||||
Subject: [PATCH] Revert "block: remove the -ERESTARTSYS handling in
|
||||
blkdev_get_by_dev"
|
||||
|
||||
This reverts commit a8ed1a0607cfa5478ff6009539f44790c4d0956d.
|
||||
|
||||
It breaks ZFS sometimes:
|
||||
https://github.com/openzfs/zfs/issues/12301#issuecomment-873303739
|
||||
|
||||
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||
---
|
||||
fs/block_dev.c | 6 ++++++
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
diff --git a/fs/block_dev.c b/fs/block_dev.c
|
||||
index e4a80bd4ddf1..4a14d28dd923 100644
|
||||
--- a/fs/block_dev.c
|
||||
+++ b/fs/block_dev.c
|
||||
@@ -1436,6 +1436,10 @@ struct block_device *blkdev_get_by_dev(dev_t dev, fmode_t mode, void *holder)
|
||||
if (ret)
|
||||
return ERR_PTR(ret);
|
||||
|
||||
+ /*
|
||||
+ * If we lost a race with 'disk' being deleted, try again. See md.c.
|
||||
+ */
|
||||
+retry:
|
||||
bdev = blkdev_get_no_open(dev);
|
||||
if (!bdev)
|
||||
return ERR_PTR(-ENXIO);
|
||||
@@ -1482,6 +1486,8 @@ struct block_device *blkdev_get_by_dev(dev_t dev, fmode_t mode, void *holder)
|
||||
disk_unblock_events(disk);
|
||||
put_blkdev:
|
||||
blkdev_put_no_open(bdev);
|
||||
+ if (ret == -ERESTARTSYS)
|
||||
+ goto retry;
|
||||
return ERR_PTR(ret);
|
||||
}
|
||||
EXPORT_SYMBOL(blkdev_get_by_dev);
|
@ -17,12 +17,13 @@ Fixes: ecc53c48c13d ("io-wq: check max_worker limits if a worker transitions bou
|
||||
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
||||
[backport]
|
||||
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
|
||||
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||
---
|
||||
fs/io-wq.c | 156 +++++++++++++++++++++++------------------------------
|
||||
1 file changed, 68 insertions(+), 88 deletions(-)
|
||||
fs/io-wq.c | 160 +++++++++++++++++++++++------------------------------
|
||||
1 file changed, 70 insertions(+), 90 deletions(-)
|
||||
|
||||
diff --git a/fs/io-wq.c b/fs/io-wq.c
|
||||
index 33678185f3bc..2496d8781ea1 100644
|
||||
index ba7aaf2b95d0..6710da3d4445 100644
|
||||
--- a/fs/io-wq.c
|
||||
+++ b/fs/io-wq.c
|
||||
@@ -34,7 +34,7 @@ enum {
|
||||
@ -34,7 +35,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
};
|
||||
|
||||
/*
|
||||
@@ -73,25 +73,24 @@ struct io_wqe_acct {
|
||||
@@ -73,26 +73,25 @@ struct io_wqe_acct {
|
||||
unsigned max_workers;
|
||||
int index;
|
||||
atomic_t nr_running;
|
||||
@ -57,14 +58,16 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
- struct io_wq_work_list work_list;
|
||||
- unsigned flags;
|
||||
- } ____cacheline_aligned_in_smp;
|
||||
-
|
||||
- int node;
|
||||
+ raw_spinlock_t lock;
|
||||
+ struct io_wqe_acct acct[2];
|
||||
|
||||
int node;
|
||||
- struct io_wqe_acct acct[2];
|
||||
struct io_wqe_acct acct[2];
|
||||
|
||||
+ int node;
|
||||
+
|
||||
struct hlist_nulls_head free_list;
|
||||
struct list_head all_list;
|
||||
|
||||
@@ -196,11 +195,10 @@ static void io_worker_exit(struct io_worker *worker)
|
||||
do_exit(0);
|
||||
}
|
||||
@ -140,8 +143,8 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -417,44 +401,23 @@ static void io_wait_on_hash(struct io_wqe *wqe, unsigned int hash)
|
||||
spin_unlock(&wq->hash->wait.lock);
|
||||
@@ -420,44 +404,23 @@ static bool io_wait_on_hash(struct io_wqe *wqe, unsigned int hash)
|
||||
return ret;
|
||||
}
|
||||
|
||||
-/*
|
||||
@ -189,7 +192,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
return work;
|
||||
}
|
||||
|
||||
@@ -465,7 +428,7 @@ static struct io_wq_work *io_get_next_work(struct io_wqe *wqe,
|
||||
@@ -468,7 +431,7 @@ static struct io_wq_work *io_get_next_work(struct io_wqe *wqe,
|
||||
/* hashed, can run if not already running */
|
||||
if (!test_and_set_bit(hash, &wqe->wq->hash->map)) {
|
||||
wqe->hash_tail[hash] = NULL;
|
||||
@ -198,16 +201,22 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
return work;
|
||||
}
|
||||
if (stall_hash == -1U)
|
||||
@@ -479,7 +442,7 @@ static struct io_wq_work *io_get_next_work(struct io_wqe *wqe,
|
||||
@@ -484,12 +447,12 @@ static struct io_wq_work *io_get_next_work(struct io_wqe *wqe,
|
||||
* Set this before dropping the lock to avoid racing with new
|
||||
* work being added and clearing the stalled bit.
|
||||
*/
|
||||
- wqe->flags |= IO_WQE_FLAG_STALLED;
|
||||
+ set_bit(IO_ACCT_STALLED_BIT, &acct->flags);
|
||||
raw_spin_unlock(&wqe->lock);
|
||||
io_wait_on_hash(wqe, stall_hash);
|
||||
unstalled = io_wait_on_hash(wqe, stall_hash);
|
||||
raw_spin_lock(&wqe->lock);
|
||||
@@ -516,6 +479,7 @@ static void io_wqe_enqueue(struct io_wqe *wqe, struct io_wq_work *work);
|
||||
if (unstalled) {
|
||||
- wqe->flags &= ~IO_WQE_FLAG_STALLED;
|
||||
+ clear_bit(IO_ACCT_STALLED_BIT, &acct->flags);
|
||||
if (wq_has_sleeper(&wqe->wq->hash->wait))
|
||||
wake_up(&wqe->wq->hash->wait);
|
||||
}
|
||||
@@ -526,6 +489,7 @@ static void io_wqe_enqueue(struct io_wqe *wqe, struct io_wq_work *work);
|
||||
static void io_worker_handle_work(struct io_worker *worker)
|
||||
__releases(wqe->lock)
|
||||
{
|
||||
@ -215,7 +224,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
struct io_wqe *wqe = worker->wqe;
|
||||
struct io_wq *wq = wqe->wq;
|
||||
bool do_kill = test_bit(IO_WQ_BIT_EXIT, &wq->state);
|
||||
@@ -530,7 +494,7 @@ static void io_worker_handle_work(struct io_worker *worker)
|
||||
@@ -540,7 +504,7 @@ static void io_worker_handle_work(struct io_worker *worker)
|
||||
* can't make progress, any work completion or insertion will
|
||||
* clear the stalled flag.
|
||||
*/
|
||||
@ -224,19 +233,16 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
if (work)
|
||||
__io_worker_busy(wqe, worker, work);
|
||||
|
||||
@@ -564,10 +528,10 @@ static void io_worker_handle_work(struct io_worker *worker)
|
||||
|
||||
if (hash != -1U && !next_hashed) {
|
||||
@@ -576,7 +540,7 @@ static void io_worker_handle_work(struct io_worker *worker)
|
||||
/* serialize hash clear with wake_up() */
|
||||
spin_lock_irq(&wq->hash->wait.lock);
|
||||
clear_bit(hash, &wq->hash->map);
|
||||
- wqe->flags &= ~IO_WQE_FLAG_STALLED;
|
||||
+ clear_bit(IO_ACCT_STALLED_BIT, &acct->flags);
|
||||
spin_unlock_irq(&wq->hash->wait.lock);
|
||||
if (wq_has_sleeper(&wq->hash->wait))
|
||||
wake_up(&wq->hash->wait);
|
||||
raw_spin_lock_irq(&wqe->lock);
|
||||
- wqe->flags &= ~IO_WQE_FLAG_STALLED;
|
||||
/* skip unnecessary unlock-lock wqe->lock */
|
||||
if (!work)
|
||||
goto get_next;
|
||||
@@ -582,6 +546,7 @@ static void io_worker_handle_work(struct io_worker *worker)
|
||||
@@ -595,6 +559,7 @@ static void io_worker_handle_work(struct io_worker *worker)
|
||||
static int io_wqe_worker(void *data)
|
||||
{
|
||||
struct io_worker *worker = data;
|
||||
@ -244,7 +250,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
struct io_wqe *wqe = worker->wqe;
|
||||
struct io_wq *wq = wqe->wq;
|
||||
char buf[TASK_COMM_LEN];
|
||||
@@ -597,7 +562,7 @@ static int io_wqe_worker(void *data)
|
||||
@@ -610,7 +575,7 @@ static int io_wqe_worker(void *data)
|
||||
set_current_state(TASK_INTERRUPTIBLE);
|
||||
loop:
|
||||
raw_spin_lock_irq(&wqe->lock);
|
||||
@ -253,7 +259,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
io_worker_handle_work(worker);
|
||||
goto loop;
|
||||
}
|
||||
@@ -623,7 +588,7 @@ static int io_wqe_worker(void *data)
|
||||
@@ -636,7 +601,7 @@ static int io_wqe_worker(void *data)
|
||||
|
||||
if (test_bit(IO_WQ_BIT_EXIT, &wq->state)) {
|
||||
raw_spin_lock_irq(&wqe->lock);
|
||||
@ -262,7 +268,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
io_worker_handle_work(worker);
|
||||
else
|
||||
raw_spin_unlock_irq(&wqe->lock);
|
||||
@@ -769,12 +734,13 @@ static void io_run_cancel(struct io_wq_work *work, struct io_wqe *wqe)
|
||||
@@ -782,12 +747,13 @@ static void io_run_cancel(struct io_wq_work *work, struct io_wqe *wqe)
|
||||
|
||||
static void io_wqe_insert_work(struct io_wqe *wqe, struct io_wq_work *work)
|
||||
{
|
||||
@ -277,7 +283,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -784,7 +750,7 @@ static void io_wqe_insert_work(struct io_wqe *wqe, struct io_wq_work *work)
|
||||
@@ -797,7 +763,7 @@ static void io_wqe_insert_work(struct io_wqe *wqe, struct io_wq_work *work)
|
||||
if (!tail)
|
||||
goto append;
|
||||
|
||||
@ -286,7 +292,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
}
|
||||
|
||||
static void io_wqe_enqueue(struct io_wqe *wqe, struct io_wq_work *work)
|
||||
@@ -806,10 +772,10 @@ static void io_wqe_enqueue(struct io_wqe *wqe, struct io_wq_work *work)
|
||||
@@ -819,10 +785,10 @@ static void io_wqe_enqueue(struct io_wqe *wqe, struct io_wq_work *work)
|
||||
|
||||
raw_spin_lock_irqsave(&wqe->lock, flags);
|
||||
io_wqe_insert_work(wqe, work);
|
||||
@ -299,7 +305,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
rcu_read_unlock();
|
||||
|
||||
raw_spin_unlock_irqrestore(&wqe->lock, flags);
|
||||
@@ -862,6 +828,7 @@ static inline void io_wqe_remove_pending(struct io_wqe *wqe,
|
||||
@@ -875,6 +841,7 @@ static inline void io_wqe_remove_pending(struct io_wqe *wqe,
|
||||
struct io_wq_work *work,
|
||||
struct io_wq_work_node *prev)
|
||||
{
|
||||
@ -307,7 +313,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
unsigned int hash = io_get_work_hash(work);
|
||||
struct io_wq_work *prev_work = NULL;
|
||||
|
||||
@@ -873,7 +840,7 @@ static inline void io_wqe_remove_pending(struct io_wqe *wqe,
|
||||
@@ -886,7 +853,7 @@ static inline void io_wqe_remove_pending(struct io_wqe *wqe,
|
||||
else
|
||||
wqe->hash_tail[hash] = NULL;
|
||||
}
|
||||
@ -316,7 +322,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
}
|
||||
|
||||
static void io_wqe_cancel_pending_work(struct io_wqe *wqe,
|
||||
@@ -882,22 +849,27 @@ static void io_wqe_cancel_pending_work(struct io_wqe *wqe,
|
||||
@@ -895,22 +862,27 @@ static void io_wqe_cancel_pending_work(struct io_wqe *wqe,
|
||||
struct io_wq_work_node *node, *prev;
|
||||
struct io_wq_work *work;
|
||||
unsigned long flags;
|
||||
@ -356,7 +362,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
}
|
||||
raw_spin_unlock_irqrestore(&wqe->lock, flags);
|
||||
}
|
||||
@@ -958,18 +930,24 @@ static int io_wqe_hash_wake(struct wait_queue_entry *wait, unsigned mode,
|
||||
@@ -971,18 +943,24 @@ static int io_wqe_hash_wake(struct wait_queue_entry *wait, unsigned mode,
|
||||
int sync, void *key)
|
||||
{
|
||||
struct io_wqe *wqe = container_of(wait, struct io_wqe, wait);
|
||||
@ -383,7 +389,7 @@ index 33678185f3bc..2496d8781ea1 100644
|
||||
struct io_wq *wq;
|
||||
|
||||
if (WARN_ON_ONCE(!data->free_work || !data->do_work))
|
||||
@@ -1006,18 +984,20 @@ struct io_wq *io_wq_create(unsigned bounded, struct io_wq_data *data)
|
||||
@@ -1019,18 +997,20 @@ struct io_wq *io_wq_create(unsigned bounded, struct io_wq_data *data)
|
||||
goto err;
|
||||
wq->wqes[node] = wqe;
|
||||
wqe->node = alloc_node;
|
@ -0,0 +1,28 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Fabian=20Gr=C3=BCnbichler?= <f.gruenbichler@proxmox.com>
|
||||
Date: Thu, 14 Sep 2017 11:09:58 +0200
|
||||
Subject: [PATCH] do not generate split BTF type info per default
|
||||
|
||||
This reverts commit a8ed1a0607cfa5478ff6009539f44790c4d0956d.
|
||||
|
||||
It breaks ZFS sometimes:
|
||||
https://github.com/openzfs/zfs/issues/12301#issuecomment-873303739
|
||||
|
||||
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||
---
|
||||
lib/Kconfig.debug | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
|
||||
index 25dc20175bba..7ff51a3f65e6 100644
|
||||
--- a/lib/Kconfig.debug
|
||||
+++ b/lib/Kconfig.debug
|
||||
@@ -314,7 +314,7 @@ config PAHOLE_HAS_SPLIT_BTF
|
||||
def_bool $(success, test `$(PAHOLE) --version | sed -E 's/v([0-9]+)\.([0-9]+)/\1\2/'` -ge "119")
|
||||
|
||||
config DEBUG_INFO_BTF_MODULES
|
||||
- def_bool y
|
||||
+ def_bool n
|
||||
depends on DEBUG_INFO_BTF && MODULES && PAHOLE_HAS_SPLIT_BTF
|
||||
help
|
||||
Generate compact split BTF type information for kernel modules.
|
@ -1,69 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jens Axboe <axboe@kernel.dk>
|
||||
Date: Tue, 31 Aug 2021 13:53:00 -0600
|
||||
Subject: [PATCH] io-wq: fix queue stalling race
|
||||
|
||||
We need to set the stalled bit early, before we drop the lock for adding
|
||||
us to the stall hash queue. If not, then we can race with new work being
|
||||
queued between adding us to the stall hash and io_worker_handle_work()
|
||||
marking us stalled.
|
||||
|
||||
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
||||
[backport]
|
||||
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
|
||||
---
|
||||
fs/io-wq.c | 15 +++++++--------
|
||||
1 file changed, 7 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/fs/io-wq.c b/fs/io-wq.c
|
||||
index 6612d0aa497e..33678185f3bc 100644
|
||||
--- a/fs/io-wq.c
|
||||
+++ b/fs/io-wq.c
|
||||
@@ -437,8 +437,7 @@ static bool io_worker_can_run_work(struct io_worker *worker,
|
||||
}
|
||||
|
||||
static struct io_wq_work *io_get_next_work(struct io_wqe *wqe,
|
||||
- struct io_worker *worker,
|
||||
- bool *stalled)
|
||||
+ struct io_worker *worker)
|
||||
__must_hold(wqe->lock)
|
||||
{
|
||||
struct io_wq_work_node *node, *prev;
|
||||
@@ -476,10 +475,14 @@ static struct io_wq_work *io_get_next_work(struct io_wqe *wqe,
|
||||
}
|
||||
|
||||
if (stall_hash != -1U) {
|
||||
+ /*
|
||||
+ * Set this before dropping the lock to avoid racing with new
|
||||
+ * work being added and clearing the stalled bit.
|
||||
+ */
|
||||
+ wqe->flags |= IO_WQE_FLAG_STALLED;
|
||||
raw_spin_unlock(&wqe->lock);
|
||||
io_wait_on_hash(wqe, stall_hash);
|
||||
raw_spin_lock(&wqe->lock);
|
||||
- *stalled = true;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
@@ -519,7 +522,6 @@ static void io_worker_handle_work(struct io_worker *worker)
|
||||
|
||||
do {
|
||||
struct io_wq_work *work;
|
||||
- bool stalled;
|
||||
get_next:
|
||||
/*
|
||||
* If we got some work, mark us as busy. If we didn't, but
|
||||
@@ -528,12 +530,9 @@ static void io_worker_handle_work(struct io_worker *worker)
|
||||
* can't make progress, any work completion or insertion will
|
||||
* clear the stalled flag.
|
||||
*/
|
||||
- stalled = false;
|
||||
- work = io_get_next_work(wqe, worker, &stalled);
|
||||
+ work = io_get_next_work(wqe, worker);
|
||||
if (work)
|
||||
__io_worker_busy(wqe, worker, work);
|
||||
- else if (stalled)
|
||||
- wqe->flags |= IO_WQE_FLAG_STALLED;
|
||||
|
||||
raw_spin_unlock_irq(&wqe->lock);
|
||||
if (!work)
|
@ -0,0 +1,90 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Paolo Bonzini <pbonzini@redhat.com>
|
||||
Date: Mon, 22 Nov 2021 19:43:09 -0500
|
||||
Subject: [PATCH] KVM: VMX: prepare sync_pir_to_irr for running with APICv
|
||||
disabled
|
||||
|
||||
If APICv is disabled for this vCPU, assigned devices may still attempt to
|
||||
post interrupts. In that case, we need to cancel the vmentry and deliver
|
||||
the interrupt with KVM_REQ_EVENT. Extend the existing code that handles
|
||||
injection of L1 interrupts into L2 to cover this case as well.
|
||||
|
||||
vmx_hwapic_irr_update is only called when APICv is active so it would be
|
||||
confusing to add a check for vcpu->arch.apicv_active in there. Instead,
|
||||
just use vmx_set_rvi directly in vmx_sync_pir_to_irr.
|
||||
|
||||
Cc: stable@vger.kernel.org
|
||||
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
|
||||
Reviewed-by: David Matlack <dmatlack@google.com>
|
||||
Reviewed-by: Sean Christopherson <seanjc@google.com>
|
||||
Message-Id: <20211123004311.2954158-3-pbonzini@redhat.com>
|
||||
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
||||
(cherry picked from commit 7e1901f6c86c896acff6609e0176f93f756d8b2a)
|
||||
[ T: reused WARN instead of newer KVM_BUG_ON for minimal change ]
|
||||
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||
---
|
||||
arch/x86/kvm/vmx/vmx.c | 39 +++++++++++++++++++++++++--------------
|
||||
1 file changed, 25 insertions(+), 14 deletions(-)
|
||||
|
||||
diff --git a/arch/x86/kvm/vmx/vmx.c b/arch/x86/kvm/vmx/vmx.c
|
||||
index fc6fbaba1cb5..2f6db087e243 100644
|
||||
--- a/arch/x86/kvm/vmx/vmx.c
|
||||
+++ b/arch/x86/kvm/vmx/vmx.c
|
||||
@@ -6331,9 +6331,9 @@ static int vmx_sync_pir_to_irr(struct kvm_vcpu *vcpu)
|
||||
{
|
||||
struct vcpu_vmx *vmx = to_vmx(vcpu);
|
||||
int max_irr;
|
||||
- bool max_irr_updated;
|
||||
+ bool got_posted_interrupt;
|
||||
|
||||
- WARN_ON(!vcpu->arch.apicv_active);
|
||||
+ WARN_ON(!enable_apicv);
|
||||
if (pi_test_on(&vmx->pi_desc)) {
|
||||
pi_clear_on(&vmx->pi_desc);
|
||||
/*
|
||||
@@ -6341,22 +6341,33 @@ static int vmx_sync_pir_to_irr(struct kvm_vcpu *vcpu)
|
||||
* But on x86 this is just a compiler barrier anyway.
|
||||
*/
|
||||
smp_mb__after_atomic();
|
||||
- max_irr_updated =
|
||||
+ got_posted_interrupt =
|
||||
kvm_apic_update_irr(vcpu, vmx->pi_desc.pir, &max_irr);
|
||||
-
|
||||
- /*
|
||||
- * If we are running L2 and L1 has a new pending interrupt
|
||||
- * which can be injected, this may cause a vmexit or it may
|
||||
- * be injected into L2. Either way, this interrupt will be
|
||||
- * processed via KVM_REQ_EVENT, not RVI, because we do not use
|
||||
- * virtual interrupt delivery to inject L1 interrupts into L2.
|
||||
- */
|
||||
- if (is_guest_mode(vcpu) && max_irr_updated)
|
||||
- kvm_make_request(KVM_REQ_EVENT, vcpu);
|
||||
} else {
|
||||
max_irr = kvm_lapic_find_highest_irr(vcpu);
|
||||
+ got_posted_interrupt = false;
|
||||
}
|
||||
- vmx_hwapic_irr_update(vcpu, max_irr);
|
||||
+
|
||||
+ /*
|
||||
+ * Newly recognized interrupts are injected via either virtual interrupt
|
||||
+ * delivery (RVI) or KVM_REQ_EVENT. Virtual interrupt delivery is
|
||||
+ * disabled in two cases:
|
||||
+ *
|
||||
+ * 1) If L2 is running and the vCPU has a new pending interrupt. If L1
|
||||
+ * wants to exit on interrupts, KVM_REQ_EVENT is needed to synthesize a
|
||||
+ * VM-Exit to L1. If L1 doesn't want to exit, the interrupt is injected
|
||||
+ * into L2, but KVM doesn't use virtual interrupt delivery to inject
|
||||
+ * interrupts into L2, and so KVM_REQ_EVENT is again needed.
|
||||
+ *
|
||||
+ * 2) If APICv is disabled for this vCPU, assigned devices may still
|
||||
+ * attempt to post interrupts. The posted interrupt vector will cause
|
||||
+ * a VM-Exit and the subsequent entry will call sync_pir_to_irr.
|
||||
+ */
|
||||
+ if (!is_guest_mode(vcpu) && kvm_vcpu_apicv_active(vcpu))
|
||||
+ vmx_set_rvi(max_irr);
|
||||
+ else if (got_posted_interrupt)
|
||||
+ kvm_make_request(KVM_REQ_EVENT, vcpu);
|
||||
+
|
||||
return max_irr;
|
||||
}
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit b188ba567fc92eebd36f679de7ba1b8c2354839d
|
||||
Subproject commit 168d1231d9f29e3331fa0bbed876ffdd148143b8
|
@ -1 +1 @@
|
||||
Subproject commit 0ee31a51f6eaa0466b3e4d67f829a4469dc4d466
|
||||
Subproject commit 531eac33046f7e207226b428e399bcab173b7b6b
|
Loading…
Reference in New Issue
Block a user