]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
5.15-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 26 Apr 2022 06:44:10 +0000 (08:44 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 26 Apr 2022 06:44:10 +0000 (08:44 +0200)
added patches:
arm64-dts-qcom-add-ipa-qcom-qmp-property.patch
block-compat_ioctl-fix-range-check-in-blkgetsize.patch

queue-5.15/arm64-dts-qcom-add-ipa-qcom-qmp-property.patch [new file with mode: 0644]
queue-5.15/block-compat_ioctl-fix-range-check-in-blkgetsize.patch [new file with mode: 0644]
queue-5.15/series

diff --git a/queue-5.15/arm64-dts-qcom-add-ipa-qcom-qmp-property.patch b/queue-5.15/arm64-dts-qcom-add-ipa-qcom-qmp-property.patch
new file mode 100644 (file)
index 0000000..14e7606
--- /dev/null
@@ -0,0 +1,56 @@
+From 73419e4d2fd1b838fcb1df6a978d67b3ae1c5c01 Mon Sep 17 00:00:00 2001
+From: Alex Elder <elder@linaro.org>
+Date: Tue, 1 Feb 2022 08:07:23 -0600
+Subject: arm64: dts: qcom: add IPA qcom,qmp property
+
+From: Alex Elder <elder@linaro.org>
+
+commit 73419e4d2fd1b838fcb1df6a978d67b3ae1c5c01 upstream.
+
+At least three platforms require the "qcom,qmp" property to be
+specified, so the IPA driver can request register retention across
+power collapse.  Update DTS files accordingly.
+
+Signed-off-by: Alex Elder <elder@linaro.org>
+Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
+Link: https://lore.kernel.org/r/20220201140723.467431-1-elder@linaro.org
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ arch/arm64/boot/dts/qcom/sc7180.dtsi |    2 ++
+ arch/arm64/boot/dts/qcom/sc7280.dtsi |    2 ++
+ arch/arm64/boot/dts/qcom/sm8350.dtsi |    2 ++
+ 3 files changed, 6 insertions(+)
+
+--- a/arch/arm64/boot/dts/qcom/sc7180.dtsi
++++ b/arch/arm64/boot/dts/qcom/sc7180.dtsi
+@@ -1460,6 +1460,8 @@
+                                            "imem",
+                                            "config";
++                      qcom,qmp = <&aoss_qmp>;
++
+                       qcom,smem-states = <&ipa_smp2p_out 0>,
+                                          <&ipa_smp2p_out 1>;
+                       qcom,smem-state-names = "ipa-clock-enabled-valid",
+--- a/arch/arm64/boot/dts/qcom/sc7280.dtsi
++++ b/arch/arm64/boot/dts/qcom/sc7280.dtsi
+@@ -615,6 +615,8 @@
+                       interconnect-names = "memory",
+                                            "config";
++                      qcom,qmp = <&aoss_qmp>;
++
+                       qcom,smem-states = <&ipa_smp2p_out 0>,
+                                          <&ipa_smp2p_out 1>;
+                       qcom,smem-state-names = "ipa-clock-enabled-valid",
+--- a/arch/arm64/boot/dts/qcom/sm8350.dtsi
++++ b/arch/arm64/boot/dts/qcom/sm8350.dtsi
+@@ -736,6 +736,8 @@
+                       interconnect-names = "memory",
+                                            "config";
++                      qcom,qmp = <&aoss_qmp>;
++
+                       qcom,smem-states = <&ipa_smp2p_out 0>,
+                                          <&ipa_smp2p_out 1>;
+                       qcom,smem-state-names = "ipa-clock-enabled-valid",
diff --git a/queue-5.15/block-compat_ioctl-fix-range-check-in-blkgetsize.patch b/queue-5.15/block-compat_ioctl-fix-range-check-in-blkgetsize.patch
new file mode 100644 (file)
index 0000000..f60638c
--- /dev/null
@@ -0,0 +1,36 @@
+From ccf16413e520164eb718cf8b22a30438da80ff23 Mon Sep 17 00:00:00 2001
+From: Khazhismel Kumykov <khazhy@google.com>
+Date: Thu, 14 Apr 2022 15:40:56 -0700
+Subject: block/compat_ioctl: fix range check in BLKGETSIZE
+
+From: Khazhismel Kumykov <khazhy@google.com>
+
+commit ccf16413e520164eb718cf8b22a30438da80ff23 upstream.
+
+kernel ulong and compat_ulong_t may not be same width. Use type directly
+to eliminate mismatches.
+
+This would result in truncation rather than EFBIG for 32bit mode for
+large disks.
+
+Reviewed-by: Bart Van Assche <bvanassche@acm.org>
+Signed-off-by: Khazhismel Kumykov <khazhy@google.com>
+Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
+Link: https://lore.kernel.org/r/20220414224056.2875681-1-khazhy@google.com
+Signed-off-by: Jens Axboe <axboe@kernel.dk>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ block/ioctl.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/block/ioctl.c
++++ b/block/ioctl.c
+@@ -645,7 +645,7 @@ long compat_blkdev_ioctl(struct file *fi
+                       (bdev->bd_disk->bdi->ra_pages * PAGE_SIZE) / 512);
+       case BLKGETSIZE:
+               size = i_size_read(bdev->bd_inode);
+-              if ((size >> 9) > ~0UL)
++              if ((size >> 9) > ~(compat_ulong_t)0)
+                       return -EFBIG;
+               return compat_put_ulong(argp, size >> 9);
index 856abe6e96b87c8f73f1906eb458632a05569809..c5fb958198c4b0102705aa1a4a413f7a15646f43 100644 (file)
@@ -120,3 +120,5 @@ ext4-force-overhead-calculation-if-the-s_overhead_cluster-makes-no-sense.patch
 netfilter-nft_ct-fix-use-after-free-when-attaching-zone-template.patch
 jbd2-fix-a-potential-race-while-discarding-reserved-buffers-after-an-abort.patch
 spi-atmel-quadspi-fix-the-buswidth-adjustment-between-spi-mem-and-controller.patch
+block-compat_ioctl-fix-range-check-in-blkgetsize.patch
+arm64-dts-qcom-add-ipa-qcom-qmp-property.patch