From: Greg Kroah-Hartman Date: Mon, 15 Apr 2019 16:55:26 +0000 (+0200) Subject: drop broken dm patch from 3.18, 4.4, and 4.9 queues. X-Git-Tag: v4.9.169~7 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1731884f1fecaa077408e1e6375d6829b1a8856d;p=thirdparty%2Fkernel%2Fstable-queue.git drop broken dm patch from 3.18, 4.4, and 4.9 queues. --- diff --git a/queue-3.18/dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch b/queue-3.18/dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch deleted file mode 100644 index ac765ab342e..00000000000 --- a/queue-3.18/dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch +++ /dev/null @@ -1,80 +0,0 @@ -From eb40c0acdc342b815d4d03ae6abb09e80c0f2988 Mon Sep 17 00:00:00 2001 -From: Ilya Dryomov -Date: Tue, 26 Mar 2019 20:20:58 +0100 -Subject: dm table: propagate BDI_CAP_STABLE_WRITES to fix sporadic checksum errors - -From: Ilya Dryomov - -commit eb40c0acdc342b815d4d03ae6abb09e80c0f2988 upstream. - -Some devices don't use blk_integrity but still want stable pages -because they do their own checksumming. Examples include rbd and iSCSI -when data digests are negotiated. Stacking DM (and thus LVM) on top of -these devices results in sporadic checksum errors. - -Set BDI_CAP_STABLE_WRITES if any underlying device has it set. - -Cc: stable@vger.kernel.org -Signed-off-by: Ilya Dryomov -Signed-off-by: Mike Snitzer -Signed-off-by: Greg Kroah-Hartman - ---- - drivers/md/dm-table.c | 39 +++++++++++++++++++++++++++++++++++++++ - 1 file changed, 39 insertions(+) - ---- a/drivers/md/dm-table.c -+++ b/drivers/md/dm-table.c -@@ -1435,6 +1435,36 @@ static bool dm_table_supports_discards(s - return 0; - } - -+static int device_requires_stable_pages(struct dm_target *ti, -+ struct dm_dev *dev, sector_t start, -+ sector_t len, void *data) -+{ -+ struct request_queue *q = bdev_get_queue(dev->bdev); -+ -+ return q && bdi_cap_stable_pages_required(q->backing_dev_info); -+} -+ -+/* -+ * If any underlying device requires stable pages, a table must require -+ * them as well. Only targets that support iterate_devices are considered: -+ * don't want error, zero, etc to require stable pages. -+ */ -+static bool dm_table_requires_stable_pages(struct dm_table *t) -+{ -+ struct dm_target *ti; -+ unsigned i; -+ -+ for (i = 0; i < dm_table_get_num_targets(t); i++) { -+ ti = dm_table_get_target(t, i); -+ -+ if (ti->type->iterate_devices && -+ ti->type->iterate_devices(ti, device_requires_stable_pages, NULL)) -+ return true; -+ } -+ -+ return false; -+} -+ - void dm_table_set_restrictions(struct dm_table *t, struct request_queue *q, - struct queue_limits *limits) - { -@@ -1486,6 +1516,15 @@ void dm_table_set_restrictions(struct dm - queue_flag_clear_unlocked(QUEUE_FLAG_ADD_RANDOM, q); - - /* -+ * Some devices don't use blk_integrity but still want stable pages -+ * because they do their own checksumming. -+ */ -+ if (dm_table_requires_stable_pages(t)) -+ q->backing_dev_info->capabilities |= BDI_CAP_STABLE_WRITES; -+ else -+ q->backing_dev_info->capabilities &= ~BDI_CAP_STABLE_WRITES; -+ -+ /* - * QUEUE_FLAG_STACKABLE must be set after all queue settings are - * visible to other CPUs because, once the flag is set, incoming bios - * are processed by request-based dm, which refers to the queue diff --git a/queue-3.18/series b/queue-3.18/series index 359aaa4702c..1f69af5afae 100644 --- a/queue-3.18/series +++ b/queue-3.18/series @@ -57,4 +57,3 @@ xen-prevent-buffer-overflow-in-privcmd-ioctl.patch sched-fair-do-not-re-read-h_load_next-during-hierarchical-load-calculation.patch xtensa-fix-return_address.patch pci-add-function-1-dma-alias-quirk-for-marvell-9170-sata-controller.patch -dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch diff --git a/queue-4.4/dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch b/queue-4.4/dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch deleted file mode 100644 index 6b7ee076614..00000000000 --- a/queue-4.4/dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch +++ /dev/null @@ -1,80 +0,0 @@ -From eb40c0acdc342b815d4d03ae6abb09e80c0f2988 Mon Sep 17 00:00:00 2001 -From: Ilya Dryomov -Date: Tue, 26 Mar 2019 20:20:58 +0100 -Subject: dm table: propagate BDI_CAP_STABLE_WRITES to fix sporadic checksum errors - -From: Ilya Dryomov - -commit eb40c0acdc342b815d4d03ae6abb09e80c0f2988 upstream. - -Some devices don't use blk_integrity but still want stable pages -because they do their own checksumming. Examples include rbd and iSCSI -when data digests are negotiated. Stacking DM (and thus LVM) on top of -these devices results in sporadic checksum errors. - -Set BDI_CAP_STABLE_WRITES if any underlying device has it set. - -Cc: stable@vger.kernel.org -Signed-off-by: Ilya Dryomov -Signed-off-by: Mike Snitzer -Signed-off-by: Greg Kroah-Hartman - ---- - drivers/md/dm-table.c | 39 +++++++++++++++++++++++++++++++++++++++ - 1 file changed, 39 insertions(+) - ---- a/drivers/md/dm-table.c -+++ b/drivers/md/dm-table.c -@@ -1479,6 +1479,36 @@ static bool dm_table_supports_discards(s - return false; - } - -+static int device_requires_stable_pages(struct dm_target *ti, -+ struct dm_dev *dev, sector_t start, -+ sector_t len, void *data) -+{ -+ struct request_queue *q = bdev_get_queue(dev->bdev); -+ -+ return q && bdi_cap_stable_pages_required(q->backing_dev_info); -+} -+ -+/* -+ * If any underlying device requires stable pages, a table must require -+ * them as well. Only targets that support iterate_devices are considered: -+ * don't want error, zero, etc to require stable pages. -+ */ -+static bool dm_table_requires_stable_pages(struct dm_table *t) -+{ -+ struct dm_target *ti; -+ unsigned i; -+ -+ for (i = 0; i < dm_table_get_num_targets(t); i++) { -+ ti = dm_table_get_target(t, i); -+ -+ if (ti->type->iterate_devices && -+ ti->type->iterate_devices(ti, device_requires_stable_pages, NULL)) -+ return true; -+ } -+ -+ return false; -+} -+ - void dm_table_set_restrictions(struct dm_table *t, struct request_queue *q, - struct queue_limits *limits) - { -@@ -1521,6 +1551,15 @@ void dm_table_set_restrictions(struct dm - dm_table_verify_integrity(t); - - /* -+ * Some devices don't use blk_integrity but still want stable pages -+ * because they do their own checksumming. -+ */ -+ if (dm_table_requires_stable_pages(t)) -+ q->backing_dev_info->capabilities |= BDI_CAP_STABLE_WRITES; -+ else -+ q->backing_dev_info->capabilities &= ~BDI_CAP_STABLE_WRITES; -+ -+ /* - * Determine whether or not this queue's I/O timings contribute - * to the entropy pool, Only request-based targets use this. - * Clear QUEUE_FLAG_ADD_RANDOM if any underlying device does not diff --git a/queue-4.4/series b/queue-4.4/series index b6f3c54034d..ee6d2476aee 100644 --- a/queue-4.4/series +++ b/queue-4.4/series @@ -95,4 +95,3 @@ xen-prevent-buffer-overflow-in-privcmd-ioctl.patch sched-fair-do-not-re-read-h_load_next-during-hierarchical-load-calculation.patch xtensa-fix-return_address.patch pci-add-function-1-dma-alias-quirk-for-marvell-9170-sata-controller.patch -dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch diff --git a/queue-4.9/dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch b/queue-4.9/dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch deleted file mode 100644 index ab0fd9d2d76..00000000000 --- a/queue-4.9/dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch +++ /dev/null @@ -1,80 +0,0 @@ -From eb40c0acdc342b815d4d03ae6abb09e80c0f2988 Mon Sep 17 00:00:00 2001 -From: Ilya Dryomov -Date: Tue, 26 Mar 2019 20:20:58 +0100 -Subject: dm table: propagate BDI_CAP_STABLE_WRITES to fix sporadic checksum errors - -From: Ilya Dryomov - -commit eb40c0acdc342b815d4d03ae6abb09e80c0f2988 upstream. - -Some devices don't use blk_integrity but still want stable pages -because they do their own checksumming. Examples include rbd and iSCSI -when data digests are negotiated. Stacking DM (and thus LVM) on top of -these devices results in sporadic checksum errors. - -Set BDI_CAP_STABLE_WRITES if any underlying device has it set. - -Cc: stable@vger.kernel.org -Signed-off-by: Ilya Dryomov -Signed-off-by: Mike Snitzer -Signed-off-by: Greg Kroah-Hartman - ---- - drivers/md/dm-table.c | 39 +++++++++++++++++++++++++++++++++++++++ - 1 file changed, 39 insertions(+) - ---- a/drivers/md/dm-table.c -+++ b/drivers/md/dm-table.c -@@ -1575,6 +1575,36 @@ static bool dm_table_supports_discards(s - return false; - } - -+static int device_requires_stable_pages(struct dm_target *ti, -+ struct dm_dev *dev, sector_t start, -+ sector_t len, void *data) -+{ -+ struct request_queue *q = bdev_get_queue(dev->bdev); -+ -+ return q && bdi_cap_stable_pages_required(q->backing_dev_info); -+} -+ -+/* -+ * If any underlying device requires stable pages, a table must require -+ * them as well. Only targets that support iterate_devices are considered: -+ * don't want error, zero, etc to require stable pages. -+ */ -+static bool dm_table_requires_stable_pages(struct dm_table *t) -+{ -+ struct dm_target *ti; -+ unsigned i; -+ -+ for (i = 0; i < dm_table_get_num_targets(t); i++) { -+ ti = dm_table_get_target(t, i); -+ -+ if (ti->type->iterate_devices && -+ ti->type->iterate_devices(ti, device_requires_stable_pages, NULL)) -+ return true; -+ } -+ -+ return false; -+} -+ - void dm_table_set_restrictions(struct dm_table *t, struct request_queue *q, - struct queue_limits *limits) - { -@@ -1617,6 +1647,15 @@ void dm_table_set_restrictions(struct dm - dm_table_verify_integrity(t); - - /* -+ * Some devices don't use blk_integrity but still want stable pages -+ * because they do their own checksumming. -+ */ -+ if (dm_table_requires_stable_pages(t)) -+ q->backing_dev_info->capabilities |= BDI_CAP_STABLE_WRITES; -+ else -+ q->backing_dev_info->capabilities &= ~BDI_CAP_STABLE_WRITES; -+ -+ /* - * Determine whether or not this queue's I/O timings contribute - * to the entropy pool, Only request-based targets use this. - * Clear QUEUE_FLAG_ADD_RANDOM if any underlying device does not diff --git a/queue-4.9/series b/queue-4.9/series index fdc60f4a968..77e5175467a 100644 --- a/queue-4.9/series +++ b/queue-4.9/series @@ -74,4 +74,3 @@ xen-prevent-buffer-overflow-in-privcmd-ioctl.patch sched-fair-do-not-re-read-h_load_next-during-hierarchical-load-calculation.patch xtensa-fix-return_address.patch pci-add-function-1-dma-alias-quirk-for-marvell-9170-sata-controller.patch -dm-table-propagate-bdi_cap_stable_writes-to-fix-sporadic-checksum-errors.patch