]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
drop libata patch from 4.10 and 4.9 trees
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 18 May 2017 07:59:52 +0000 (09:59 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 18 May 2017 07:59:52 +0000 (09:59 +0200)
queue-4.10/libata-reject-passthrough-write-same-requests.patch [deleted file]
queue-4.10/series
queue-4.9/libata-reject-passthrough-write-same-requests.patch [deleted file]
queue-4.9/series

diff --git a/queue-4.10/libata-reject-passthrough-write-same-requests.patch b/queue-4.10/libata-reject-passthrough-write-same-requests.patch
deleted file mode 100644 (file)
index c374b54..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-From c6ade20f5e50e188d20b711a618b20dd1d50457e Mon Sep 17 00:00:00 2001
-From: Christoph Hellwig <hch@lst.de>
-Date: Tue, 25 Apr 2017 13:39:54 +0200
-Subject: libata: reject passthrough WRITE SAME requests
-
-From: Christoph Hellwig <hch@lst.de>
-
-commit c6ade20f5e50e188d20b711a618b20dd1d50457e upstream.
-
-The WRITE SAME to TRIM translation rewrites the DATA OUT buffer.  While
-the SCSI code accomodates for this by passing a read-writable buffer
-userspace applications don't cater for this behavior.  In fact it can
-be used to rewrite e.g. a readonly file through mmap and should be
-considered as a security fix.
-
-Signed-off-by: Christoph Hellwig <hch@lst.de>
-Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
-Signed-off-by: Tejun Heo <tj@kernel.org>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
----
- drivers/ata/libata-scsi.c |    8 ++++++++
- 1 file changed, 8 insertions(+)
-
---- a/drivers/ata/libata-scsi.c
-+++ b/drivers/ata/libata-scsi.c
-@@ -3487,6 +3487,14 @@ static unsigned int ata_scsi_write_same_
-       if (unlikely(!dev->dma_mode))
-               goto invalid_opcode;
-+      /*
-+       * We only allow sending this command through the block layer,
-+       * as it modifies the DATA OUT buffer, which would corrupt user
-+       * memory for SG_IO commands.
-+       */
-+      if (unlikely(blk_rq_is_passthrough(scmd->request)))
-+              goto invalid_opcode;
-+
-       if (unlikely(scmd->cmd_len < 16)) {
-               fp = 15;
-               goto invalid_fld;
index 31b1066f9d70b10715e26e3680a336d31326ad52..cee62ed19238276d6b2ce889288691e3b18fbfad 100644 (file)
@@ -84,4 +84,3 @@ tty-pty-fix-ldisc-flush-after-userspace-become-aware-of-the-data-already.patch
 bluetooth-fix-user-channel-for-32bit-userspace-on-64bit-kernel.patch
 bluetooth-hci_bcm-add-missing-tty-device-sanity-check.patch
 bluetooth-hci_intel-add-missing-tty-device-sanity-check.patch
-libata-reject-passthrough-write-same-requests.patch
diff --git a/queue-4.9/libata-reject-passthrough-write-same-requests.patch b/queue-4.9/libata-reject-passthrough-write-same-requests.patch
deleted file mode 100644 (file)
index 39aab83..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-From c6ade20f5e50e188d20b711a618b20dd1d50457e Mon Sep 17 00:00:00 2001
-From: Christoph Hellwig <hch@lst.de>
-Date: Tue, 25 Apr 2017 13:39:54 +0200
-Subject: libata: reject passthrough WRITE SAME requests
-
-From: Christoph Hellwig <hch@lst.de>
-
-commit c6ade20f5e50e188d20b711a618b20dd1d50457e upstream.
-
-The WRITE SAME to TRIM translation rewrites the DATA OUT buffer.  While
-the SCSI code accomodates for this by passing a read-writable buffer
-userspace applications don't cater for this behavior.  In fact it can
-be used to rewrite e.g. a readonly file through mmap and should be
-considered as a security fix.
-
-Signed-off-by: Christoph Hellwig <hch@lst.de>
-Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
-Signed-off-by: Tejun Heo <tj@kernel.org>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
----
- drivers/ata/libata-scsi.c |    8 ++++++++
- 1 file changed, 8 insertions(+)
-
---- a/drivers/ata/libata-scsi.c
-+++ b/drivers/ata/libata-scsi.c
-@@ -3405,6 +3405,14 @@ static unsigned int ata_scsi_write_same_
-       if (unlikely(!dev->dma_mode))
-               goto invalid_opcode;
-+      /*
-+       * We only allow sending this command through the block layer,
-+       * as it modifies the DATA OUT buffer, which would corrupt user
-+       * memory for SG_IO commands.
-+       */
-+      if (unlikely(blk_rq_is_passthrough(scmd->request)))
-+              goto invalid_opcode;
-+
-       if (unlikely(scmd->cmd_len < 16)) {
-               fp = 15;
-               goto invalid_fld;
index 8c7eb061eee5f885b56a81ff85d31a2513530b7b..196f06fc7854451dfb8895c499fe384229c24412 100644 (file)
@@ -72,4 +72,3 @@ tty-pty-fix-ldisc-flush-after-userspace-become-aware-of-the-data-already.patch
 bluetooth-fix-user-channel-for-32bit-userspace-on-64bit-kernel.patch
 bluetooth-hci_bcm-add-missing-tty-device-sanity-check.patch
 bluetooth-hci_intel-add-missing-tty-device-sanity-check.patch
-libata-reject-passthrough-write-same-requests.patch