]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
5.10-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 27 Nov 2023 12:43:06 +0000 (12:43 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 27 Nov 2023 12:43:06 +0000 (12:43 +0000)
added patches:
interconnect-qcom-add-support-for-mask-based-bcms.patch

queue-5.10/interconnect-qcom-add-support-for-mask-based-bcms.patch [new file with mode: 0644]
queue-5.10/s390-ap-fix-ap-bus-crash-on-early-config-change-callback-invocation.patch [deleted file]
queue-5.10/series

diff --git a/queue-5.10/interconnect-qcom-add-support-for-mask-based-bcms.patch b/queue-5.10/interconnect-qcom-add-support-for-mask-based-bcms.patch
new file mode 100644 (file)
index 0000000..dbfb556
--- /dev/null
@@ -0,0 +1,61 @@
+From d8630f050d3fd2079f8617dd6c00c6509109c755 Mon Sep 17 00:00:00 2001
+From: Mike Tipton <mdtipton@codeaurora.org>
+Date: Fri, 23 Jun 2023 14:50:42 +0200
+Subject: interconnect: qcom: Add support for mask-based BCMs
+
+From: Mike Tipton <mdtipton@codeaurora.org>
+
+commit d8630f050d3fd2079f8617dd6c00c6509109c755 upstream.
+
+Some BCMs aren't directly associated with the data path (i.e. ACV) and
+therefore don't communicate using BW. Instead, they are simply
+enabled/disabled with a simple bit mask. Add support for these.
+
+Origin commit retrieved from:
+https://git.codelinaro.org/clo/la/kernel/msm-5.15/-/commit/2d1573e0206998151b342e6b52a4c0f7234d7e36
+
+Signed-off-by: Mike Tipton <mdtipton@codeaurora.org>
+[narmstrong: removed copyright change from original commit]
+Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
+Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
+Link: https://lore.kernel.org/r/20230619-topic-sm8550-upstream-interconnect-mask-vote-v2-1-709474b151cc@linaro.org
+Fixes: fafc114a468e ("interconnect: qcom: Add SM8450 interconnect provider driver")
+Signed-off-by: Georgi Djakov <djakov@kernel.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/interconnect/qcom/bcm-voter.c |    5 +++++
+ drivers/interconnect/qcom/icc-rpmh.h  |    2 ++
+ 2 files changed, 7 insertions(+)
+
+--- a/drivers/interconnect/qcom/bcm-voter.c
++++ b/drivers/interconnect/qcom/bcm-voter.c
+@@ -90,6 +90,11 @@ static void bcm_aggregate(struct qcom_ic
+               temp = agg_peak[bucket] * bcm->vote_scale;
+               bcm->vote_y[bucket] = bcm_div(temp, bcm->aux_data.unit);
++
++              if (bcm->enable_mask && (bcm->vote_x[bucket] || bcm->vote_y[bucket])) {
++                      bcm->vote_x[bucket] = 0;
++                      bcm->vote_y[bucket] = bcm->enable_mask;
++              }
+       }
+       if (bcm->keepalive && bcm->vote_x[QCOM_ICC_BUCKET_AMC] == 0 &&
+--- a/drivers/interconnect/qcom/icc-rpmh.h
++++ b/drivers/interconnect/qcom/icc-rpmh.h
+@@ -81,6 +81,7 @@ struct qcom_icc_node {
+  * @vote_x: aggregated threshold values, represents sum_bw when @type is bw bcm
+  * @vote_y: aggregated threshold values, represents peak_bw when @type is bw bcm
+  * @vote_scale: scaling factor for vote_x and vote_y
++ * @enable_mask: optional mask to send as vote instead of vote_x/vote_y
+  * @dirty: flag used to indicate whether the bcm needs to be committed
+  * @keepalive: flag used to indicate whether a keepalive is required
+  * @aux_data: auxiliary data used when calculating threshold values and
+@@ -97,6 +98,7 @@ struct qcom_icc_bcm {
+       u64 vote_x[QCOM_ICC_NUM_BUCKETS];
+       u64 vote_y[QCOM_ICC_NUM_BUCKETS];
+       u64 vote_scale;
++      u32 enable_mask;
+       bool dirty;
+       bool keepalive;
+       struct bcm_db aux_data;
diff --git a/queue-5.10/s390-ap-fix-ap-bus-crash-on-early-config-change-callback-invocation.patch b/queue-5.10/s390-ap-fix-ap-bus-crash-on-early-config-change-callback-invocation.patch
deleted file mode 100644 (file)
index d354d06..0000000
+++ /dev/null
@@ -1,88 +0,0 @@
-From e14aec23025eeb1f2159ba34dbc1458467c4c347 Mon Sep 17 00:00:00 2001
-From: Harald Freudenberger <freude@linux.ibm.com>
-Date: Mon, 23 Oct 2023 09:57:10 +0200
-Subject: s390/ap: fix AP bus crash on early config change callback invocation
-
-From: Harald Freudenberger <freude@linux.ibm.com>
-
-commit e14aec23025eeb1f2159ba34dbc1458467c4c347 upstream.
-
-Fix kernel crash in AP bus code caused by very early invocation of the
-config change callback function via SCLP.
-
-After a fresh IML of the machine the crypto cards are still offline and
-will get switched online only with activation of any LPAR which has the
-card in it's configuration. A crypto card coming online is reported
-to the LPAR via SCLP and the AP bus offers a callback function to get
-this kind of information. However, it may happen that the callback is
-invoked before the AP bus init function is complete. As the callback
-triggers a synchronous AP bus scan, the scan may already run but some
-internal states are not initialized by the AP bus init function resulting
-in a crash like this:
-
-  [   11.635859] Unable to handle kernel pointer dereference in virtual kernel address space
-  [   11.635861] Failing address: 0000000000000000 TEID: 0000000000000887
-  [   11.635862] Fault in home space mode while using kernel ASCE.
-  [   11.635864] AS:00000000894c4007 R3:00000001fece8007 S:00000001fece7800 P:000000000000013d
-  [   11.635879] Oops: 0004 ilc:1 [#1] SMP
-  [   11.635882] Modules linked in:
-  [   11.635884] CPU: 5 PID: 42 Comm: kworker/5:0 Not tainted 6.6.0-rc3-00003-g4dbf7cdc6b42 #12
-  [   11.635886] Hardware name: IBM 3931 A01 751 (LPAR)
-  [   11.635887] Workqueue: events_long ap_scan_bus
-  [   11.635891] Krnl PSW : 0704c00180000000 0000000000000000 (0x0)
-  [   11.635895]            R:0 T:1 IO:1 EX:1 Key:0 M:1 W:0 P:0 AS:3 CC:0 PM:0 RI:0 EA:3
-  [   11.635897] Krnl GPRS: 0000000001000a00 0000000000000000 0000000000000006 0000000089591940
-  [   11.635899]            0000000080000000 0000000000000a00 0000000000000000 0000000000000000
-  [   11.635901]            0000000081870c00 0000000089591000 000000008834e4e2 0000000002625a00
-  [   11.635903]            0000000081734200 0000038000913c18 000000008834c6d6 0000038000913ac8
-  [   11.635906] Krnl Code:>0000000000000000: 0000                illegal
-  [   11.635906]            0000000000000002: 0000                illegal
-  [   11.635906]            0000000000000004: 0000                illegal
-  [   11.635906]            0000000000000006: 0000                illegal
-  [   11.635906]            0000000000000008: 0000                illegal
-  [   11.635906]            000000000000000a: 0000                illegal
-  [   11.635906]            000000000000000c: 0000                illegal
-  [   11.635906]            000000000000000e: 0000                illegal
-  [   11.635915] Call Trace:
-  [   11.635916]  [<0000000000000000>] 0x0
-  [   11.635918]  [<000000008834e4e2>] ap_queue_init_state+0x82/0xb8
-  [   11.635921]  [<000000008834ba1c>] ap_scan_domains+0x6fc/0x740
-  [   11.635923]  [<000000008834c092>] ap_scan_adapter+0x632/0x8b0
-  [   11.635925]  [<000000008834c3e4>] ap_scan_bus+0xd4/0x288
-  [   11.635927]  [<00000000879a33ba>] process_one_work+0x19a/0x410
-  [   11.635930] Discipline DIAG cannot be used without z/VM
-  [   11.635930]  [<00000000879a3a2c>] worker_thread+0x3fc/0x560
-  [   11.635933]  [<00000000879aea60>] kthread+0x120/0x128
-  [   11.635936]  [<000000008792afa4>] __ret_from_fork+0x3c/0x58
-  [   11.635938]  [<00000000885ebe62>] ret_from_fork+0xa/0x30
-  [   11.635942] Last Breaking-Event-Address:
-  [   11.635942]  [<000000008834c6d4>] ap_wait+0xcc/0x148
-
-This patch improves the ap_bus_force_rescan() function which is
-invoked by the config change callback by checking if a first
-initial AP bus scan has been done. If not, the force rescan request
-is simple ignored. Anyhow it does not make sense to trigger AP bus
-re-scans even before the very first bus scan is complete.
-
-Cc: stable@vger.kernel.org
-Reviewed-by: Holger Dengler <dengler@linux.ibm.com>
-Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>
-Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/s390/crypto/ap_bus.c |    4 ++++
- 1 file changed, 4 insertions(+)
-
---- a/drivers/s390/crypto/ap_bus.c
-+++ b/drivers/s390/crypto/ap_bus.c
-@@ -787,6 +787,10 @@ EXPORT_SYMBOL(ap_driver_unregister);
- void ap_bus_force_rescan(void)
- {
-+      /* Only trigger AP bus scans after the initial scan is done */
-+      if (atomic64_read(&ap_scan_bus_count) <= 0)
-+              return;
-+
-       /* processing a asynchronous bus rescan */
-       del_timer(&ap_config_timer);
-       queue_work(system_long_wq, &ap_scan_work);
index 4662bfdb2ccbfad771a4c6361b862126e8992de5..577baa357b50f01161ba897c8192c96d92911ce7 100644 (file)
@@ -158,7 +158,6 @@ revert-ncsi-propagate-carrier-gain-loss-events-to-the-ncsi-controller.patch
 lsm-fix-default-return-value-for-vm_enough_memory.patch
 lsm-fix-default-return-value-for-inode_getsecctx.patch
 i2c-designware-disable-tx_empty-irq-while-waiting-for-block-length-byte.patch
-s390-ap-fix-ap-bus-crash-on-early-config-change-callback-invocation.patch
 net-dsa-lan9303-consequently-nested-lock-physical-mdio.patch
 net-phylink-initialize-carrier-state-at-creation.patch
 i2c-i801-fix-potential-race-in-i801_block_transaction_byte_by_byte.patch
@@ -185,3 +184,4 @@ tracing-have-trace_event_file-have-ref-counters.patch
 netfilter-nftables-update-table-flags-from-the-commit-phase.patch
 netfilter-nf_tables-fix-table-flag-updates.patch
 netfilter-nf_tables-disable-toggling-dormant-table-state-more-than-once.patch
+interconnect-qcom-add-support-for-mask-based-bcms.patch