]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.4-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Feb 2021 09:08:43 +0000 (10:08 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Feb 2021 09:08:43 +0000 (10:08 +0100)
added patches:
igb-remove-incorrect-unexpected-sys-wrap-log-message.patch
ntfs-check-for-valid-standard-information-attribute.patch

queue-4.4/igb-remove-incorrect-unexpected-sys-wrap-log-message.patch [new file with mode: 0644]
queue-4.4/ntfs-check-for-valid-standard-information-attribute.patch [new file with mode: 0644]
queue-4.4/series

diff --git a/queue-4.4/igb-remove-incorrect-unexpected-sys-wrap-log-message.patch b/queue-4.4/igb-remove-incorrect-unexpected-sys-wrap-log-message.patch
new file mode 100644 (file)
index 0000000..6506232
--- /dev/null
@@ -0,0 +1,44 @@
+From 2643e6e90210e16c978919617170089b7c2164f7 Mon Sep 17 00:00:00 2001
+From: Corinna Vinschen <vinschen@redhat.com>
+Date: Fri, 23 Jun 2017 14:26:30 +0200
+Subject: igb: Remove incorrect "unexpected SYS WRAP" log message
+
+From: Corinna Vinschen <vinschen@redhat.com>
+
+commit 2643e6e90210e16c978919617170089b7c2164f7 upstream.
+
+TSAUXC.DisableSystime is never set, so SYSTIM runs into a SYS WRAP
+every 1100 secs on 80580/i350/i354 (40 bit SYSTIM) and every 35000
+secs on 80576 (45 bit SYSTIM).
+
+This wrap event sets the TSICR.SysWrap bit unconditionally.
+
+However, checking TSIM at interrupt time shows that this event does not
+actually cause the interrupt.  Rather, it's just bycatch while the
+actual interrupt is caused by, for instance, TSICR.TXTS.
+
+The conclusion is that the SYS WRAP is actually expected, so the
+"unexpected SYS WRAP" message is entirely bogus and just helps to
+confuse users.  Drop it.
+
+Signed-off-by: Corinna Vinschen <vinschen@redhat.com>
+Acked-by: Jacob Keller <jacob.e.keller@intel.com>
+Tested-by: Aaron Brown <aaron.f.brown@intel.com>
+Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
+Cc: Punit Agrawal <punit1.agrawal@toshiba.co.jp>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/net/ethernet/intel/igb/igb_main.c |    2 --
+ 1 file changed, 2 deletions(-)
+
+--- a/drivers/net/ethernet/intel/igb/igb_main.c
++++ b/drivers/net/ethernet/intel/igb/igb_main.c
+@@ -5421,8 +5421,6 @@ static void igb_tsync_interrupt(struct i
+               event.type = PTP_CLOCK_PPS;
+               if (adapter->ptp_caps.pps)
+                       ptp_clock_event(adapter->ptp_clock, &event);
+-              else
+-                      dev_err(&adapter->pdev->dev, "unexpected SYS WRAP");
+               ack |= TSINTR_SYS_WRAP;
+       }
diff --git a/queue-4.4/ntfs-check-for-valid-standard-information-attribute.patch b/queue-4.4/ntfs-check-for-valid-standard-information-attribute.patch
new file mode 100644 (file)
index 0000000..48d7323
--- /dev/null
@@ -0,0 +1,43 @@
+From 4dfe6bd94959222e18d512bdf15f6bf9edb9c27c Mon Sep 17 00:00:00 2001
+From: Rustam Kovhaev <rkovhaev@gmail.com>
+Date: Wed, 24 Feb 2021 12:00:30 -0800
+Subject: ntfs: check for valid standard information attribute
+
+From: Rustam Kovhaev <rkovhaev@gmail.com>
+
+commit 4dfe6bd94959222e18d512bdf15f6bf9edb9c27c upstream.
+
+Mounting a corrupted filesystem with NTFS resulted in a kernel crash.
+
+We should check for valid STANDARD_INFORMATION attribute offset and length
+before trying to access it
+
+Link: https://lkml.kernel.org/r/20210217155930.1506815-1-rkovhaev@gmail.com
+Link: https://syzkaller.appspot.com/bug?extid=c584225dabdea2f71969
+Signed-off-by: Rustam Kovhaev <rkovhaev@gmail.com>
+Reported-by: syzbot+c584225dabdea2f71969@syzkaller.appspotmail.com
+Tested-by: syzbot+c584225dabdea2f71969@syzkaller.appspotmail.com
+Acked-by: Anton Altaparmakov <anton@tuxera.com>
+Cc: <stable@vger.kernel.org>
+Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ fs/ntfs/inode.c |    6 ++++++
+ 1 file changed, 6 insertions(+)
+
+--- a/fs/ntfs/inode.c
++++ b/fs/ntfs/inode.c
+@@ -661,6 +661,12 @@ static int ntfs_read_locked_inode(struct
+       }
+       a = ctx->attr;
+       /* Get the standard information attribute value. */
++      if ((u8 *)a + le16_to_cpu(a->data.resident.value_offset)
++                      + le32_to_cpu(a->data.resident.value_length) >
++                      (u8 *)ctx->mrec + vol->mft_record_size) {
++              ntfs_error(vi->i_sb, "Corrupt standard information attribute in inode.");
++              goto unm_err_out;
++      }
+       si = (STANDARD_INFORMATION*)((u8*)a +
+                       le16_to_cpu(a->data.resident.value_offset));
index b42cd493b12b162ba0fb8c7625cba50f5c93afbd..f2b6af0ba3b44348f0f66f1824fa8f639f7d905a 100644 (file)
@@ -1,3 +1,5 @@
 hid-make-arrays-usage-and-value-to-be-the-same.patch
 usb-quirks-add-quirk-to-start-video-capture-on-elmo-l-12f-document-camera-reliable.patch
 xen-netback-delete-napi-instance-when-queue-fails-to-initialize.patch
+ntfs-check-for-valid-standard-information-attribute.patch
+igb-remove-incorrect-unexpected-sys-wrap-log-message.patch