6.5.3-rc1 review
Subsystems (13)
Greg Kroah-Hartman
maintainerPATCH 227/739 arm64: dts: qcom: sdm845-tama: Set serial indices and stdout-path
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 9acc60c3e2d449243e4c2126e3b56f1c4f7fd3bc ]
UART6 is used for debug (routed via uSD pins) and UART9 is connected to the bluetooth chip.
Set indexed aliases to make the GENI UART driver happy and route serial traffic through the debug uart by default.
--- arch/arm64/boot/dts/qcom/sdm845-sony-xperia-tama.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+)
arch/arm64/boot/dts/qcom/sdm845-sony-xperia-tama.dtsi +9 -0
@@ -15,6 +15,15 @@ / { qcom,msm-id = <321 0x20001>; /* SDM845 v2.1 */ qcom,board-id = <8 0>; + aliases { + serial0 = &uart6; + serial1 = &uart9; + }; + + chosen { + stdout-path = "serial0:115200n8"; + }; + gpio-keys { compatible = "gpio-keys";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 228/739 arm64: dts: qcom: sm8350: Fix CPU idle state residency times
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 91ce3693e2fb685f31d39605a5ad1fbd940804da ]
The present values look to have been copypasted from 8150 or 8180. Fix that.
--- arch/arm64/boot/dts/qcom/sm8350.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
arch/arm64/boot/dts/qcom/sm8350.dtsi +4 -4
@@ -246,8 +246,8 @@ LITTLE_CPU_SLEEP_0: cpu-sleep-0-0 { compatible = "arm,idle-state"; idle-state-name = "silver-rail-power-collapse"; arm,psci-suspend-param = <0x40000004>; - entry-latency-us = <355>; - exit-latency-us = <909>; + entry-latency-us = <360>; + exit-latency-us = <531>; min-residency-us = <3934>; local-timer-stop; };
@@ -256,8 +256,8 @@ BIG_CPU_SLEEP_0: cpu-sleep-1-0 { compatible = "arm,idle-state"; idle-state-name = "gold-rail-power-collapse"; arm,psci-suspend-param = <0x40000004>; - entry-latency-us = <241>; - exit-latency-us = <1461>; + entry-latency-us = <702>; + exit-latency-us = <1061>; min-residency-us = <4488>; local-timer-stop; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 229/739 arm64: dts: qcom: sm8350: Add missing LMH interrupts to cpufreq
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 951151c2bb548e0f6b2c40ab4c48675f5342c914 ]
Add the missing interrupts that communicate the hardware-managed throttling to Linux.
--- arch/arm64/boot/dts/qcom/sm8350.dtsi | 7 +++++++ 1 file changed, 7 insertions(+)
arch/arm64/boot/dts/qcom/sm8350.dtsi +7 -0
@@ -3399,6 +3399,13 @@ cpufreq_hw: cpufreq@18591000 { <0 0x18593000 0 0x1000>; reg-names = "freq-domain0", "freq-domain1", "freq-domain2"; + interrupts = <GIC_SPI 30 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 31 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 19 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dcvsh-irq-0", + "dcvsh-irq-1", + "dcvsh-irq-2"; + clocks = <&rpmhcc RPMH_CXO_CLK>, <&gcc GCC_GPLL0>; clock-names = "xo", "alternate";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 230/739 arm64: dts: qcom: sc8180x: Fix cluster PSCI suspend param
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 9c31a3f5abc9eeb6509d06041b1e5f12deb39c4d ]
The value was copypasted from 8150, but 8180 expects a different one. Confirmed with both downstream device tree and Windows DSDT, not tested on hardware (sorry, I don't have any).
Fix it.
--- arch/arm64/boot/dts/qcom/sc8180x.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/sc8180x.dtsi +1 -1
@@ -298,7 +298,7 @@ BIG_CPU_SLEEP_0: cpu-sleep-1-0 { domain-idle-states { CLUSTER_SLEEP_0: cluster-sleep-0 { compatible = "domain-idle-state"; - arm,psci-suspend-param = <0x4100c244>; + arm,psci-suspend-param = <0x4100a344>; entry-latency-us = <3263>; exit-latency-us = <6562>; min-residency-us = <9987>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 231/739 arm64: dts: qcom: sm8350: Use proper CPU compatibles
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 4390730cc12af25f7c997f477795f5f4200149c0 ]
The Kryo names (once again) turned out to be fake. The CPUs report:
0x412fd050 (CA55 r2p0) (0 - 3)0x411fd410 (CA78 r1p1) (4 - 6)0x411fd440 (CX1 r1p1) (7)
Use the compatibles that reflect that.
--- arch/arm64/boot/dts/qcom/sm8350.dtsi | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)
arch/arm64/boot/dts/qcom/sm8350.dtsi +8 -8
@@ -48,7 +48,7 @@ cpus { CPU0: cpu@0 { device_type = "cpu"; - compatible = "qcom,kryo685"; + compatible = "arm,cortex-a55"; reg = <0x0 0x0>; clocks = <&cpufreq_hw 0>; enable-method = "psci";
@@ -72,7 +72,7 @@ L3_0: l3-cache { CPU1: cpu@100 { device_type = "cpu"; - compatible = "qcom,kryo685"; + compatible = "arm,cortex-a55"; reg = <0x0 0x100>; clocks = <&cpufreq_hw 0>; enable-method = "psci";
@@ -91,7 +91,7 @@ L2_100: l2-cache { CPU2: cpu@200 { device_type = "cpu"; - compatible = "qcom,kryo685"; + compatible = "arm,cortex-a55"; reg = <0x0 0x200>; clocks = <&cpufreq_hw 0>; enable-method = "psci";
@@ -110,7 +110,7 @@ L2_200: l2-cache { CPU3: cpu@300 { device_type = "cpu"; - compatible = "qcom,kryo685"; + compatible = "arm,cortex-a55"; reg = <0x0 0x300>; clocks = <&cpufreq_hw 0>; enable-method = "psci";
@@ -129,7 +129,7 @@ L2_300: l2-cache { CPU4: cpu@400 { device_type = "cpu"; - compatible = "qcom,kryo685"; + compatible = "arm,cortex-a78"; reg = <0x0 0x400>; clocks = <&cpufreq_hw 1>; enable-method = "psci";
@@ -148,7 +148,7 @@ L2_400: l2-cache { CPU5: cpu@500 { device_type = "cpu"; - compatible = "qcom,kryo685"; + compatible = "arm,cortex-a78"; reg = <0x0 0x500>; clocks = <&cpufreq_hw 1>; enable-method = "psci";
@@ -167,7 +167,7 @@ L2_500: l2-cache { CPU6: cpu@600 { device_type = "cpu"; - compatible = "qcom,kryo685"; + compatible = "arm,cortex-a78"; reg = <0x0 0x600>; clocks = <&cpufreq_hw 1>; enable-method = "psci";
@@ -186,7 +186,7 @@ L2_600: l2-cache { CPU7: cpu@700 { device_type = "cpu"; - compatible = "qcom,kryo685"; + compatible = "arm,cortex-x1"; reg = <0x0 0x700>; clocks = <&cpufreq_hw 2>; enable-method = "psci";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 232/739 arm64: dts: qcom: pm8350: fix thermal zone name
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Baryshkov <[email protected]>
[ Upstream commit 64f19c06f704846db5e4885ca63c689d9bef5723 ]
The name of the thermal zone in pm8350.dtsi (pm8350c-thermal) conflicts with the thermal zone in pm8350c.dtsi. Rename the thermal zone according to the chip name.
--- arch/arm64/boot/dts/qcom/pm8350.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/pm8350.dtsi +1 -1
@@ -8,7 +8,7 @@ / { thermal-zones { - pm8350_thermal: pm8350c-thermal { + pm8350_thermal: pm8350-thermal { polling-delay-passive = <100>; polling-delay = <0>; thermal-sensors = <&pm8350_temp_alarm>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 233/739 arm64: dts: qcom: pm8350b: fix thermal zone name
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Baryshkov <[email protected]>
[ Upstream commit aad41d9e6c44dfe299cddab97528a5333f17bdfe ]
The name of the thermal zone in pm8350b.dtsi (pm8350c-thermal) conflicts with the thermal zone in pm8350c.dtsi. Rename the thermal zone according to the chip name.
--- arch/arm64/boot/dts/qcom/pm8350b.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/pm8350b.dtsi +1 -1
@@ -8,7 +8,7 @@ / { thermal-zones { - pm8350b_thermal: pm8350c-thermal { + pm8350b_thermal: pm8350b-thermal { polling-delay-passive = <100>; polling-delay = <0>; thermal-sensors = <&pm8350b_temp_alarm>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 234/739 arm64: dts: qcom: pmr735b: fix thermal zone name
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Baryshkov <[email protected]>
[ Upstream commit 99f8cf491d546cd668236f573c7d846d3e94f2d6 ]
The name of the thermal zone in pmr735b.dtsi (pmr735a-thermal) conflicts with the thermal zone in pmr735a.dtsi. Rename the thermal zone according to the chip name.
--- arch/arm64/boot/dts/qcom/pmr735b.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/pmr735b.dtsi +1 -1
@@ -8,7 +8,7 @@ / { thermal-zones { - pmr735a_thermal: pmr735a-thermal { + pmr735b_thermal: pmr735b-thermal { polling-delay-passive = <100>; polling-delay = <0>; thermal-sensors = <&pmr735b_temp_alarm>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 235/739 arm64: dts: qcom: pmk8350: fix ADC-TM compatible string
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Baryshkov <[email protected]>
[ Upstream commit 435a73d7377ceb29c1a22d2711dd85c831b40c45 ]
The commit b2de43136058 ("arm64: dts: qcom: pmk8350: Add peripherals for pmk8350") for the ADC TM (thermal monitoring device) have used the compatible string from the vendor kernel ("qcom,adc-tm7"). Use the proper compatible string that is defined in the upstream kernel ("qcom,spmi-adc-tm5-gen2").
--- arch/arm64/boot/dts/qcom/pmk8350.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/pmk8350.dtsi +1 -1
@@ -59,7 +59,7 @@ pmk8350_vadc: adc@3100 { }; pmk8350_adc_tm: adc-tm@3400 { - compatible = "qcom,adc-tm7"; + compatible = "qcom,spmi-adc-tm5-gen2"; reg = <0x3400>; interrupts = <PMK8350_SID 0x34 0x0 IRQ_TYPE_EDGE_RISING>; #address-cells = <1>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 236/739 arm64: dts: qcom: sm8450-hdk: remove pmr735b PMIC inclusion
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Baryshkov <[email protected]>
[ Upstream commit 701b59db773730a914f1778cf2dd05e3a05c2c69 ]
The 8450-HDK doesn't use PMR735B PMIC. Drop its inclusion to remove the warning during the HDK bootup.
--- arch/arm64/boot/dts/qcom/sm8450-hdk.dts | 1 - 1 file changed, 1 deletion(-)
arch/arm64/boot/dts/qcom/sm8450-hdk.dts +0 -1
@@ -14,7 +14,6 @@ #include "pm8450.dtsi" #include "pmk8350.dtsi" #include "pmr735a.dtsi" -#include "pmr735b.dtsi" / { model = "Qualcomm Technologies, Inc. SM8450 HDK";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 237/739 arm64: dts: qcom: sm8250: Mark PCIe hosts as DMA coherent
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 339d38a436f30d0f874815eafc7de2257346bf26 ]
The PCIe hosts on SM8250 are cache-coherent. Mark them as such.
--- arch/arm64/boot/dts/qcom/sm8250.dtsi | 3 +++ 1 file changed, 3 insertions(+)
arch/arm64/boot/dts/qcom/sm8250.dtsi +3 -0
@@ -1905,6 +1905,7 @@ pcie0: pci@1c00000 { pinctrl-names = "default"; pinctrl-0 = <&pcie0_default_state>; + dma-coherent; status = "disabled"; };
@@ -2011,6 +2012,7 @@ pcie1: pci@1c08000 { pinctrl-names = "default"; pinctrl-0 = <&pcie1_default_state>; + dma-coherent; status = "disabled"; };
@@ -2119,6 +2121,7 @@ pcie2: pci@1c10000 { pinctrl-names = "default"; pinctrl-0 = <&pcie2_default_state>; + dma-coherent; status = "disabled"; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 238/739 arm64: dts: qcom: minor whitespace cleanup around =
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Krzysztof Kozlowski <[email protected]>
[ Upstream commit 934a3b4d5a2d4c265ca22d3cf471a72ec8d9ee65 ]
The DTS code coding style expects exactly one space before and after '=' sign.
Stable-dep-of: 4cb19bd7c632 ("arm64: dts: qcom: sm8250: Mark SMMUs as DMA coherent")
--- arch/arm64/boot/dts/qcom/ipq8074.dtsi | 8 +- .../dts/qcom/msm8916-samsung-serranove.dts | 6 +- arch/arm64/boot/dts/qcom/msm8939.dtsi | 12 +- .../boot/dts/qcom/msm8953-xiaomi-daisy.dts | 2 +- .../boot/dts/qcom/msm8953-xiaomi-vince.dts | 2 +- arch/arm64/boot/dts/qcom/msm8996.dtsi | 6 +- .../dts/qcom/msm8996pro-xiaomi-natrium.dts | 2 +- arch/arm64/boot/dts/qcom/msm8998.dtsi | 18 +- arch/arm64/boot/dts/qcom/qcm2290.dtsi | 2 +- arch/arm64/boot/dts/qcom/qcs404.dtsi | 8 +- arch/arm64/boot/dts/qcom/sa8540p.dtsi | 2 +- .../sc7280-herobrine-audio-rt5682-3mic.dtsi | 2 +- arch/arm64/boot/dts/qcom/sc7280.dtsi | 2 +- arch/arm64/boot/dts/qcom/sc8180x.dtsi | 2 +- arch/arm64/boot/dts/qcom/sdm630.dtsi | 10 +- .../dts/qcom/sdm845-oneplus-enchilada.dts | 2 +- arch/arm64/boot/dts/qcom/sdx75.dtsi | 4 +- arch/arm64/boot/dts/qcom/sm6115.dtsi | 2 +- arch/arm64/boot/dts/qcom/sm8250.dtsi | 198 +++++++++--------- arch/arm64/boot/dts/qcom/sm8350.dtsi | 196 ++++++++--------- arch/arm64/boot/dts/qcom/sm8450.dtsi | 194 ++++++++--------- arch/arm64/boot/dts/qcom/sm8550.dtsi | 196 ++++++++--------- 22 files changed, 438 insertions(+), 438 deletions(-)
arch/arm64/boot/dts/qcom/ipq8074.dtsi +4 -4
@@ -794,10 +794,10 @@ frame@b128000 { pcie1: pci@10000000 { compatible = "qcom,pcie-ipq8074"; - reg = <0x10000000 0xf1d>, - <0x10000f20 0xa8>, - <0x00088000 0x2000>, - <0x10100000 0x1000>; + reg = <0x10000000 0xf1d>, + <0x10000f20 0xa8>, + <0x00088000 0x2000>, + <0x10100000 0x1000>; reg-names = "dbi", "elbi", "parf", "config"; device_type = "pci"; linux,pci-domain = <1>;
arch/arm64/boot/dts/qcom/msm8916-samsung-serranove.dts +3 -3
@@ -219,9 +219,9 @@ magnetometer@2e { compatible = "yamaha,yas537"; reg = <0x2e>; - mount-matrix = "0", "1", "0", - "1", "0", "0", - "0", "0", "-1"; + mount-matrix = "0", "1", "0", + "1", "0", "0", + "0", "0", "-1"; }; };
arch/arm64/boot/dts/qcom/msm8939.dtsi +6 -6
@@ -1646,7 +1646,7 @@ sdhc_2: mmc@7864900 { clocks = <&gcc GCC_SDCC2_AHB_CLK>, <&gcc GCC_SDCC2_APPS_CLK>, <&rpmcc RPM_SMD_XO_CLK_SRC>; - clock-names = "iface", "core", "xo"; + clock-names = "iface", "core", "xo"; resets = <&gcc GCC_SDCC2_BCR>; pinctrl-0 = <&sdc2_default>; pinctrl-1 = <&sdc2_sleep>;
@@ -1733,7 +1733,7 @@ blsp_i2c2: i2c@78b6000 { interrupts = <GIC_SPI 96 IRQ_TYPE_LEVEL_HIGH>; clocks = <&gcc GCC_BLSP1_QUP2_I2C_APPS_CLK>, <&gcc GCC_BLSP1_AHB_CLK>; - clock-names = "core", "iface"; + clock-names = "core", "iface"; dmas = <&blsp_dma 6>, <&blsp_dma 7>; dma-names = "tx", "rx"; pinctrl-0 = <&blsp_i2c2_default>;
@@ -1767,7 +1767,7 @@ blsp_i2c3: i2c@78b7000 { interrupts = <GIC_SPI 97 IRQ_TYPE_LEVEL_HIGH>; clocks = <&gcc GCC_BLSP1_QUP3_I2C_APPS_CLK>, <&gcc GCC_BLSP1_AHB_CLK>; - clock-names = "core", "iface"; + clock-names = "core", "iface"; dmas = <&blsp_dma 8>, <&blsp_dma 9>; dma-names = "tx", "rx"; pinctrl-0 = <&blsp_i2c3_default>;
@@ -1801,7 +1801,7 @@ blsp_i2c4: i2c@78b8000 { interrupts = <GIC_SPI 98 IRQ_TYPE_LEVEL_HIGH>; clocks = <&gcc GCC_BLSP1_QUP4_I2C_APPS_CLK>, <&gcc GCC_BLSP1_AHB_CLK>; - clock-names = "core", "iface"; + clock-names = "core", "iface"; dmas = <&blsp_dma 10>, <&blsp_dma 11>; dma-names = "tx", "rx"; pinctrl-0 = <&blsp_i2c4_default>;
@@ -1835,7 +1835,7 @@ blsp_i2c5: i2c@78b9000 { interrupts = <GIC_SPI 99 IRQ_TYPE_LEVEL_HIGH>; clocks = <&gcc GCC_BLSP1_QUP5_I2C_APPS_CLK>, <&gcc GCC_BLSP1_AHB_CLK>; - clock-names = "core", "iface"; + clock-names = "core", "iface"; dmas = <&blsp_dma 12>, <&blsp_dma 13>; dma-names = "tx", "rx"; pinctrl-0 = <&blsp_i2c5_default>;
@@ -1869,7 +1869,7 @@ blsp_i2c6: i2c@78ba000 { interrupts = <GIC_SPI 100 IRQ_TYPE_LEVEL_HIGH>; clocks = <&gcc GCC_BLSP1_QUP6_I2C_APPS_CLK>, <&gcc GCC_BLSP1_AHB_CLK>; - clock-names = "core", "iface"; + clock-names = "core", "iface"; dmas = <&blsp_dma 14>, <&blsp_dma 15>; dma-names = "tx", "rx"; pinctrl-0 = <&blsp_i2c6_default>;
arch/arm64/boot/dts/qcom/msm8953-xiaomi-daisy.dts +1 -1
@@ -17,7 +17,7 @@ / { compatible = "xiaomi,daisy", "qcom,msm8953"; chassis-type = "handset"; qcom,msm-id = <293 0>; - qcom,board-id= <0x1000b 0x9>; + qcom,board-id = <0x1000b 0x9>; chosen { #address-cells = <2>;
arch/arm64/boot/dts/qcom/msm8953-xiaomi-vince.dts +1 -1
@@ -20,7 +20,7 @@ / { compatible = "xiaomi,vince", "qcom,msm8953"; chassis-type = "handset"; qcom,msm-id = <293 0>; - qcom,board-id= <0x1000b 0x08>; + qcom,board-id = <0x1000b 0x08>; gpio-keys { compatible = "gpio-keys";
arch/arm64/boot/dts/qcom/msm8996.dtsi +3 -3
@@ -1138,9 +1138,9 @@ mdss_dsi1_phy: phy@996400 { hdmi: hdmi-tx@9a0000 { compatible = "qcom,hdmi-tx-8996"; - reg = <0x009a0000 0x50c>, - <0x00070000 0x6158>, - <0x009e0000 0xfff>; + reg = <0x009a0000 0x50c>, + <0x00070000 0x6158>, + <0x009e0000 0xfff>; reg-names = "core_physical", "qfprom_physical", "hdcp_physical";
arch/arm64/boot/dts/qcom/msm8996pro-xiaomi-natrium.dts +1 -1
@@ -106,7 +106,7 @@ &slpi_pil { &sound { compatible = "qcom,apq8096-sndcard"; model = "natrium"; - audio-routing = "RX_BIAS", "MCLK"; + audio-routing = "RX_BIAS", "MCLK"; mm1-dai-link { link-name = "MultiMedia1";
arch/arm64/boot/dts/qcom/msm8998.dtsi +9 -9
@@ -909,10 +909,10 @@ anoc2_smmu: iommu@16c0000 { pcie0: pci@1c00000 { compatible = "qcom,pcie-msm8998", "qcom,pcie-msm8996"; - reg = <0x01c00000 0x2000>, - <0x1b000000 0xf1d>, - <0x1b000f20 0xa8>, - <0x1b100000 0x100000>; + reg = <0x01c00000 0x2000>, + <0x1b000000 0xf1d>, + <0x1b000f20 0xa8>, + <0x1b100000 0x100000>; reg-names = "parf", "dbi", "elbi", "config"; device_type = "pci"; linux,pci-domain = <0>;
@@ -2074,11 +2074,11 @@ sram@290000 { spmi_bus: spmi@800f000 { compatible = "qcom,spmi-pmic-arb"; - reg = <0x0800f000 0x1000>, - <0x08400000 0x1000000>, - <0x09400000 0x1000000>, - <0x0a400000 0x220000>, - <0x0800a000 0x3000>; + reg = <0x0800f000 0x1000>, + <0x08400000 0x1000000>, + <0x09400000 0x1000000>, + <0x0a400000 0x220000>, + <0x0800a000 0x3000>; reg-names = "core", "chnls", "obsrvr", "intr", "cnfg"; interrupt-names = "periph_irq"; interrupts = <GIC_SPI 326 IRQ_TYPE_LEVEL_HIGH>;
arch/arm64/boot/dts/qcom/qcm2290.dtsi +1 -1
@@ -790,7 +790,7 @@ gpi_dma0: dma-controller@4a00000 { <GIC_SPI 342 IRQ_TYPE_LEVEL_HIGH>, <GIC_SPI 343 IRQ_TYPE_LEVEL_HIGH>, <GIC_SPI 344 IRQ_TYPE_LEVEL_HIGH>; - dma-channels = <10>; + dma-channels = <10>; dma-channel-mask = <0x1f>; iommus = <&apps_smmu 0xf6 0x0>; #dma-cells = <3>;
arch/arm64/boot/dts/qcom/qcs404.dtsi +4 -4
@@ -1459,10 +1459,10 @@ glink-edge { pcie: pci@10000000 { compatible = "qcom,pcie-qcs404"; - reg = <0x10000000 0xf1d>, - <0x10000f20 0xa8>, - <0x07780000 0x2000>, - <0x10001000 0x2000>; + reg = <0x10000000 0xf1d>, + <0x10000f20 0xa8>, + <0x07780000 0x2000>, + <0x10001000 0x2000>; reg-names = "dbi", "elbi", "parf", "config"; device_type = "pci"; linux,pci-domain = <0>;
arch/arm64/boot/dts/qcom/sa8540p.dtsi +1 -1
@@ -207,7 +207,7 @@ &pcie3a { linux,pci-domain = <2>; - interrupts = <GIC_SPI 567 IRQ_TYPE_LEVEL_HIGH>; + interrupts = <GIC_SPI 567 IRQ_TYPE_LEVEL_HIGH>; interrupt-names = "msi"; interrupt-map = <0 0 0 1 &intc 0 0 GIC_SPI 541 IRQ_TYPE_LEVEL_HIGH>,
arch/arm64/boot/dts/qcom/sc7280-herobrine-audio-rt5682-3mic.dtsi +1 -1
@@ -13,7 +13,7 @@ sound: sound { compatible = "google,sc7280-herobrine"; model = "sc7280-rt5682-max98360a-3mic"; - audio-routing = "VA DMIC0", "vdd-micb", + audio-routing = "VA DMIC0", "vdd-micb", "VA DMIC1", "vdd-micb", "VA DMIC2", "vdd-micb", "VA DMIC3", "vdd-micb",
arch/arm64/boot/dts/qcom/sc7280.dtsi +1 -1
@@ -2449,7 +2449,7 @@ lpass_cpu: audio@3987000 { <&apps_smmu 0x1821 0>, <&apps_smmu 0x1832 0>; - power-domains = <&rpmhpd SC7280_LCX>; + power-domains = <&rpmhpd SC7280_LCX>; power-domain-names = "lcx"; required-opps = <&rpmhpd_opp_nom>;
arch/arm64/boot/dts/qcom/sc8180x.dtsi +1 -1
@@ -2252,7 +2252,7 @@ opp-177000000 { }; gmu: gmu@2c6a000 { - compatible="qcom,adreno-gmu-680.1", "qcom,adreno-gmu"; + compatible = "qcom,adreno-gmu-680.1", "qcom,adreno-gmu"; reg = <0 0x02c6a000 0 0x30000>, <0 0x0b290000 0 0x10000>,
arch/arm64/boot/dts/qcom/sdm630.dtsi +5 -5
@@ -1196,11 +1196,11 @@ sram@290000 { spmi_bus: spmi@800f000 { compatible = "qcom,spmi-pmic-arb"; - reg = <0x0800f000 0x1000>, - <0x08400000 0x1000000>, - <0x09400000 0x1000000>, - <0x0a400000 0x220000>, - <0x0800a000 0x3000>; + reg = <0x0800f000 0x1000>, + <0x08400000 0x1000000>, + <0x09400000 0x1000000>, + <0x0a400000 0x220000>, + <0x0800a000 0x3000>; reg-names = "core", "chnls", "obsrvr", "intr", "cnfg"; interrupt-names = "periph_irq"; interrupts = <GIC_SPI 326 IRQ_TYPE_LEVEL_HIGH>;
arch/arm64/boot/dts/qcom/sdm845-oneplus-enchilada.dts +1 -1
@@ -57,7 +57,7 @@ &pmi8998_charger { &sound { model = "OnePlus 6"; - audio-routing = "RX_BIAS", "MCLK", + audio-routing = "RX_BIAS", "MCLK", "AMIC2", "MIC BIAS2", "AMIC3", "MIC BIAS4", "AMIC4", "MIC BIAS1",
arch/arm64/boot/dts/qcom/sdx75.dtsi +2 -2
@@ -484,14 +484,14 @@ qupv3_se1_2uart_active: qupv3-se1-2uart-active-state { tx-pins { pins = "gpio12"; function = "qup_se1_l2_mira"; - drive-strength= <2>; + drive-strength = <2>; bias-disable; }; rx-pins { pins = "gpio13"; function = "qup_se1_l3_mira"; - drive-strength= <2>; + drive-strength = <2>; bias-disable; }; };
arch/arm64/boot/dts/qcom/sm6115.dtsi +1 -1
@@ -1052,7 +1052,7 @@ gpi_dma0: dma-controller@4a00000 { <GIC_SPI 342 IRQ_TYPE_LEVEL_HIGH>, <GIC_SPI 343 IRQ_TYPE_LEVEL_HIGH>, <GIC_SPI 344 IRQ_TYPE_LEVEL_HIGH>; - dma-channels = <10>; + dma-channels = <10>; dma-channel-mask = <0xf>; iommus = <&apps_smmu 0xf6 0x0>; #dma-cells = <3>;
arch/arm64/boot/dts/qcom/sm8250.dtsi +99 -99
210 lines not on this page · raw message
arch/arm64/boot/dts/qcom/sm8350.dtsi +98 -98
202 lines not on this page · raw message
arch/arm64/boot/dts/qcom/sm8450.dtsi +97 -97
200 lines not on this page · raw message
arch/arm64/boot/dts/qcom/sm8550.dtsi +98 -98
208 lines not on this page · raw message
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 239/739 arm64: dts: qcom: sm8250: Mark SMMUs as DMA coherent
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 4cb19bd7c6329c4702f92c6dd4e7c02eb903ca13 ]
The SMMUs on SM8250 are cache-coherent. Mark them as such.
--- arch/arm64/boot/dts/qcom/sm8250.dtsi | 2 ++ 1 file changed, 2 insertions(+)
arch/arm64/boot/dts/qcom/sm8250.dtsi +2 -0
@@ -2729,6 +2729,7 @@ adreno_smmu: iommu@3da0000 { clock-names = "ahb", "bus", "iface"; power-domains = <&gpucc GPU_CX_GDSC>; + dma-coherent; }; slpi: remoteproc@5c00000 {
@@ -5399,6 +5400,7 @@ apps_smmu: iommu@15000000 { <GIC_SPI 696 IRQ_TYPE_LEVEL_HIGH>, <GIC_SPI 697 IRQ_TYPE_LEVEL_HIGH>, <GIC_SPI 707 IRQ_TYPE_LEVEL_HIGH>; + dma-coherent; }; adsp: remoteproc@17300000 {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 240/739 ARM: dts: stm32: Add missing detach mailbox for emtrion emSBC-Argon
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Marek Vasut <[email protected]>
[ Upstream commit 0ee0ef38aa9f75f21b51f729dd42b2e932515188 ]
Add missing "detach" mailbox to this board to permit the CPU to inform the remote processor on a detach. This signal allows the remote processor firmware to stop IPC communication and to reinitialize the resources for a re-attach.
Without this mailbox, detach is not possible and kernel log contains the following warning to, so make sure all the STM32MP15xx platform DTs are
in sync regarding the mailboxes to fix the detach issue and the warning:
"
stm32-rproc 10000000.m4: mbox_request_channel_byname() could not locate channel named "detach" "
--- arch/arm/boot/dts/st/stm32mp157c-emstamp-argon.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm/boot/dts/st/stm32mp157c-emstamp-argon.dtsi +2 -2
@@ -368,8 +368,8 @@ &iwdg2 { &m4_rproc { memory-region = <&retram>, <&mcuram>, <&mcuram2>, <&vdev0vring0>, <&vdev0vring1>, <&vdev0buffer>; - mboxes = <&ipcc 0>, <&ipcc 1>, <&ipcc 2>; - mbox-names = "vq0", "vq1", "shutdown"; + mboxes = <&ipcc 0>, <&ipcc 1>, <&ipcc 2>, <&ipcc 3>; + mbox-names = "vq0", "vq1", "shutdown", "detach"; interrupt-parent = <&exti>; interrupts = <68 1>; interrupt-names = "wdg";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 241/739 ARM: dts: stm32: Add missing detach mailbox for Odyssey SoM
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Marek Vasut <[email protected]>
[ Upstream commit 966f04a89d77548e673de2c400abe0b2cf5c15db ]
Add missing "detach" mailbox to this board to permit the CPU to inform the remote processor on a detach. This signal allows the remote processor firmware to stop IPC communication and to reinitialize the resources for a re-attach.
Without this mailbox, detach is not possible and kernel log contains the following warning to, so make sure all the STM32MP15xx platform DTs are
in sync regarding the mailboxes to fix the detach issue and the warning:
"
stm32-rproc 10000000.m4: mbox_request_channel_byname() could not locate channel named "detach" "
--- arch/arm/boot/dts/st/stm32mp157c-odyssey-som.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm/boot/dts/st/stm32mp157c-odyssey-som.dtsi +2 -2
@@ -230,8 +230,8 @@ &iwdg2 { &m4_rproc { memory-region = <&retram>, <&mcuram>, <&mcuram2>, <&vdev0vring0>, <&vdev0vring1>, <&vdev0buffer>; - mboxes = <&ipcc 0>, <&ipcc 1>, <&ipcc 2>; - mbox-names = "vq0", "vq1", "shutdown"; + mboxes = <&ipcc 0>, <&ipcc 1>, <&ipcc 2>, <&ipcc 3>; + mbox-names = "vq0", "vq1", "shutdown", "detach"; interrupt-parent = <&exti>; interrupts = <68 1>; status = "okay";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 242/739 ARM: dts: stm32: Add missing detach mailbox for DHCOM SoM
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Marek Vasut <[email protected]>
[ Upstream commit deb7edbc27a6ec4d8f5edfd8519b7ed13cbd2a52 ]
Add missing "detach" mailbox to this board to permit the CPU to inform the remote processor on a detach. This signal allows the remote processor firmware to stop IPC communication and to reinitialize the resources for a re-attach.
Without this mailbox, detach is not possible and kernel log contains the following warning to, so make sure all the STM32MP15xx platform DTs are
in sync regarding the mailboxes to fix the detach issue and the warning:
"
stm32-rproc 10000000.m4: mbox_request_channel_byname() could not locate channel named "detach" "
--- arch/arm/boot/dts/st/stm32mp15xx-dhcom-som.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm/boot/dts/st/stm32mp15xx-dhcom-som.dtsi +2 -2
@@ -416,8 +416,8 @@ &iwdg2 { &m4_rproc { memory-region = <&retram>, <&mcuram>, <&mcuram2>, <&vdev0vring0>, <&vdev0vring1>, <&vdev0buffer>; - mboxes = <&ipcc 0>, <&ipcc 1>, <&ipcc 2>; - mbox-names = "vq0", "vq1", "shutdown"; + mboxes = <&ipcc 0>, <&ipcc 1>, <&ipcc 2>, <&ipcc 3>; + mbox-names = "vq0", "vq1", "shutdown", "detach"; interrupt-parent = <&exti>; interrupts = <68 1>; status = "okay";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 243/739 ARM: dts: stm32: Add missing detach mailbox for DHCOR SoM
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Marek Vasut <[email protected]>
[ Upstream commit 2f38de940f072db369edd3e6e8d82bb8f42c5c9b ]
Add missing "detach" mailbox to this board to permit the CPU to inform the remote processor on a detach. This signal allows the remote processor firmware to stop IPC communication and to reinitialize the resources for a re-attach.
Without this mailbox, detach is not possible and kernel log contains the following warning to, so make sure all the STM32MP15xx platform DTs are
in sync regarding the mailboxes to fix the detach issue and the warning:
"
stm32-rproc 10000000.m4: mbox_request_channel_byname() could not locate channel named "detach" "
--- arch/arm/boot/dts/st/stm32mp15xx-dhcor-som.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm/boot/dts/st/stm32mp15xx-dhcor-som.dtsi +2 -2
@@ -227,8 +227,8 @@ &iwdg2 { &m4_rproc { memory-region = <&retram>, <&mcuram>, <&mcuram2>, <&vdev0vring0>, <&vdev0vring1>, <&vdev0buffer>; - mboxes = <&ipcc 0>, <&ipcc 1>, <&ipcc 2>; - mbox-names = "vq0", "vq1", "shutdown"; + mboxes = <&ipcc 0>, <&ipcc 1>, <&ipcc 2>, <&ipcc 3>; + mbox-names = "vq0", "vq1", "shutdown", "detach"; interrupt-parent = <&exti>; interrupts = <68 1>; status = "okay";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 244/739 firmware: ti_sci: Use system_state to determine polling
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Nishanth Menon <[email protected]>
[ Upstream commit 9225bcdedf16297a346082e7d23b0e8434aa98ed ]
Commit b9e8a7d950ff ("firmware: ti_sci: Switch transport to polled mode during system suspend") aims to resolve issues with tisci operations during system suspend operation. However, the system may enter a no_irq stage in various other usage modes, including power-off and restart. To determine if polling mode is appropriate, use the system_state instead.
While at this, drop the unused is_suspending state variable and related helpers.
--- drivers/firmware/ti_sci.c | 36 ++---------------------------------- 1 file changed, 2 insertions(+), 34 deletions(-)
drivers/firmware/ti_sci.c +2 -34
@@ -97,7 +97,6 @@ struct ti_sci_desc {* @node: list head * @host_id: Host ID * @users: Number of users of this instance -* @is_suspending: Flag set to indicate in suspend path. */ struct ti_sci_info {struct device *dev;
@@ -116,7 +115,6 @@ struct ti_sci_info {u8 host_id;/* protected by ti_sci_list_mutex */ int users; -bool is_suspending; };#define cl_to_ti_sci_info (c) container_of(c, struct ti_sci_info, cl)
@@ -418,14 +416,14 @@ static inline int ti_sci_do_xfer(struct ti_sci_info *info, ret =0 ; -if (!info->is_suspending) { +if (system_state <=SYSTEM_RUNNING ) {/* And we wait for the response. */ timeout =msecs_to_jiffies (info->desc->max_rx_timeout_ms);if (!wait_for_completion_timeout (&xfer->done, timeout)) ret = -ETIMEDOUT ; }else {/* -* If we are suspending, we cannot use wait_for_completion_timeout +* If we are !running, we cannot use wait_for_completion_timeout * during noirq phase, so we must manually poll the completion. */ ret = read_poll_timeout_atomic(try_wait_for_completion, done_state,
@@ -3281,35 +3279,6 @@ static int tisci_reboot_handler(struct notifier_block *nb, unsigned long mode,return NOTIFY_BAD ; } -static void ti_sci_set_is_suspending (struct ti_sci_info *info,bool is_suspending) -{ - info->is_suspending = is_suspending; -} - -static int ti_sci_suspend (struct device *dev) -{ -struct ti_sci_info *info =dev_get_drvdata (dev); -/* -* We must switch operation to polled mode now as drivers and the genpd -* layer may make late TI SCI calls to change clock and device states -* from the noirq phase of suspend. -*/ -ti_sci_set_is_suspending (info, true); - -return 0 ; -} - -static int ti_sci_resume (struct device *dev) -{ -struct ti_sci_info *info =dev_get_drvdata (dev); - -ti_sci_set_is_suspending (info, false); - -return 0 ; -} - -static DEFINE_SIMPLE_DEV_PM_OPS(ti_sci_pm_ops, ti_sci_suspend, ti_sci_resume); -/* Description for K2G */ static const struct ti_sci_desc ti_sci_pmmc_k2g_desc = { .default_host_id =2 ,
@@ -3516,7 +3485,6 @@ static struct platform_driver ti_sci_driver = { .driver = { .name = "ti-sci", .of_match_table = of_match_ptr(ti_sci_of_match), - .pm = &ti_sci_pm_ops, }, };module_platform_driver (ti_sci_driver);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 245/739 drm/amdgpu: avoid integer overflow warning in amdgpu_device_resize_fb_bar()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Arnd Bergmann <[email protected]>
[ Upstream commit 822130b5e8834ab30ad410cf19a582e5014b9a85 ]
On 32-bit architectures comparing a resource against a value larger than U32_MAX can cause a warning:
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c:1344:18: error: result of comparison of constant 4294967296 with expression of type 'resource_size_t' (aka 'unsigned int') is always false [-Werror,-Wtautological-constant-out-of-range-compare]
res->start > 0x100000000ull)
~~~~~~~~~~ ^ ~~~~~~~~~~~~~~As gcc does not warn about this in dead code, add an IS_ENABLED() check at the start of the function. This will always return success but not actually resize the BAR on 32-bit architectures without high memory, which is exactly what we want here, as the driver can fall back to bank switching the VRAM access.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +3 -0
@@ -1325,6 +1325,9 @@ int amdgpu_device_resize_fb_bar(struct amdgpu_device *adev)u16 cmd;int r; +if (!IS_ENABLED (CONFIG_PHYS_ADDR_T_64BIT )) +return 0 ; +/* Bypass for VF */ if (amdgpu_sriov_vf (adev))return 0 ;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 246/739 ARM: dts: BCM53573: Drop nonexistent "default-off" LED trigger
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rafał Miłecki <[email protected]>
[ Upstream commit be7e1e5b0f67c58ec4be0a54db23b6a4fa6e2116 ]
There is no such trigger documented or implemented in Linux. It was a copy & paste mistake.
This fixes:arch/arm/boot/dts/broadcom/bcm47189-luxul-xap-1440.dtb: leds: led-wlan:linux,default-trigger: 'oneOf' conditional failed, one must be fixed:
'default-off' is not one of ['backlight', 'default-on', 'heartbeat', 'disk-activity', 'disk-read', 'disk-write', 'timer', 'pattern', 'audio-micmute', 'audio-mute', 'bluetooth-power', 'flash', 'kbd-capslock', 'mtd', 'nand-disk', 'none', 'torch', 'usb-gadget', 'usb-host', 'usbport']
'default-off' does not match '^cpu[0-9]*$'
'default-off' does not match '^hci[0-9]+-power$'
'default-off' does not match '^mmc[0-9]+$'
'default-off' does not match '^phy[0-9]+tx$'
From schema: Documentation/devicetree/bindings/leds/leds-gpio.yaml--- arch/arm/boot/dts/broadcom/bcm47189-luxul-xap-1440.dts | 1 - arch/arm/boot/dts/broadcom/bcm47189-luxul-xap-810.dts | 2 -- 2 files changed, 3 deletions(-)
arch/arm/boot/dts/broadcom/bcm47189-luxul-xap-1440.dts +0 -1
@@ -26,7 +26,6 @@ leds { led-wlan { label = "bcm53xx:blue:wlan"; gpios = <&chipcommon 10 GPIO_ACTIVE_LOW>; - linux,default-trigger = "default-off"; }; led-system {
arch/arm/boot/dts/broadcom/bcm47189-luxul-xap-810.dts +0 -2
@@ -26,7 +26,6 @@ leds-0 { led-5ghz { label = "bcm53xx:blue:5ghz"; gpios = <&chipcommon 11 GPIO_ACTIVE_HIGH>; - linux,default-trigger = "default-off"; }; led-system {
@@ -42,7 +41,6 @@ leds-1 { led-2ghz { label = "bcm53xx:blue:2ghz"; gpios = <&pcie0_chipcommon 3 GPIO_ACTIVE_HIGH>; - linux,default-trigger = "default-off"; }; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 247/739 ARM: dts: BCM53573: Drop nonexistent #usb-cells
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rafał Miłecki <[email protected]>
[ Upstream commit 05d2c3d552b8c92fc397377d9d1112fc58e2cd59 ]
Such property simply doesn't exist (is not documented or used anywhere).
This fixes:arch/arm/boot/dts/broadcom/bcm47189-luxul-xap-1440.dtb: usb@d000: Unevaluated properties are not allowed ('#usb-cells' was unexpected)
From schema: Documentation/devicetree/bindings/usb/generic-ohci.yaml
--- arch/arm/boot/dts/broadcom/bcm53573.dtsi | 2 -- 1 file changed, 2 deletions(-)
arch/arm/boot/dts/broadcom/bcm53573.dtsi +0 -2
@@ -156,8 +156,6 @@ ehci_port2: port@2 { }; ohci: usb@d000 { - #usb-cells = <0>; - compatible = "generic-ohci"; reg = <0xd000 0x1000>; interrupt-parent = <&gic>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 248/739 ARM: dts: BCM53573: Add cells sizes to PCIe node
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rafał Miłecki <[email protected]>
[ Upstream commit 3392ef368d9b04622fe758b1079b512664b6110a ]
This fixes:arch/arm/boot/dts/broadcom/bcm47189-luxul-xap-1440.dtb: pcie@2000: '#address-cells' is a required property
From schema: /lib/python3.10/site-packages/dtschema/schemas/pci/pci-bus.yamlarch/arm/boot/dts/broadcom/bcm47189-luxul-xap-1440.dtb: pcie@2000: '#size-cells' is a required property
From schema: /lib/python3.10/site-packages/dtschema/schemas/pci/pci-bus.yaml
Two properties that need to be added later are "device_type" and "ranges". Adding "device_type" on its own causes a new warning and the value of "ranges" needs to be determined yet.
--- arch/arm/boot/dts/broadcom/bcm53573.dtsi | 3 +++ 1 file changed, 3 insertions(+)
arch/arm/boot/dts/broadcom/bcm53573.dtsi +3 -0
@@ -127,6 +127,9 @@ uart0: serial@300 { pcie0: pcie@2000 { reg = <0x00002000 0x1000>; + + #address-cells = <3>; + #size-cells = <2>; }; usb2: usb2@4000 {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 249/739 ARM: dts: BCM53573: Use updated "spi-gpio" binding properties
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rafał Miłecki <[email protected]>
[ Upstream commit 2c0fd6b3d0778ceab40205315ccef74568490f17 ]
Switch away from deprecated properties.
This fixes:arch/arm/boot/dts/broadcom/bcm947189acdbmr.dtb: spi: gpio-sck: False schema does not allow [[3, 21, 0]]
From schema: Documentation/devicetree/bindings/spi/spi-gpio.yamlarch/arm/boot/dts/broadcom/bcm947189acdbmr.dtb: spi: gpio-miso: False schema does not allow [[3, 22, 0]]
From schema: Documentation/devicetree/bindings/spi/spi-gpio.yamlarch/arm/boot/dts/broadcom/bcm947189acdbmr.dtb: spi: gpio-mosi: False schema does not allow [[3, 23, 0]]
From schema: Documentation/devicetree/bindings/spi/spi-gpio.yamlarch/arm/boot/dts/broadcom/bcm947189acdbmr.dtb: spi: 'sck-gpios' is a required property
From schema: Documentation/devicetree/bindings/spi/spi-gpio.yamlarch/arm/boot/dts/broadcom/bcm947189acdbmr.dtb: spi: Unevaluated properties are not allowed ('gpio-miso', 'gpio-mosi', 'gpio-sck' were unexpected)
From schema: Documentation/devicetree/bindings/spi/spi-gpio.yaml
--- arch/arm/boot/dts/broadcom/bcm947189acdbmr.dts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
arch/arm/boot/dts/broadcom/bcm947189acdbmr.dts +3 -3
@@ -60,9 +60,9 @@ button-wps { spi { compatible = "spi-gpio"; num-chipselects = <1>; - gpio-sck = <&chipcommon 21 0>; - gpio-miso = <&chipcommon 22 0>; - gpio-mosi = <&chipcommon 23 0>; + sck-gpios = <&chipcommon 21 0>; + miso-gpios = <&chipcommon 22 0>; + mosi-gpios = <&chipcommon 23 0>; cs-gpios = <&chipcommon 24 0>; #address-cells = <1>; #size-cells = <0>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 250/739 arm64: tegra: Add missing alias for NVIDIA IGX Orin
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jon Hunter <[email protected]>
[ Upstream commit d97966df30ed8c7df0350b8ff6662e38ee88c39f ]
The following error is seen on boot for the NVIDIA IGX Orin platform ...
serial-tegra 3100000.serial: failed to get alias id, errno -19
Fix this by populating the necessary alias for the serial device.
--- arch/arm64/boot/dts/nvidia/tegra234-p3740-0002+p3701-0008.dts | 1 + 1 file changed, 1 insertion(+)
arch/arm64/boot/dts/nvidia/tegra234-p3740-0002+p3701-0008.dts +1 -0
@@ -12,6 +12,7 @@ / { aliases { serial0 = &tcu; + serial1 = &uarta; }; chosen {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 251/739 arm64: tegra: Fix HSUART for Jetson AGX Orin
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jon Hunter <[email protected]>
[ Upstream commit 861dbb2b15b1049113887fb95e856f7123eea0cc ]
After commit 71de0a054d0e ("arm64: tegra: Drop serial clock-names and reset-names") was applied, the HSUART failed to probe and the following error is seen:
serial-tegra 3100000.serial: Couldn't get the reset
serial-tegra: probe of 3100000.serial failed with error -2
Commit 71de0a054d0e ("arm64: tegra: Drop serial clock-names and reset-names") is correct because the "reset-names" property is not needed for 8250 UARTs. However, the "reset-names" is required for the HSUART and should have been populated as part of commit ff578db7b693 ("arm64: tegra: Enable UART instance on 40-pin header") that enabled the HSUART for Jetson AGX Orin. Fix this by populating the "reset-names" property for the HSUART on Jetson AGX Orin.
--- arch/arm64/boot/dts/nvidia/tegra234-p3737-0000+p3701-0000.dts | 1 + 1 file changed, 1 insertion(+)
arch/arm64/boot/dts/nvidia/tegra234-p3737-0000+p3701-0000.dts +1 -0
@@ -2010,6 +2010,7 @@ interrupt-controller@2a40000 { serial@3100000 { compatible = "nvidia,tegra194-hsuart"; + reset-names = "serial"; status = "okay"; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 252/739 arm64: dts: qcom: sm8250-sony-xperia: correct GPIO keys wakeup again
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Krzysztof Kozlowski <[email protected]>
[ Upstream commit b8fbeea0253211d97c579eae787274633d3eaf0d ]
gpio-keys,wakeup is a deprecated property:
m8250-sony-xperia-edo-pdx206.dtb: gpio-keys: key-camera-focus: Unevaluated properties are not allowed ('gpio-key,wakeup' was unexpected)
--- arch/arm64/boot/dts/qcom/sm8250-sony-xperia-edo.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/qcom/sm8250-sony-xperia-edo.dtsi +2 -2
@@ -60,7 +60,7 @@ key-camera-focus { gpios = <&pm8150b_gpios 2 GPIO_ACTIVE_LOW>; debounce-interval = <15>; linux,can-disable; - gpio-key,wakeup; + wakeup-source; }; key-camera-snapshot {
@@ -69,7 +69,7 @@ key-camera-snapshot { gpios = <&pm8150b_gpios 1 GPIO_ACTIVE_LOW>; debounce-interval = <15>; linux,can-disable; - gpio-key,wakeup; + wakeup-source; }; key-vol-down {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 253/739 arm64: dts: qcom: pm6150l: Add missing short interrupt
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 7e1f024ef0d1da456f61d00f01dc3287ede915b3 ]
Add the missing short interrupt. This fixes the schema warning:
wled@d800: interrupt-names: ['ovp'] is too short
--- arch/arm64/boot/dts/qcom/pm6150l.dtsi | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/qcom/pm6150l.dtsi +3 -2
@@ -121,8 +121,9 @@ pm6150l_flash: led-controller@d300 { pm6150l_wled: leds@d800 { compatible = "qcom,pm6150l-wled"; reg = <0xd800>, <0xd900>; - interrupts = <0x5 0xd8 0x1 IRQ_TYPE_EDGE_RISING>; - interrupt-names = "ovp"; + interrupts = <0x5 0xd8 0x1 IRQ_TYPE_EDGE_RISING>, + <0x5 0xd8 0x2 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "ovp", "short"; label = "backlight"; status = "disabled";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 254/739 arm64: dts: qcom: pm660l: Add missing short interrupt
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 9a4ac09db3c7413e334b4abd6b2f6de8930dd781 ]
Add the missing short interrupt. This fixes the schema warning:
wled@d800: interrupt-names: ['ovp'] is too short
--- arch/arm64/boot/dts/qcom/pm660l.dtsi | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/qcom/pm660l.dtsi +3 -2
@@ -74,8 +74,9 @@ pm660l_lpg: pwm { pm660l_wled: leds@d800 { compatible = "qcom,pm660l-wled"; reg = <0xd800>, <0xd900>; - interrupts = <0x3 0xd8 0x1 IRQ_TYPE_EDGE_RISING>; - interrupt-names = "ovp"; + interrupts = <0x3 0xd8 0x1 IRQ_TYPE_EDGE_RISING>, + <0x3 0xd8 0x2 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "ovp", "short"; label = "backlight"; status = "disabled";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 255/739 arm64: dts: qcom: pmi8950: Add missing OVP interrupt
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 4d77b639531fd85b84a7079c3369908dfaddf8b2 ]
Add the missing OVP interrupt. This fixes the schema warning:
wled@d800: interrupt-names: ['short'] is too short
--- arch/arm64/boot/dts/qcom/pmi8950.dtsi | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/qcom/pmi8950.dtsi +3 -2
@@ -87,8 +87,9 @@ pmic@3 { pmi8950_wled: leds@d800 { compatible = "qcom,pmi8950-wled"; reg = <0xd800>, <0xd900>; - interrupts = <0x3 0xd8 0x02 IRQ_TYPE_EDGE_RISING>; - interrupt-names = "short"; + interrupts = <0x3 0xd8 0x1 IRQ_TYPE_EDGE_RISING>, + <0x3 0xd8 0x2 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "ovp", "short"; label = "backlight"; status = "disabled";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 256/739 arm64: dts: qcom: pmi8994: Add missing OVP interrupt
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 8db94432690371b1736e9a2566a9b3d8a73d5a97 ]
Add the missing OVP interrupt. This fixes the schema warning:
wled@d800: interrupt-names: ['short'] is too short
--- arch/arm64/boot/dts/qcom/pmi8994.dtsi | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/qcom/pmi8994.dtsi +3 -2
@@ -54,8 +54,9 @@ pmi8994_spmi_regulators: regulators { pmi8994_wled: wled@d800 { compatible = "qcom,pmi8994-wled"; reg = <0xd800>, <0xd900>; - interrupts = <3 0xd8 0x02 IRQ_TYPE_EDGE_RISING>; - interrupt-names = "short"; + interrupts = <0x3 0xd8 0x1 IRQ_TYPE_EDGE_RISING>, + <0x3 0xd8 0x2 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "ovp", "short"; qcom,cabc; qcom,external-pfet; status = "disabled";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 257/739 arm64: dts: qcom: sc8180x: Add missing cache-unified to L3
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit e4322bb818bbcd36b441de9880fa4ac911a5eb51 ]
Add the missing property to fix the dt checker warning:
qcom/sc8180x-primus.dtb: l3-cache: 'cache-unified' is a required property
--- arch/arm64/boot/dts/qcom/sc8180x.dtsi | 1 + 1 file changed, 1 insertion(+)
arch/arm64/boot/dts/qcom/sc8180x.dtsi +1 -0
@@ -64,6 +64,7 @@ L2_0: l2-cache { L3_0: l3-cache { compatible = "cache"; cache-level = <3>; + cache-unified; }; }; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 258/739 arm64: tegra: Fix HSUART for Smaug
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Diogo Ivo <[email protected]>
[ Upstream commit 590bfe51838f6345a6a3288507661dc9b7208464 ]
After commit 71de0a054d0e ("arm64: tegra: Drop serial clock-names and reset-names") was applied, the HSUART failed to probe and the following error is seen:
serial-tegra 70006300.serial: Couldn't get the reset
serial-tegra: probe of 70006300.serial failed with error -2
Commit 71de0a054d0e ("arm64: tegra: Drop serial clock-names and reset-names") is correct because the "reset-names" property is not needed for 8250 UARTs. However, the "reset-names" is required for the HSUART and should have been populated as part of commit a63c0cd83720c ("arm64: dts: tegra: smaug: Add Bluetooth node") that enabled the HSUART for the Pixel C. Fix this by populating the "reset-names" property for the HSUART on the Pixel C.
--- arch/arm64/boot/dts/nvidia/tegra210-smaug.dts | 1 + 1 file changed, 1 insertion(+)
arch/arm64/boot/dts/nvidia/tegra210-smaug.dts +1 -0
@@ -1317,6 +1317,7 @@ serial@70006000 { uartd: serial@70006300 { compatible = "nvidia,tegra30-hsuart"; + reset-names = "serial"; status = "okay"; bluetooth {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 259/739 drm/etnaviv: fix dumping of active MMU context
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Lucas Stach <[email protected]>
[ Upstream commit 20faf2005ec85fa1a6acc9a74ff27de667f90576 ]
gpu->mmu_context is the MMU context of the last job in the HW queue, which isn't necessarily the same as the context from the bad job. Dump the MMU context from the scheduler determined bad submit to make it work as intended.
--- drivers/gpu/drm/etnaviv/etnaviv_dump.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-)
drivers/gpu/drm/etnaviv/etnaviv_dump.c +7 -7
@@ -130,9 +130,9 @@ void etnaviv_core_dump(struct etnaviv_gem_submit *submit)return ; etnaviv_dump_core = false; -mutex_lock (&gpu->mmu_context->lock); +mutex_lock (&submit->mmu_context->lock); - mmu_size =etnaviv_iommu_dump_size (gpu->mmu_context); + mmu_size =etnaviv_iommu_dump_size (submit->mmu_context);/* We always dump registers, mmu, ring, hanging cmdbuf and end marker */ n_obj =5 ;
@@ -162,7 +162,7 @@ void etnaviv_core_dump(struct etnaviv_gem_submit *submit) iter.start =__vmalloc (file_size,GFP_KERNEL | __GFP_NOWARN | __GFP_NORETRY);if (!iter.start) { -mutex_unlock (&gpu->mmu_context->lock); +mutex_unlock (&submit->mmu_context->lock);dev_warn (gpu->dev,"failed to allocate devcoredump file\n" );return ; }
@@ -174,18 +174,18 @@ void etnaviv_core_dump(struct etnaviv_gem_submit *submit)memset (iter.hdr,0 , iter.data - iter.start);etnaviv_core_dump_registers (&iter, gpu); -etnaviv_core_dump_mmu (&iter, gpu->mmu_context, mmu_size); +etnaviv_core_dump_mmu (&iter, submit->mmu_context, mmu_size);etnaviv_core_dump_mem (&iter,ETDUMP_BUF_RING , gpu->buffer.vaddr, gpu->buffer.size,etnaviv_cmdbuf_get_va (&gpu->buffer, - &gpu->mmu_context->cmdbuf_mapping)); + &submit->mmu_context->cmdbuf_mapping));etnaviv_core_dump_mem (&iter,ETDUMP_BUF_CMD , submit->cmdbuf.vaddr, submit->cmdbuf.size,etnaviv_cmdbuf_get_va (&submit->cmdbuf, - &gpu->mmu_context->cmdbuf_mapping)); + &submit->mmu_context->cmdbuf_mapping)); -mutex_unlock (&gpu->mmu_context->lock); +mutex_unlock (&submit->mmu_context->lock);/* Reserve space for the bomap */ if (n_bomap_pages) {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 260/739 block: cleanup queue_wc_store
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christoph Hellwig <[email protected]>
[ Upstream commit c4e21bcd0f9d01f9c5d6c52007f5541871a5b1de ]
Get rid of the local queue_wc_store variable and handling setting and clearing the QUEUE_FLAG_WC flag diretly instead the if / else if.
Stable-dep-of: 43c9835b144c ("block: don't allow enabling a cache on devices that don't support it")
--- block/blk-sysfs.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-)
block/blk-sysfs.c +3 -11
@@ -449,21 +449,13 @@ static ssize_t queue_wc_show(struct request_queue *q, char *page)static ssize_t queue_wc_store (struct request_queue *q,const char *page,size_t count) { -int set =-1 ; -if (!strncmp (page,"write back" ,10 )) - set =1 ; +blk_queue_flag_set (QUEUE_FLAG_WC , q);else if (!strncmp (page,"write through" ,13 ) || !strncmp (page,"none" ,4 )) - set =0 ; - -if (set ==-1 ) -return -EINVAL ; - -if (set) -blk_queue_flag_set (QUEUE_FLAG_WC , q); -else blk_queue_flag_clear (QUEUE_FLAG_WC , q); +else +return -EINVAL ;return count; }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 261/739 block: dont allow enabling a cache on devices that dont support it
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christoph Hellwig <[email protected]>
[ Upstream commit 43c9835b144c7ce29efe142d662529662a9eb376 ]
Currently the write_cache attribute allows enabling the QUEUE_FLAG_WC flag on devices that never claimed the capability.
Fix that by adding a QUEUE_FLAG_HW_WC flag that is set by blk_queue_write_cache and guards re-enabling the cache through sysfs.
Note that any rescan that calls blk_queue_write_cache will still re-enable the write cache as in the current code.
--- block/blk-settings.c | 7 +++++-- block/blk-sysfs.c | 11 +++++++---- include/linux/blkdev.h | 1 + 3 files changed, 13 insertions(+), 6 deletions(-)
block/blk-settings.c +5 -2
@@ -830,10 +830,13 @@ EXPORT_SYMBOL(blk_set_queue_depth);*/ void blk_queue_write_cache (struct request_queue *q,bool wc,bool fua) { -if (wc) +if (wc) { +blk_queue_flag_set (QUEUE_FLAG_HW_WC , q);blk_queue_flag_set (QUEUE_FLAG_WC , q); -else + }else { +blk_queue_flag_clear (QUEUE_FLAG_HW_WC , q);blk_queue_flag_clear (QUEUE_FLAG_WC , q); + }if (fua)blk_queue_flag_set (QUEUE_FLAG_FUA , q);else
block/blk-sysfs.c +7 -4
@@ -449,13 +449,16 @@ static ssize_t queue_wc_show(struct request_queue *q, char *page)static ssize_t queue_wc_store (struct request_queue *q,const char *page,size_t count) { -if (!strncmp (page,"write back" ,10 )) +if (!strncmp (page,"write back" ,10 )) { +if (!test_bit (QUEUE_FLAG_HW_WC , &q->queue_flags)) +return -EINVAL ;blk_queue_flag_set (QUEUE_FLAG_WC , q); -else if (!strncmp (page,"write through" ,13 ) || - !strncmp (page,"none" ,4 )) + }else if (!strncmp (page,"write through" ,13 ) || + !strncmp (page,"none" ,4 )) {blk_queue_flag_clear (QUEUE_FLAG_WC , q); -else + }else {return -EINVAL ; + }return count; }
include/linux/blkdev.h +1 -0
@@ -538,6 +538,7 @@ struct request_queue {#define QUEUE_FLAG_ADD_RANDOM 10/* Contributes to random pool */ #define QUEUE_FLAG_SYNCHRONOUS 11/* always completes in submit context */ #define QUEUE_FLAG_SAME_FORCE 12/* force complete on same CPU */ +#define QUEUE_FLAG_HW_WC 18/* Write back caching supported */ #define QUEUE_FLAG_INIT_DONE 14/* queue is initialized */ #define QUEUE_FLAG_STABLE_WRITES 15/* don't modify blks until WB is done */ #define QUEUE_FLAG_POLL 16/* IO polling enabled if set */
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 262/739 blk-flush: fix rq->flush.seq for post-flush requests
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Chengming Zhou <[email protected]>
[ Upstream commit 28b241237470981a96fbd82077c8044466b61e5f ]
If the policy == (REQ_FSEQ_DATA | REQ_FSEQ_POSTFLUSH), it means that the data sequence and post-flush sequence need to be done for this request.
The rq->flush.seq should record what sequences have been done (or don't need to be done). So in this case, pre-flush doesn't need to be done, we should init rq->flush.seq to REQ_FSEQ_PREFLUSH not REQ_FSEQ_POSTFLUSH.
--- block/blk-flush.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
block/blk-flush.c +1 -1
@@ -443,7 +443,7 @@ bool blk_insert_flush(struct request *rq)* the post flush, and then just pass the command on. */ blk_rq_init_flush (rq); - rq->flush.seq |=REQ_FSEQ_POSTFLUSH ; + rq->flush.seq |=REQ_FSEQ_PREFLUSH ;spin_lock_irq (&fq->mq_flush_lock);list_move_tail (&rq->flush.list, &fq->flush_data_in_flight);spin_unlock_irq (&fq->mq_flush_lock);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 263/739 x86/mm: Fix PAT bit missing from page protection modify mask
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Janusz Krzysztofik <[email protected]>
[ Upstream commit 548cb932051fb6232ac983ed6673dae7bdf3cf4c ]
Visible glitches have been observed when running graphics applications on Linux under Xen hypervisor. Those observations have been confirmed with failures from kms_pwrite_crc Intel GPU test that verifies data coherency of DRM frame buffer objects using hardware CRC checksums calculated by display controllers, exposed to userspace via debugfs. Affected processing paths have then been identified with new IGT test variants that mmap the objects using different methods and caching modes [1].
When running as a Xen PV guest, Linux uses Xen provided PAT configuration which is different from its native one. In particular, Xen specific PTE encoding of write-combining caching, likely used by graphics applications, differs from the Linux default one found among statically defined minimal set of supported modes. Since Xen defines PTE encoding of the WC mode as _PAGE_PAT, it no longer belongs to the minimal set, depends on correct handling of _PAGE_PAT bit, and can be mismatched with write-back caching.
When a user calls mmap() for a DRM buffer object, DRM device specific .mmap file operation, called from mmap_region(), takes care of setting PTE encoding bits in a vm_page_prot field of an associated virtual memory area structure. Unfortunately, _PAGE_PAT bit is not preserved when the vma's .vm_flags are then applied to .vm_page_prot via vm_set_page_prot(). Bits to be preserved are determined with _PAGE_CHG_MASK symbol that doesn't cover _PAGE_PAT. As a consequence, WB caching is requested instead of WC when running under Xen (also, WP is silently changed to WT, and UC downgraded to UC_MINUS). When running on bare metal, WC is not affected, but WP and WT extra modes are unintentionally replaced with WC and UC, respectively.
WP and WT modes, encoded with _PAGE_PAT bit set, were introduced by commit 281d4078bec3 ("x86: Make page cache mode a real type"). Care was taken to extend _PAGE_CACHE_MASK symbol with that additional bit, but that symbol has never been used for identification of bits preserved when applying page protection flags. Support for all cache modes under Xen, including the problematic WC mode, was then introduced by commit 47591df50512 ("xen: Support Xen pv-domains using PAT").
The issue needs to be fixed by including _PAGE_PAT bit into a bitmask used by pgprot_modify() for selecting bits to be preserved. We can do that either internally to pgprot_modify() (as initially proposed), or by making _PAGE_PAT a part of _PAGE_CHG_MASK. If we go for the latter then, since _PAGE_PAT is the same as _PAGE_PSE, we need to note that _HPAGE_CHG_MASK -- a huge pmds' counterpart of _PAGE_CHG_MASK, introduced by commit c489f1257b8c ("thp: add pmd_modify"), defined as (_PAGE_CHG_MASK | _PAGE_PSE) -- will no longer differ from _PAGE_CHG_MASK. If such modification of _PAGE_CHG_MASK was irrelevant to its users then one might wonder why that new _HPAGE_CHG_MASK symbol was introduced instead of reusing the existing one with that otherwise irrelevant bit (_PAGE_PSE in that case) added.
Add _PAGE_PAT to _PAGE_CHG_MASK and _PAGE_PAT_LARGE to _HPAGE_CHG_MASK for symmetry. Split out common bits from both symbols to a common symbol for clarity.
[ dhansen: tweak the solution changelog description ]
[1] https://gitlab.freedesktop.org/drm/igt-gpu-tools/-/commit/0f0754413f14
--- arch/x86/include/asm/pgtable_types.h | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-)
arch/x86/include/asm/pgtable_types.h +6 -5
@@ -125,11 +125,12 @@* instance, and is *not* included in this mask since * pte_modify() does modify it. */ -#define _PAGE_CHG_MASK (PTE_PFN_MASK | _PAGE_PCD | _PAGE_PWT | \ - _PAGE_SPECIAL | _PAGE_ACCESSED | _PAGE_DIRTY | \ - _PAGE_SOFT_DIRTY | _PAGE_DEVMAP | _PAGE_ENC | \ - _PAGE_UFFD_WP) -#define _HPAGE_CHG_MASK (_PAGE_CHG_MASK | _PAGE_PSE) +#define _COMMON_PAGE_CHG_MASK (PTE_PFN_MASK | _PAGE_PCD | _PAGE_PWT | \ + _PAGE_SPECIAL | _PAGE_ACCESSED | _PAGE_DIRTY |\ + _PAGE_SOFT_DIRTY | _PAGE_DEVMAP | _PAGE_ENC | \ + _PAGE_UFFD_WP) +#define _PAGE_CHG_MASK (_COMMON_PAGE_CHG_MASK | _PAGE_PAT) +#define _HPAGE_CHG_MASK (_COMMON_PAGE_CHG_MASK | _PAGE_PSE | _PAGE_PAT_LARGE)/* * The cache modes defined here are used to translate between pure SW usage
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 264/739 drm/bridge: anx7625: Use common macros for DP power sequencing commands
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Chen-Yu Tsai <[email protected]>
[ Upstream commit 2ba776f903cb7157e80b5f314fb0b4faf6ea6958 ]
The DRM DP code has macros for the DP power sequencing commands. Use them in the anx7625 driver instead of raw numbers.
--- drivers/gpu/drm/bridge/analogix/anx7625.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/gpu/drm/bridge/analogix/anx7625.c +4 -4
@@ -931,8 +931,8 @@ static void anx7625_dp_start(struct anx7625_data *ctx)dev_dbg (dev,"set downstream sink into normal\n" );/* Downstream sink enter into normal mode */ - data =1 ; - ret =anx7625_aux_trans (ctx,DP_AUX_NATIVE_WRITE ,0x000600 ,1 , &data); + data =DP_SET_POWER_D0 ; + ret =anx7625_aux_trans (ctx,DP_AUX_NATIVE_WRITE ,DP_SET_POWER ,1 , &data);if (ret <0 )dev_err (dev,"IO error : set sink into normal mode fail\n" );
@@ -971,8 +971,8 @@ static void anx7625_dp_stop(struct anx7625_data *ctx)dev_dbg (dev,"notify downstream enter into standby\n" );/* Downstream monitor enter into standby mode */ - data =2 ; - ret |=anx7625_aux_trans (ctx,DP_AUX_NATIVE_WRITE ,0x000600 ,1 , &data); + data =DP_SET_POWER_D3 ; + ret |=anx7625_aux_trans (ctx,DP_AUX_NATIVE_WRITE ,DP_SET_POWER ,1 , &data);if (ret <0 )DRM_DEV_ERROR (dev,"IO error : mute video fail\n" );
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 265/739 drm/bridge: anx7625: Use common macros for HDCP capabilities
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Chen-Yu Tsai <[email protected]>
[ Upstream commit 41639b3a8b0f1f194dfe0577d99db70613f78626 ]
The DRM DP code has macros for the DP HDCP capabilities. Use them in the anx7625 driver instead of raw numbers.
--- drivers/gpu/drm/bridge/analogix/anx7625.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/bridge/analogix/anx7625.c +2 -2
@@ -872,11 +872,11 @@ static int anx7625_hdcp_enable(struct anx7625_data *ctx) }/* Read downstream capability */ - ret =anx7625_aux_trans (ctx,DP_AUX_NATIVE_READ ,0x68028 ,1 , &bcap); + ret =anx7625_aux_trans (ctx,DP_AUX_NATIVE_READ ,DP_AUX_HDCP_BCAPS ,1 , &bcap);if (ret <0 )return ret; -if (!(bcap &0x01 )) { +if (!(bcap &DP_BCAPS_HDCP_CAPABLE )) {pr_warn ("downstream not support HDCP 1.4, cap(%x).\n" , bcap);return 0 ; }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 266/739 ARM: dts: samsung: s3c6410-mini6410: correct ethernet reg addresses (split)
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Krzysztof Kozlowski <[email protected]>
[ Upstream commit cf0cb2af6a18f28b84f9f1416bff50ca60d6e98a ]
The davicom,dm9000 Ethernet Controller accepts two reg addresses.
--- arch/arm/boot/dts/samsung/s3c6410-mini6410.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/samsung/s3c6410-mini6410.dts +1 -1
@@ -51,7 +51,7 @@ srom-cs1-bus@18000000 { ethernet@18000000 { compatible = "davicom,dm9000"; - reg = <0x18000000 0x2 0x18000004 0x2>; + reg = <0x18000000 0x2>, <0x18000004 0x2>; interrupt-parent = <&gpn>; interrupts = <7 IRQ_TYPE_LEVEL_HIGH>; davicom,no-eeprom;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 267/739 ARM: dts: samsung: s5pv210-smdkv210: correct ethernet reg addresses (split)
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Krzysztof Kozlowski <[email protected]>
[ Upstream commit 982655cb0e7f18934d7532c32366e574ad61dbd7 ]
The davicom,dm9000 Ethernet Controller accepts two reg addresses.
--- arch/arm/boot/dts/samsung/s5pv210-smdkv210.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/samsung/s5pv210-smdkv210.dts +1 -1
@@ -41,7 +41,7 @@ pmic_ap_clk: clock-0 { ethernet@a8000000 { compatible = "davicom,dm9000"; - reg = <0xA8000000 0x2 0xA8000002 0x2>; + reg = <0xa8000000 0x2>, <0xa8000002 0x2>; interrupt-parent = <&gph1>; interrupts = <1 IRQ_TYPE_LEVEL_HIGH>; local-mac-address = [00 00 de ad be ef];
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 268/739 drm: adv7511: Fix low refresh rate register for ADV7533/5
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Bogdan Togorean <[email protected]>
[ Upstream commit d281eeaa4de2636ff0c8e6ae387bb07b50e5fcbb ]
For ADV7533 and ADV7535 low refresh rate is selected using bits [3:2] of 0x4a main register.
So depending on ADV model write 0xfb or 0x4a register.
--- drivers/gpu/drm/bridge/adv7511/adv7511_drv.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-)
drivers/gpu/drm/bridge/adv7511/adv7511_drv.c +7 -2
@@ -786,8 +786,13 @@ static void adv7511_mode_set(struct adv7511 *adv7511,else low_refresh_rate =ADV7511_LOW_REFRESH_RATE_NONE ; -regmap_update_bits (adv7511->regmap,0xfb , -0x6 , low_refresh_rate <<1 ); +if (adv7511->type ==ADV7511 ) +regmap_update_bits (adv7511->regmap,0xfb , +0x6 , low_refresh_rate <<1 ); +else +regmap_update_bits (adv7511->regmap,0x4a , +0xc , low_refresh_rate <<2 ); +regmap_update_bits (adv7511->regmap,0x17 ,0x60 , (vsync_polarity <<6 ) | (hsync_polarity <<5 ));
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 269/739 ARM: dts: BCM53573: Fix Ethernet info for Luxul devices
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rafał Miłecki <[email protected]>
[ Upstream commit 44ad8207806973f4e4f7d870fff36cc01f494250 ]
Both Luxul's XAP devices (XAP-810 and XAP-1440) are access points that use a non-default design. They don't include switch but have a single Ethernet port and BCM54210E PHY connected to the Ethernet controller's MDIO bus.
Support for those devices regressed due to two changes:
1. Describing MDIO bus with switch
After commit 9fb90ae6cae7 ("ARM: dts: BCM53573: Describe on-SoC BCM53125 rev 4 switch") Linux stopped probing for MDIO devices.
2. Dropping hardcoded BCM54210E delays
In commit fea7fda7f50a ("net: phy: broadcom: Fix RGMII delays configuration for BCM54210E") support for other PHY modes was added but that requires a proper "phy-mode" value in DT.
Both above changes are correct (they don't need to be reverted or anything) but they need this fix for DT data to be correct and for Linux to work properly.
--- .../boot/dts/broadcom/bcm47189-luxul-xap-1440.dts | 13 +++++++++++++ .../boot/dts/broadcom/bcm47189-luxul-xap-810.dts | 13 +++++++++++++ 2 files changed, 26 insertions(+)
arch/arm/boot/dts/broadcom/bcm47189-luxul-xap-1440.dts +13 -0
@@ -45,3 +45,16 @@ button-restart { }; }; }; + +&gmac0 { + phy-mode = "rgmii"; + phy-handle = <&bcm54210e>; + + mdio { + /delete-node/ switch@1e; + + bcm54210e: ethernet-phy@0 { + reg = <0>; + }; + }; +};
arch/arm/boot/dts/broadcom/bcm47189-luxul-xap-810.dts +13 -0
@@ -81,3 +81,16 @@ pcie0_chipcommon: chipcommon@0 { }; }; }; + +&gmac0 { + phy-mode = "rgmii"; + phy-handle = <&bcm54210e>; + + mdio { + /delete-node/ switch@1e; + + bcm54210e: ethernet-phy@0 { + reg = <0>; + }; + }; +};
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 270/739 arm64: dts: qcom: sdm845: Add missing RPMh power domain to GCC
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Manivannan Sadhasivam <[email protected]>
[ Upstream commit 4b6ea15c0a1122422b44bf6c47a3c22fc8d46777 ]
GCC and it's GDSCs are under the RPMh CX power domain. So let's add the missing RPMh power domain to the GCC node.
--- arch/arm64/boot/dts/qcom/sdm845.dtsi | 1 + 1 file changed, 1 insertion(+)
arch/arm64/boot/dts/qcom/sdm845.dtsi +1 -0
@@ -1207,6 +1207,7 @@ gcc: clock-controller@100000 { #clock-cells = <1>; #reset-cells = <1>; #power-domain-cells = <1>; + power-domains = <&rpmhpd SDM845_CX>; }; qfprom@784000 {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 271/739 arm64: dts: qcom: sdm845: Fix the min frequency of "ice_core_clk"
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Manivannan Sadhasivam <[email protected]>
[ Upstream commit bbbef6e24bc4493602df68b052f6f48d48e3184a ]
Minimum frequency of the "ice_core_clk" should be 75MHz as specified in the downstream vendor devicetree. So fix it!
--- arch/arm64/boot/dts/qcom/sdm845.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/sdm845.dtsi +1 -1
@@ -2614,7 +2614,7 @@ ufs_mem_hc: ufshc@1d84000 { <0 0>, <0 0>, <0 0>, - <0 300000000>; + <75000000 300000000>; status = "disabled"; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 272/739 arm64: dts: qcom: sc8180x: Fix LLCC reg property
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Bjorn Andersson <[email protected]>
[ Upstream commit 74cf6675c35ec3034053a69926f4d98e52852eb0 ]
The LLCC binding and driver was recently corrected to handle the stride varying between platforms. Switch to the new format to ensure accesses are done in the right place.
--- arch/arm64/boot/dts/qcom/sc8180x.dtsi | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/qcom/sc8180x.dtsi +5 -2
@@ -2542,8 +2542,11 @@ usb_sec_dpphy: dp-phy@88ef200 { system-cache-controller@9200000 { compatible = "qcom,sc8180x-llcc"; - reg = <0 0x09200000 0 0x50000>, <0 0x09600000 0 0x50000>; - reg-names = "llcc_base", "llcc_broadcast_base"; + reg = <0 0x09200000 0 0x50000>, <0 0x09280000 0 0x50000>, + <0 0x09300000 0 0x50000>, <0 0x09380000 0 0x50000>, + <0 0x09600000 0 0x50000>; + reg-names = "llcc0_base", "llcc1_base", "llcc2_base", + "llcc3_base", "llcc_broadcast_base"; interrupts = <GIC_SPI 582 IRQ_TYPE_LEVEL_HIGH>; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 273/739 arm64: dts: qcom: msm8996-gemini: fix touchscreen VIO supply
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Krzysztof Kozlowski <[email protected]>
[ Upstream commit 21fc24ee9c5943732c9ae538766c9be93d70d936 ]
According to bindings and Linux driver, there is no VDDA but VIO supply.
--- arch/arm64/boot/dts/qcom/msm8996-xiaomi-gemini.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/msm8996-xiaomi-gemini.dts +1 -1
@@ -82,7 +82,7 @@ synaptics@20 { #size-cells = <0>; interrupt-parent = <&tlmm>; interrupts = <125 IRQ_TYPE_LEVEL_LOW>; - vdda-supply = <&vreg_l6a_1p8>; + vio-supply = <&vreg_l6a_1p8>; vdd-supply = <&vdd_3v2_tp>; reset-gpios = <&tlmm 89 GPIO_ACTIVE_LOW>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 274/739 arm64: dts: qcom: sc8180x-pmics: add missing qcom,spmi-gpio fallbacks
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Krzysztof Kozlowski <[email protected]>
[ Upstream commit 0304fc1de3d930db83749cca6ccb3a4f89918fc4 ]
The GPIO children of PMICs should use qcom,spmi-gpio fallback:
sc8180x-primus.dtb: pmic@0: gpio@c000:compatible: ['qcom,pmc8180-gpio'] is too short
--- arch/arm64/boot/dts/qcom/sc8180x-pmics.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/qcom/sc8180x-pmics.dtsi +2 -2
@@ -142,7 +142,7 @@ rtc@6000 { }; pmc8180_gpios: gpio@c000 { - compatible = "qcom,pmc8180-gpio"; + compatible = "qcom,pmc8180-gpio", "qcom,spmi-gpio"; reg = <0xc000>; gpio-controller; #gpio-cells = <2>;
@@ -300,7 +300,7 @@ pmc8180c_adc_tm: adc-tm@3500 { }; pmc8180c_gpios: gpio@c000 { - compatible = "qcom,pmc8180c-gpio"; + compatible = "qcom,pmc8180c-gpio", "qcom,spmi-gpio"; reg = <0xc000>; gpio-controller; #gpio-cells = <2>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 275/739 arm64: dts: qcom: sc8180x-pmics: add missing gpio-ranges
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Krzysztof Kozlowski <[email protected]>
[ Upstream commit 565951b1202e1984154abaae4567f16f8073fca3 ]
The GPIO children of PMICs should use gpio-ranges:
sc8180x-primus.dtb: pmic@0: gpio@c000: 'gpio-ranges' is a required property
--- arch/arm64/boot/dts/qcom/sc8180x-pmics.dtsi | 2 ++ 1 file changed, 2 insertions(+)
arch/arm64/boot/dts/qcom/sc8180x-pmics.dtsi +2 -0
@@ -145,6 +145,7 @@ pmc8180_gpios: gpio@c000 { compatible = "qcom,pmc8180-gpio", "qcom,spmi-gpio"; reg = <0xc000>; gpio-controller; + gpio-ranges = <&pmc8180_gpios 0 0 10>; #gpio-cells = <2>; interrupt-controller; #interrupt-cells = <2>;
@@ -303,6 +304,7 @@ pmc8180c_gpios: gpio@c000 { compatible = "qcom,pmc8180c-gpio", "qcom,spmi-gpio"; reg = <0xc000>; gpio-controller; + gpio-ranges = <&pmc8180c_gpios 0 0 12>; #gpio-cells = <2>; interrupt-controller; #interrupt-cells = <2>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 276/739 arm64: dts: qcom: sc8180x-pmics: align SPMI PMIC Power-on node name with dtschema
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Krzysztof Kozlowski <[email protected]>
[ Upstream commit bf520227bd32381c587fa36271475e035daab3d7 ]
Bindings expect the Power-on node name to be "pon":
sc8180x-lenovo-flex-5g.dtb: pmic@0: 'power-on@800' does not match any of the regexes:
--- arch/arm64/boot/dts/qcom/sc8180x-pmics.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/qcom/sc8180x-pmics.dtsi +2 -2
@@ -74,7 +74,7 @@ pmc8180_0: pmic@0 { #address-cells = <1>; #size-cells = <0>; - pon: power-on@800 { + pon: pon@800 { compatible = "qcom,pm8916-pon"; reg = <0x0800>; pwrkey {
@@ -247,7 +247,7 @@ pmic@4 { #address-cells = <1>; #size-cells = <0>; - power-on@800 { + pon@800 { compatible = "qcom,pm8916-pon"; reg = <0x0800>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 277/739 arm64: dts: qcom: sc8180x-pmics: align LPG node name with dtschema
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Krzysztof Kozlowski <[email protected]>
[ Upstream commit 4af302a7e29e70bd930e80ab8f967da48a99a31a ]
Bindings expect the LPG node name to be "pwm":
sc8180x-lenovo-flex-5g.dtb: pmic@5: 'lpg' does not match any of the regexes:
--- arch/arm64/boot/dts/qcom/sc8180x-pmics.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/sc8180x-pmics.dtsi +1 -1
@@ -315,7 +315,7 @@ pmic@5 { compatible = "qcom,pmc8180c", "qcom,spmi-pmic"; reg = <0x5 SPMI_USID>; - pmc8180c_lpg: lpg { + pmc8180c_lpg: pwm { compatible = "qcom,pmc8180c-lpg"; #address-cells = <1>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 278/739 dt-bindings: arm: msm: kpss-acc: Make the optional reg truly optional
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 7dc3ea5ea8e8df2a82a1e78bef2382fb2c982ed3 ]
The description of reg[1] says that register is optional. Adjust minItems to make it truly optional.
--- Documentation/devicetree/bindings/power/qcom,kpss-acc-v2.yaml | 1 + 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/power/qcom,kpss-acc-v2.yaml +1 -0
@@ -21,6 +21,7 @@ properties: const: qcom,kpss-acc-v2 reg: + minItems: 1 items: - description: Base address and size of the register region - description: Optional base address and size of the alias register region
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 279/739 drm/amdgpu: Update min() to min_t() in amdgpu_info_ioctl
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Srinivasan Shanmugam <[email protected]>
[ Upstream commit a0cc8e1512ad72c9f97cdcb76d42715730adaf62 ]
Fixes the following:
WARNING: min() should probably be min_t(size_t, size, sizeof(ip))
+ ret = copy_to_user(out, &ip, min((size_t)size, sizeof(ip)));
And other style fixes:
WARNING: Prefer 'unsigned int' to bare use of 'unsigned'
WARNING: Missing a blank line after declarations
--- drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c +8 -6
@@ -557,6 +557,7 @@ int amdgpu_info_ioctl(struct drm_device *dev, void *data, struct drm_file *filp) crtc = (struct drm_crtc *)minfo->crtcs[i];if (crtc && crtc->base.id == info->mode_crtc.id) {struct amdgpu_crtc *amdgpu_crtc =to_amdgpu_crtc (crtc); + ui32 = amdgpu_crtc->crtc_id; found =1 ;break ;
@@ -575,7 +576,7 @@ int amdgpu_info_ioctl(struct drm_device *dev, void *data, struct drm_file *filp)if (ret)return ret; - ret =copy_to_user (out, &ip,min ((size_t )size,sizeof (ip))); + ret =copy_to_user (out, &ip,min_t (size_t, size,sizeof (ip)));return ret ? -EFAULT :0 ; }case AMDGPU_INFO_HW_IP_COUNT : {
@@ -721,17 +722,18 @@ int amdgpu_info_ioctl(struct drm_device *dev, void *data, struct drm_file *filp) ? -EFAULT :0 ; }case AMDGPU_INFO_READ_MMR_REG : { -unsigned n, alloc_size; +unsigned int n, alloc_size;uint32_t *regs; -unsigned se_num = (info->read_mmr_reg.instance >> +unsigned int se_num = (info->read_mmr_reg.instance >>AMDGPU_INFO_MMR_SE_INDEX_SHIFT ) &AMDGPU_INFO_MMR_SE_INDEX_MASK ; -unsigned sh_num = (info->read_mmr_reg.instance >> +unsigned int sh_num = (info->read_mmr_reg.instance >>AMDGPU_INFO_MMR_SH_INDEX_SHIFT ) &AMDGPU_INFO_MMR_SH_INDEX_MASK ;/* set full masks if the userspace set all bits -* in the bitfields */ +* in the bitfields +*/ if (se_num ==AMDGPU_INFO_MMR_SE_INDEX_MASK ) se_num =0xffffffff ;else if (se_num >=AMDGPU_GFX_MAX_SE )
@@ -896,7 +898,7 @@ int amdgpu_info_ioctl(struct drm_device *dev, void *data, struct drm_file *filp)return ret; }case AMDGPU_INFO_VCE_CLOCK_TABLE : { -unsigned i; +unsigned int i;struct drm_amdgpu_info_vce_clock_table vce_clk_table = {};struct amd_vce_state *vce_state;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 280/739 drm/amdgpu: Use seq_puts() instead of seq_printf()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Srinivasan Shanmugam <[email protected]>
[ Upstream commit fc8e55f378cf11f3abe25ec5cd67b6fc5e915a96 ]
For a constant format without additional arguments, use seq_puts() instead of seq_printf(). Also, it fixes the following warning.
WARNING: Prefer seq_puts to seq_printf
And other style fixes:
WARNING: Prefer 'unsigned int' to bare use of 'unsigned'
WARNING: Block comments should align the * on each line
--- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c +11 -11
@@ -62,7 +62,7 @@* Returns 0 on success, error on failure. */ int amdgpu_ib_get (struct amdgpu_device *adev,struct amdgpu_vm *vm, -unsigned size,enum amdgpu_ib_pool_type pool_type, +unsigned int size,enum amdgpu_ib_pool_type pool_type,struct amdgpu_ib *ib) {int r;
@@ -123,7 +123,7 @@ void amdgpu_ib_free(struct amdgpu_device *adev, struct amdgpu_ib *ib,* a CONST_IB), it will be put on the ring prior to the DE IB. Prior * to SI there was just a DE IB. */ -int amdgpu_ib_schedule (struct amdgpu_ring *ring,unsigned num_ibs, +int amdgpu_ib_schedule (struct amdgpu_ring *ring,unsigned int num_ibs,struct amdgpu_ib *ibs,struct amdgpu_job *job,struct dma_fence **f) {
@@ -131,16 +131,16 @@ int amdgpu_ib_schedule(struct amdgpu_ring *ring, unsigned num_ibs,struct amdgpu_ib *ib = &ibs[0 ];struct dma_fence *tmp =NULL ;bool need_ctx_switch; -unsigned patch_offset = ~0 ; +unsigned int patch_offset = ~0 ;struct amdgpu_vm *vm;uint64_t fence_ctx;uint32_t status =0 , alloc_size; -unsigned fence_flags =0 ; +unsigned int fence_flags =0 ;bool secure, init_shadow;u64 shadow_va, csa_va, gds_va;int vmid =AMDGPU_JOB_GET_VMID (job); -unsigned i; +unsigned int i;int r =0 ;bool need_pipe_sync = false;
@@ -282,7 +282,7 @@ int amdgpu_ib_schedule(struct amdgpu_ring *ring, unsigned num_ibs,amdgpu_ring_emit_gfx_shadow (ring,0 ,0 ,0 , false,0 );if (ring->funcs->init_cond_exec) { -unsigned ce_offset = ~0 ; +unsigned int ce_offset = ~0 ; ce_offset =amdgpu_ring_init_cond_exec (ring);if (ce_offset != ~0 && ring->funcs->patch_cond_exec)
@@ -385,7 +385,7 @@ int amdgpu_ib_ring_tests(struct amdgpu_device *adev) {long tmo_gfx, tmo_mm;int r, ret =0 ; -unsigned i; +unsigned int i; tmo_mm = tmo_gfx =AMDGPU_IB_TEST_TIMEOUT ;if (amdgpu_sriov_vf (adev)) {
@@ -402,7 +402,7 @@ int amdgpu_ib_ring_tests(struct amdgpu_device *adev)/* for CP & SDMA engines since they are scheduled together so * need to make the timeout width enough to cover the time * cost waiting for it coming back under RUNTIME only -*/ +*/ tmo_gfx =8 *AMDGPU_IB_TEST_TIMEOUT ; }else if (adev->gmc.xgmi.hive_id) { tmo_gfx =AMDGPU_IB_TEST_GFX_XGMI_TIMEOUT ;
@@ -465,13 +465,13 @@ static int amdgpu_debugfs_sa_info_show(struct seq_file *m, void *unused) {struct amdgpu_device *adev = m->private; -seq_printf (m,"--------------------- DELAYED --------------------- \n" ); +seq_puts (m,"--------------------- DELAYED ---------------------\n" );amdgpu_sa_bo_dump_debug_info (&adev->ib_pools[AMDGPU_IB_POOL_DELAYED ], m); -seq_printf (m,"-------------------- IMMEDIATE -------------------- \n" ); +seq_puts (m,"-------------------- IMMEDIATE --------------------\n" );amdgpu_sa_bo_dump_debug_info (&adev->ib_pools[AMDGPU_IB_POOL_IMMEDIATE ], m); -seq_printf (m,"--------------------- DIRECT ---------------------- \n" ); +seq_puts (m,"--------------------- DIRECT ----------------------\n" );amdgpu_sa_bo_dump_debug_info (&adev->ib_pools[AMDGPU_IB_POOL_DIRECT ], m);return 0 ;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 281/739 arm64: dts: rockchip: Fix PCIe regulators on Radxa E25
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jonas Karlman <[email protected]>
[ Upstream commit a87852e37f782257ebc57cc44a0d3fbf806471f6 ]
Despite its name, the regulator vcc3v3_pcie30x1 has nothing to do with pcie30x1. Instead, it supply power to VBAT1-5 on the M.2 KEY B port as seen on page 8 of the schematic [1].
pcie30x1 is used for the mini PCIe slot, and as seen on page 9 the vcc3v3_minipcie regulator is instead related to pcie30x1.
The M.2 KEY B port can be used for WWAN USB2 modules or SATA drives.
Use correct regulator vcc3v3_minipcie for pcie30x1.
[1] https://dl.radxa.com/cm3p/e25/radxa-e25-v1.4-sch.pdf
--- .../arm64/boot/dts/rockchip/rk3568-radxa-e25.dts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)
arch/arm64/boot/dts/rockchip/rk3568-radxa-e25.dts +8 -8
@@ -47,6 +47,9 @@ vbus_typec: vbus-typec-regulator { vin-supply = <&vcc5v0_sys>; }; + /* actually fed by vcc5v0_sys, dependent + * on pi6c clock generator + */ vcc3v3_minipcie: vcc3v3-minipcie-regulator { compatible = "regulator-fixed"; enable-active-high;
@@ -54,9 +57,9 @@ vcc3v3_minipcie: vcc3v3-minipcie-regulator { pinctrl-names = "default"; pinctrl-0 = <&minipcie_enable_h>; regulator-name = "vcc3v3_minipcie"; - regulator-min-microvolt = <5000000>; - regulator-max-microvolt = <5000000>; - vin-supply = <&vcc5v0_sys>; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + vin-supply = <&vcc3v3_pi6c_05>; }; vcc3v3_ngff: vcc3v3-ngff-regulator {
@@ -71,9 +74,6 @@ vcc3v3_ngff: vcc3v3-ngff-regulator { vin-supply = <&vcc5v0_sys>; }; - /* actually fed by vcc5v0_sys, dependent - * on pi6c clock generator - */ vcc3v3_pcie30x1: vcc3v3-pcie30x1-regulator { compatible = "regulator-fixed"; enable-active-high;
@@ -83,7 +83,7 @@ vcc3v3_pcie30x1: vcc3v3-pcie30x1-regulator { regulator-name = "vcc3v3_pcie30x1"; regulator-min-microvolt = <3300000>; regulator-max-microvolt = <3300000>; - vin-supply = <&vcc3v3_pi6c_05>; + vin-supply = <&vcc5v0_sys>; }; vcc3v3_pi6c_05: vcc3v3-pi6c-05-regulator {
@@ -117,7 +117,7 @@ &pcie3x1 { pinctrl-names = "default"; pinctrl-0 = <&pcie30x1m0_pins>; reset-gpios = <&gpio0 RK_PC3 GPIO_ACTIVE_HIGH>; - vpcie3v3-supply = <&vcc3v3_pcie30x1>; + vpcie3v3-supply = <&vcc3v3_minipcie>; status = "okay"; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 282/739 arm64: dts: rockchip: Enable SATA on Radxa E25
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jonas Karlman <[email protected]>
[ Upstream commit 2bdfe84fbd57a4ed9fd65a67210442559ce078f0 ]
The M.2 KEY B port can be used for WWAN USB2 modules or SATA drives.
Enable sata1 node to fix use of SATA drives on the M.2 slot.
--- arch/arm64/boot/dts/rockchip/rk3568-radxa-e25.dts | 8 ++++++++ 1 file changed, 8 insertions(+)
arch/arm64/boot/dts/rockchip/rk3568-radxa-e25.dts +8 -0
@@ -99,6 +99,10 @@ vcc3v3_pi6c_05: vcc3v3-pi6c-05-regulator { }; }; +&combphy1 { + phy-supply = <&vcc3v3_pcie30x1>; +}; + &pcie2x1 { pinctrl-names = "default"; pinctrl-0 = <&pcie20_reset_h>;
@@ -178,6 +182,10 @@ &pwm12 { status = "okay"; }; +&sata1 { + status = "okay"; +}; + &sdmmc0 { bus-width = <4>; cap-sd-highspeed;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 283/739 ASoC: loongson: drop of_match_ptr for OF device id
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: YingKun Meng <[email protected]>
[ Upstream commit c17bd30d0ba5ca59266771cdfc387f26271a7042 ]
The ASoC Sound Card driver can be compile tested with !CONFIG_OF making 'loongson_asoc_dt_ids' unused:
sound/soc/loongson/loongson_card.c:200:34: warning: unused variable 'loongson_asoc_dt_ids' [-Wunused-const-variable]
As krzysztof advice, we drop of_match_ptr so the device id can also be used on ACPI.
--- sound/soc/loongson/loongson_card.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/soc/loongson/loongson_card.c +1 -1
@@ -208,7 +208,7 @@ static struct platform_driver loongson_audio_driver = { .driver = { .name = "loongson-asoc-card", .pm = &snd_soc_pm_ops, - .of_match_table = of_match_ptr(loongson_asoc_dt_ids), + .of_match_table = loongson_asoc_dt_ids, }, };module_platform_driver (loongson_audio_driver);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 284/739 ASoC: fsl: fsl_qmc_audio: Fix snd_pcm_format_t values handling
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Herve Codina <[email protected]>
[ Upstream commit 5befe22b3eebd07b334b2917f6d14ce7ee4c8404 ]
Running sparse on fsl_qmc_audio (make C=1) raises the following warnings:
fsl_qmc_audio.c:387:26: warning: restricted snd_pcm_format_t degrades to integer fsl_qmc_audio.c:389:59: warning: incorrect type in argument 1 (different base types)
fsl_qmc_audio.c:389:59: expected restricted snd_pcm_format_t [usertype] format
fsl_qmc_audio.c:389:59: got unsigned int [assigned] i
fsl_qmc_audio.c:564:26: warning: restricted snd_pcm_format_t degrades to integer fsl_qmc_audio.c:569:50: warning: incorrect type in argument 1 (different base types)
fsl_qmc_audio.c:569:50: expected restricted snd_pcm_format_t [usertype] format
fsl_qmc_audio.c:569:50: got int [assigned] i
fsl_qmc_audio.c:573:62: warning: incorrect type in argument 1 (different base types)
fsl_qmc_audio.c:573:62: expected restricted snd_pcm_format_t [usertype] format
fsl_qmc_audio.c:573:62: got int [assigned] i
These warnings are due to snd_pcm_format_t values handling done in the driver. Some macros and functions exist to handle safely these values.
Use dedicated macros and functions to remove these warnings.
--- sound/soc/fsl/fsl_qmc_audio.c | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-)
sound/soc/fsl/fsl_qmc_audio.c +14 -14
@@ -372,8 +372,8 @@ static int qmc_dai_hw_rule_format_by_channels(struct qmc_dai *qmc_dai,struct snd_mask *f_old =hw_param_mask (params,SNDRV_PCM_HW_PARAM_FORMAT );unsigned int channels =params_channels (params);unsigned int slot_width; +snd_pcm_format_t format;struct snd_mask f_new; -unsigned int i;if (!channels || channels > nb_ts) { dev_err(qmc_dai->dev, "channels %u not supported\n",
@@ -384,10 +384,10 @@ static int qmc_dai_hw_rule_format_by_channels(struct qmc_dai *qmc_dai, slot_width = (nb_ts / channels) *8 ;snd_mask_none (&f_new); -for (i =0 ; i <=SNDRV_PCM_FORMAT_LAST ; i++) { -if (snd_mask_test (f_old, i)) { -if (snd_pcm_format_physical_width (i) <= slot_width) -snd_mask_set (&f_new, i); +pcm_for_each_format (format) { +if (snd_mask_test_format (f_old, format)) { +if (snd_pcm_format_physical_width (format) <= slot_width) +snd_mask_set_format (&f_new, format); } }
@@ -551,26 +551,26 @@ static const struct snd_soc_dai_ops qmc_dai_ops = {static u64 qmc_audio_formats (u8 nb_ts) { -u64 formats; -unsigned int chan_width;unsigned int format_width; -int i; +unsigned int chan_width; +snd_pcm_format_t format; +u64 formats_mask;if (!nb_ts)return 0 ; - formats =0 ; + formats_mask =0 ; chan_width = nb_ts *8 ; -for (i =0 ; i <=SNDRV_PCM_FORMAT_LAST ; i++) { +pcm_for_each_format (format) {/* * Support format other than little-endian (ie big-endian or * without endianness such as 8bit formats) */ -if (snd_pcm_format_little_endian (i) ==1 ) +if (snd_pcm_format_little_endian (format) ==1 )continue ;/* Support physical width multiple of 8bit */ - format_width =snd_pcm_format_physical_width (i); + format_width =snd_pcm_format_physical_width (format);if (format_width ==0 || format_width %8 )continue ;
@@ -581,9 +581,9 @@ static u64 qmc_audio_formats(u8 nb_ts)if (format_width > chan_width || chan_width % format_width)continue ; - formats |= (1ULL << i); + formats_mask |=pcm_format_to_bits (format); } -return formats; +return formats_mask; } static int qmc_audio_dai_parse(struct qmc_audio *qmc_audio, struct device_node *np,
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 285/739 md: restore noio_flag for the last mddev_resume()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yu Kuai <[email protected]>
[ Upstream commit e24ed04389f9619e0aaef615a8948633c182a8b0 ]
memalloc_noio_save() is called for the first mddev_suspend(), and repeated mddev_suspend() only increase 'suspended'. However, memalloc_noio_restore() is also called for the first mddev_resume(), which means that memory reclaim will be enabled before the last mddev_resume() is called, while the array is still suspended.
Fix this problem by restore 'noio_flag' for the last mddev_resume().
--- drivers/md/md.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
drivers/md/md.c +4 -2
@@ -465,11 +465,13 @@ EXPORT_SYMBOL_GPL(mddev_suspend);void mddev_resume (struct mddev *mddev) { -/* entred the memalloc scope from mddev_suspend() */ -memalloc_noio_restore (mddev->noio_flag);lockdep_assert_held (&mddev->reconfig_mutex);if (--mddev->suspended)return ; + +/* entred the memalloc scope from mddev_suspend() */ +memalloc_noio_restore (mddev->noio_flag); +percpu_ref_resurrect (&mddev->active_io);wake_up (&mddev->sb_wait); mddev->pers->quiesce (mddev,0 );
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 286/739 md/raid10: factor out dereference_rdev_and_rrdev()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Li Nan <[email protected]>
[ Upstream commit b99f8fd2d91eb734f13098aa1cf337edaca454b7 ]
Factor out a helper to get 'rdev' and 'replacement' from config->mirrors. Just to make code cleaner and prepare to fix the bug of io loss while 'replacement' replace 'rdev'.
There is no functional change.
Stable-dep-of: 673643490b9a ("md/raid10: use dereference_rdev_and_rrdev() to get devices")
--- drivers/md/raid10.c | 29 ++++++++++++++++++++--------- 1 file changed, 20 insertions(+), 9 deletions(-)
drivers/md/raid10.c +20 -9
@@ -1322,6 +1322,25 @@ static void raid10_write_one_disk(struct mddev *mddev, struct r10bio *r10_bio, } } +static struct md_rdev *dereference_rdev_and_rrdev (struct raid10_info *mirror, +struct md_rdev **prrdev) +{ +struct md_rdev *rdev, *rrdev; + + rrdev =rcu_dereference (mirror->replacement); +/* +* Read replacement first to prevent reading both rdev and +* replacement as NULL during replacement replace rdev. +*/ +smp_mb (); + rdev =rcu_dereference (mirror->rdev); +if (rdev == rrdev) + rrdev =NULL ; + + *prrdev = rrdev; +return rdev; +} +static void wait_blocked_dev (struct mddev *mddev,struct r10bio *r10_bio) {int i;
@@ -1465,15 +1484,7 @@ static void raid10_write_request(struct mddev *mddev, struct bio *bio,int d = r10_bio->devs[i].devnum;struct md_rdev *rdev, *rrdev; - rrdev =rcu_dereference (conf->mirrors[d].replacement); -/* -* Read replacement first to prevent reading both rdev and -* replacement as NULL during replacement replace rdev. -*/ -smp_mb (); - rdev =rcu_dereference (conf->mirrors[d].rdev); -if (rdev == rrdev) - rrdev =NULL ; + rdev =dereference_rdev_and_rrdev (&conf->mirrors[d], &rrdev);if (rdev && (test_bit (Faulty, &rdev->flags))) rdev =NULL ;if (rrdev && (test_bit (Faulty, &rrdev->flags)))
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 287/739 md/raid10: use dereference_rdev_and_rrdev() to get devices
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Li Nan <[email protected]>
[ Upstream commit 673643490b9a0eb3b25633abe604f62b8f63dba1 ]
Commit 2ae6aaf76912 ("md/raid10: fix io loss while replacement replace rdev") reads replacement first to prevent io loss. However, there are same issue in wait_blocked_dev() and raid10_handle_discard(), too. Fix it by using dereference_rdev_and_rrdev() to get devices.
--- drivers/md/raid10.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-)
drivers/md/raid10.c +5 -8
@@ -1351,11 +1351,9 @@ static void wait_blocked_dev(struct mddev *mddev, struct r10bio *r10_bio) blocked_rdev =NULL ;rcu_read_lock ();for (i =0 ; i < conf->copies; i++) { -struct md_rdev *rdev =rcu_dereference (conf->mirrors[i].rdev); -struct md_rdev *rrdev =rcu_dereference ( - conf->mirrors[i].replacement); -if (rdev == rrdev) - rrdev =NULL ; +struct md_rdev *rdev, *rrdev; + + rdev =dereference_rdev_and_rrdev (&conf->mirrors[i], &rrdev);if (rdev &&unlikely (test_bit (Blocked, &rdev->flags))) {atomic_inc (&rdev->nr_pending); blocked_rdev = rdev;
@@ -1791,10 +1789,9 @@ static int raid10_handle_discard(struct mddev *mddev, struct bio *bio)*/ rcu_read_lock ();for (disk =0 ; disk < geo->raid_disks; disk++) { -struct md_rdev *rdev =rcu_dereference (conf->mirrors[disk].rdev); -struct md_rdev *rrdev =rcu_dereference ( - conf->mirrors[disk].replacement); +struct md_rdev *rdev, *rrdev; + rdev =dereference_rdev_and_rrdev (&conf->mirrors[disk], &rrdev); r10_bio->devs[disk].bio =NULL ; r10_bio->devs[disk].repl_bio =NULL ;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 288/739 md/md-bitmap: remove unnecessary local variable in backlog_store()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yu Kuai <[email protected]>
[ Upstream commit b4d129640f194ffc4cc64c3e97f98ae944c072e8 ]
Local variable is definied first in the beginning of backlog_store(), there is no need to define it again.
--- drivers/md/md-bitmap.c | 2 -- 1 file changed, 2 deletions(-)
drivers/md/md-bitmap.c +0 -2
@@ -2565,8 +2565,6 @@ backlog_store(struct mddev *mddev, const char *buf, size_t len)mddev_destroy_serial_pool (mddev,NULL , false); }else if (backlog && !mddev->serial_info_pool) {/* serial_info_pool is needed since backlog is not zero */ -struct md_rdev *rdev; -rdev_for_each (rdev, mddev)mddev_create_serial_pool (mddev, rdev, false); }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 289/739 md/md-bitmap: hold reconfig_mutex in backlog_store()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yu Kuai <[email protected]>
[ Upstream commit 44abfa6a95df425c0660d56043020b67e6d93ab8 ]
Several reasons why 'reconfig_mutex' should be held:
1) rdev_for_each() is not safe to be called without the lock, because rdev can be removed concurrently.
2) mddev_destroy_serial_pool() and mddev_create_serial_pool() should not be called concurrently.
3) mddev_suspend() from mddev_destroy/create_serial_pool() should be protected by the lock.
--- drivers/md/md-bitmap.c | 7 +++++++ 1 file changed, 7 insertions(+)
drivers/md/md-bitmap.c +7 -0
@@ -2542,6 +2542,10 @@ backlog_store(struct mddev *mddev, const char *buf, size_t len)if (backlog >COUNTER_MAX )return -EINVAL ; + rv =mddev_lock (mddev); +if (rv) +return rv; +/* * Without write mostly device, it doesn't make sense to set * backlog for max_write_behind.
@@ -2555,6 +2559,7 @@ backlog_store(struct mddev *mddev, const char *buf, size_t len)if (!has_write_mostly) {pr_warn_ratelimited ("%s: can't set backlog, no write mostly device available\n" ,mdname (mddev)); +mddev_unlock (mddev);return -EINVAL ; }
@@ -2570,6 +2575,8 @@ backlog_store(struct mddev *mddev, const char *buf, size_t len) }if (old_mwb != backlog)md_bitmap_update_sb (mddev->bitmap); + +mddev_unlock (mddev);return len; }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 290/739 drm/msm: Update dev core dump to not print backwards
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ryan McCann <[email protected]>
[ Upstream commit 903705111d863ed8ccf73465da77d232fc422ec1 ]
Device core dump add block method adds hardware blocks to dumping queue with stack behavior which causes the hardware blocks to be printed in reverse order. Change the addition to dumping queue data structure from "list_add" to "list_add_tail" for FIFO queue behavior.
Patchwork: https://patchwork.freedesktop.org/patch/546200/
--- drivers/gpu/drm/msm/disp/msm_disp_snapshot_util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/msm/disp/msm_disp_snapshot_util.c +1 -1
@@ -192,5 +192,5 @@ void msm_disp_snapshot_add_block(struct msm_disp_state *disp_state, u32 len, new_blk->base_addr = base_addr;msm_disp_state_dump_regs (&new_blk->state, new_blk->size, base_addr); -list_add (&new_blk->node, &disp_state->blocks); +list_add_tail (&new_blk->node, &disp_state->blocks); }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 291/739 drm/tegra: dpaux: Fix incorrect return value of platform_get_irq
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yangtao Li <[email protected]>
[ Upstream commit 2a1ca44b654346cadfc538c4fb32eecd8daf3140 ]
When platform_get_irq fails, we should return dpaux->irq instead of -ENXIO.
--- drivers/gpu/drm/tegra/dpaux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/tegra/dpaux.c +1 -1
@@ -468,7 +468,7 @@ static int tegra_dpaux_probe(struct platform_device *pdev) dpaux->irq =platform_get_irq (pdev,0 );if (dpaux->irq <0 ) -return -ENXIO ; +return dpaux->irq;if (!pdev->dev.pm_domain) { dpaux->rst =devm_reset_control_get (&pdev->dev,"dpaux" );
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 292/739 of: unittest: fix null pointer dereferencing in of_unittest_find_node_by_name()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ruan Jinjie <[email protected]>
[ Upstream commit d6ce4f0ea19c32f10867ed93d8386924326ab474 ]
when kmalloc() fail to allocate memory in kasprintf(), name or full_name will be NULL, strcmp() will cause null pointer dereference.
--- drivers/of/unittest.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-)
drivers/of/unittest.c +6 -4
@@ -77,7 +77,7 @@ static void __init of_unittest_find_node_by_name(void) np =of_find_node_by_path ("/testcase-data" ); name =kasprintf (GFP_KERNEL ,"%pOF" , np); -unittest (np && !strcmp ("/testcase-data" , name), +unittest (np && name && !strcmp ("/testcase-data" , name),"find /testcase-data failed\n" );of_node_put (np);kfree (name);
@@ -88,14 +88,14 @@ static void __init of_unittest_find_node_by_name(void) np =of_find_node_by_path ("/testcase-data/phandle-tests/consumer-a" ); name =kasprintf (GFP_KERNEL ,"%pOF" , np); -unittest (np && !strcmp ("/testcase-data/phandle-tests/consumer-a" , name), +unittest (np && name && !strcmp ("/testcase-data/phandle-tests/consumer-a" , name),"find /testcase-data/phandle-tests/consumer-a failed\n" );of_node_put (np);kfree (name); np =of_find_node_by_path ("testcase-alias" ); name =kasprintf (GFP_KERNEL ,"%pOF" , np); -unittest (np && !strcmp ("/testcase-data" , name), +unittest (np && name && !strcmp ("/testcase-data" , name),"find testcase-alias failed\n" );of_node_put (np);kfree (name);
@@ -106,7 +106,7 @@ static void __init of_unittest_find_node_by_name(void) np =of_find_node_by_path ("testcase-alias/phandle-tests/consumer-a" ); name =kasprintf (GFP_KERNEL ,"%pOF" , np); -unittest (np && !strcmp ("/testcase-data/phandle-tests/consumer-a" , name), +unittest (np && name && !strcmp ("/testcase-data/phandle-tests/consumer-a" , name),"find testcase-alias/phandle-tests/consumer-a failed\n" );of_node_put (np);kfree (name);
@@ -1533,6 +1533,8 @@ static void attach_node_and_children(struct device_node *np)const char *full_name; full_name =kasprintf (GFP_KERNEL ,"%pOF" , np); +if (!full_name) +return ;if (!strcmp (full_name,"/__local_fixups__" ) || !strcmp (full_name,"/__fixups__" )) {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 293/739 arm64: dts: qcom: sm8150: Fix the I2C7 interrupt
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Zeyan Li <[email protected]>
[ Upstream commit f9568d22ce06192a7e14bda3a29dc216659554ff ]
I2C6 and I2C7 use the same interrupts, which is incorrect. In the downstream kernel, I2C7 has interrupts of 608 instead of 607.
--- arch/arm64/boot/dts/qcom/sm8150.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/sm8150.dtsi +1 -1
@@ -1231,7 +1231,7 @@ i2c7: i2c@89c000 { dma-names = "tx", "rx"; pinctrl-names = "default"; pinctrl-0 = <&qup_i2c7_default>; - interrupts = <GIC_SPI 607 IRQ_TYPE_LEVEL_HIGH>; + interrupts = <GIC_SPI 608 IRQ_TYPE_LEVEL_HIGH>; #address-cells = <1>; #size-cells = <0>; status = "disabled";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 294/739 drm/ast: report connection status on Display Port.
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jocelyn Falempe <[email protected]>
[ Upstream commit f81bb0ac7872893241319ea82504956676ef02fd ]
Aspeed always report the display port as "connected", because it doesn't set a .detect_ctx callback.
Fix this by providing the proper detect callback for astdp and dp501.
This also fixes the following regression:
Since commit fae7d186403e ("drm/probe-helper: Default to 640x480 if no EDID on DP") The default resolution is now 640x480 when no monitor is connected. But Aspeed graphics is mostly used in servers, where no monitor is attached. This also affects the remote BMC resolution to 640x480, which is inconvenient, and breaks the anaconda installer.
v2: Add .detect callback to the dp/dp501 connector (Jani Nikula)
v3: Use .detect_ctx callback, and refactors (Thomas Zimmermann)
Add a BMC virtual connector
v4: Better indent detect_ctx() functions (Thomas Zimmermann)
v5: Enable polling of the dp and dp501 connector status
(Thomas Zimmermann)
v6: Change check order in ast_astdp_is_connected (Jammy Huang)
--- drivers/gpu/drm/ast/ast_dp.c | 11 ++++++++++ drivers/gpu/drm/ast/ast_dp501.c | 37 ++++++++++++++++++++++----------- drivers/gpu/drm/ast/ast_drv.h | 2 ++ drivers/gpu/drm/ast/ast_mode.c | 30 ++++++++++++++++++++++++-- 4 files changed, 66 insertions(+), 14 deletions(-)
drivers/gpu/drm/ast/ast_dp.c +11 -0
@@ -7,6 +7,17 @@#include <drm/drm_print.h> #include "ast_drv.h" +bool ast_astdp_is_connected (struct ast_device *ast) +{ +if (!ast_get_index_reg_mask (ast,AST_IO_CRTC_PORT ,0xD1 ,ASTDP_MCU_FW_EXECUTING )) +return false; +if (!ast_get_index_reg_mask (ast,AST_IO_CRTC_PORT ,0xDF ,ASTDP_HPD )) +return false; +if (!ast_get_index_reg_mask (ast,AST_IO_CRTC_PORT ,0xDC ,ASTDP_LINK_SUCCESS )) +return false; +return true; +} +int ast_astdp_read_edid (struct drm_device *dev,u8 *ediddata) {struct ast_device *ast =to_ast_device (dev);
drivers/gpu/drm/ast/ast_dp501.c +25 -12
@@ -272,11 +272,9 @@ static bool ast_launch_m68k(struct drm_device *dev)return true; } -bool ast_dp501_read_edid (struct drm_device *dev,u8 *ediddata) +bool ast_dp501_is_connected (struct ast_device *ast) { -struct ast_device *ast =to_ast_device (dev); -u32 i, boot_address, offset, data; -u32 *pEDIDidx; +u32 boot_address, offset, data;if (ast->config_mode == ast_use_p2a) { boot_address =get_fw_base (ast);
@@ -292,14 +290,6 @@ bool ast_dp501_read_edid(struct drm_device *dev, u8 *ediddata) data =ast_mindwm (ast, boot_address + offset);if (!(data &AST_DP501_PNP_CONNECTED ))return false; - -/* Read EDID */ - offset =AST_DP501_EDID_DATA ; -for (i =0 ; i <128 ; i +=4 ) { - data =ast_mindwm (ast, boot_address + offset + i); - pEDIDidx = (u32 *)(ediddata + i); - *pEDIDidx = data; - } }else {if (!ast->dp501_fw_buf)return false;
@@ -319,7 +309,30 @@ bool ast_dp501_read_edid(struct drm_device *dev, u8 *ediddata) data =readl (ast->dp501_fw_buf + offset);if (!(data &AST_DP501_PNP_CONNECTED ))return false; + } +return true; +} + +bool ast_dp501_read_edid (struct drm_device *dev,u8 *ediddata) +{ +struct ast_device *ast =to_ast_device (dev); +u32 i, boot_address, offset, data; +u32 *pEDIDidx; + +if (!ast_dp501_is_connected (ast)) +return false; + +if (ast->config_mode == ast_use_p2a) { + boot_address =get_fw_base (ast); +/* Read EDID */ + offset =AST_DP501_EDID_DATA ; +for (i =0 ; i <128 ; i +=4 ) { + data =ast_mindwm (ast, boot_address + offset + i); + pEDIDidx = (u32 *)(ediddata + i); + *pEDIDidx = data; + } + }else {/* Read EDID */ offset =AST_DP501_EDID_DATA ;for (i =0 ; i <128 ; i +=4 ) {
drivers/gpu/drm/ast/ast_drv.h +2 -0
@@ -468,6 +468,7 @@ void ast_patch_ahb_2500(struct ast_device *ast);/* ast dp501 */ void ast_set_dp501_video_output (struct drm_device *dev,u8 mode);bool ast_backup_fw (struct drm_device *dev,u8 *addr,u32 size); +bool ast_dp501_is_connected (struct ast_device *ast);bool ast_dp501_read_edid (struct drm_device *dev,u8 *ediddata);u8 ast_get_dp501_max_clk (struct drm_device *dev);void ast_init_3rdtx (struct drm_device *dev);
@@ -476,6 +477,7 @@ void ast_init_3rdtx(struct drm_device *dev);struct ast_i2c_chan *ast_i2c_create (struct drm_device *dev);/* aspeed DP */ +bool ast_astdp_is_connected (struct ast_device *ast);int ast_astdp_read_edid (struct drm_device *dev,u8 *ediddata);void ast_dp_launch (struct drm_device *dev);void ast_dp_power_on_off (struct drm_device *dev,bool no);
drivers/gpu/drm/ast/ast_mode.c +28 -2
@@ -1585,8 +1585,20 @@ static int ast_dp501_connector_helper_get_modes(struct drm_connector *connector)return 0 ; } +static int ast_dp501_connector_helper_detect_ctx (struct drm_connector *connector, +struct drm_modeset_acquire_ctx *ctx, +bool force) +{ +struct ast_device *ast =to_ast_device (connector->dev); + +if (ast_dp501_is_connected (ast)) +return connector_status_connected; +return connector_status_disconnected; +} +static const struct drm_connector_helper_funcs ast_dp501_connector_helper_funcs = { .get_modes = ast_dp501_connector_helper_get_modes, + .detect_ctx = ast_dp501_connector_helper_detect_ctx, };static const struct drm_connector_funcs ast_dp501_connector_funcs = {
@@ -1611,7 +1623,7 @@ static int ast_dp501_connector_init(struct drm_device *dev, struct drm_connector connector->interlace_allowed =0 ; connector->doublescan_allowed =0 ; - connector->polled =DRM_CONNECTOR_POLL_CONNECT ; + connector->polled =DRM_CONNECTOR_POLL_CONNECT |DRM_CONNECTOR_POLL_DISCONNECT ;return 0 ; }
@@ -1683,8 +1695,20 @@ static int ast_astdp_connector_helper_get_modes(struct drm_connector *connector)return 0 ; } +static int ast_astdp_connector_helper_detect_ctx (struct drm_connector *connector, +struct drm_modeset_acquire_ctx *ctx, +bool force) +{ +struct ast_device *ast =to_ast_device (connector->dev); + +if (ast_astdp_is_connected (ast)) +return connector_status_connected; +return connector_status_disconnected; +} +static const struct drm_connector_helper_funcs ast_astdp_connector_helper_funcs = { .get_modes = ast_astdp_connector_helper_get_modes, + .detect_ctx = ast_astdp_connector_helper_detect_ctx, };static const struct drm_connector_funcs ast_astdp_connector_funcs = {
@@ -1709,7 +1733,7 @@ static int ast_astdp_connector_init(struct drm_device *dev, struct drm_connector connector->interlace_allowed =0 ; connector->doublescan_allowed =0 ; - connector->polled =DRM_CONNECTOR_POLL_CONNECT ; + connector->polled =DRM_CONNECTOR_POLL_CONNECT |DRM_CONNECTOR_POLL_DISCONNECT ;return 0 ; }
@@ -1848,5 +1872,7 @@ int ast_mode_config_init(struct ast_device *ast)drm_mode_config_reset (dev); +drm_kms_helper_poll_init (dev); +return 0 ; }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 295/739 ARM: dts: BCM53573: Fix Tenda AC9 switch CPU port
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rafał Miłecki <[email protected]>
[ Upstream commit 7141209db9c335ab261a17933809a3e660ebdc12 ]
Primary Ethernet interface is connected to the port 8 (not 5).
--- arch/arm/boot/dts/broadcom/bcm47189-tenda-ac9.dts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm/boot/dts/broadcom/bcm47189-tenda-ac9.dts +2 -2
@@ -135,8 +135,8 @@ port@4 { label = "lan4"; }; - port@5 { - reg = <5>; + port@8 { + reg = <8>; label = "cpu"; ethernet = <&gmac0>; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 296/739 drm/armada: Fix off-by-one error in armada_overlay_get_property()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Geert Uytterhoeven <[email protected]>
[ Upstream commit 5f0d984053f74983a287100a9519b2fabb785fb5 ]
As ffs() returns one more than the index of the first bit set (zero means no bits set), the color key mode value is shifted one position too much.
Fix this by using FIELD_GET() instead.
--- drivers/gpu/drm/armada/armada_overlay.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
drivers/gpu/drm/armada/armada_overlay.c +4 -2
@@ -4,6 +4,8 @@* Rewritten from the dovefb driver, and Armada510 manuals. */ +#include <linux/bitfield.h> +#include <drm/armada_drm.h> #include <drm/drm_atomic.h> #include <drm/drm_atomic_helper.h>
@@ -445,8 +447,8 @@ static int armada_overlay_get_property(struct drm_plane *plane,drm_to_overlay_state (state)->colorkey_ug, drm_to_overlay_state(state)->colorkey_vb, 0); }else if (property == priv->colorkey_mode_prop) { - *val = (drm_to_overlay_state (state)->colorkey_mode & -CFG_CKMODE_MASK ) >>ffs (CFG_CKMODE_MASK ); + *val =FIELD_GET (CFG_CKMODE_MASK , +drm_to_overlay_state (state)->colorkey_mode); }else if (property == priv->brightness_prop) { *val =drm_to_overlay_state (state)->brightness +256 ; }else if (property == priv->contrast_prop) {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 297/739 drm/repaper: Reduce temporary buffer size in repaper_fb_dirty()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Geert Uytterhoeven <[email protected]>
[ Upstream commit fedf429e071f6dbbe7a69dfc342492e037692018 ]
As the temporary buffer is no longer used to store 8-bit grayscale data, its size can be reduced to the size needed to store the monochrome bitmap data.
--- drivers/gpu/drm/tiny/repaper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/tiny/repaper.c +1 -1
@@ -533,7 +533,7 @@ static int repaper_fb_dirty(struct drm_framebuffer *fb)DRM_DEBUG ("Flushing [FB:%d] st=%ums\n" , fb->base.id, epd->factored_stage_time); - buf =kmalloc_array (fb->width, fb->height,GFP_KERNEL ); + buf =kmalloc (fb->width * fb->height /8 ,GFP_KERNEL );if (!buf) { ret = -ENOMEM ; goto out_exit;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 298/739 drm/panel: simple: Add missing connector type and pixel format for AUO T215HVN01
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Marek Vasut <[email protected]>
[ Upstream commit 7a675a8fa598edb29a664a91adb80f0340649f6f ]
The connector type and pixel format are missing for this panel, add them to prevent various drivers from failing to determine either of those parameters.
--- drivers/gpu/drm/panel/panel-simple.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/panel/panel-simple.c +3 -1
@@ -1189,7 +1189,9 @@ static const struct panel_desc auo_t215hvn01 = { .delay = { .disable = 5, .unprepare = 1000, - } + }, + .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, + .connector_type = DRM_MODE_CONNECTOR_LVDS, };static const struct drm_display_mode avic_tm070ddh03_mode = {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 299/739 ima: Remove deprecated IMA_TRUSTED_KEYRING Kconfig
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Nayna Jain <[email protected]>
[ Upstream commit 5087fd9e80e539d2163accd045b73da64de7de95 ]
Time to remove "IMA_TRUSTED_KEYRING".
--- security/integrity/ima/Kconfig | 12 ------------ 1 file changed, 12 deletions(-)
security/integrity/ima/Kconfig +0 -12
@@ -248,18 +248,6 @@ config IMA_APPRAISE_MODSIG The modsig keyword can be used in the IMA policy to allow a hook to accept such signatures. -config IMA_TRUSTED_KEYRING - bool "Require all keys on the .ima keyring be signed (deprecated)" - depends on IMA_APPRAISE && SYSTEM_TRUSTED_KEYRING - depends on INTEGRITY_ASYMMETRIC_KEYS - select INTEGRITY_TRUSTED_KEYRING - default y - help - This option requires that all keys added to the .ima - keyring be signed by a key on the system trusted keyring. - - This option is deprecated in favor of INTEGRITY_TRUSTED_KEYRING - config IMA_KEYRINGS_PERMIT_SIGNED_BY_BUILTIN_OR_SECONDARY bool "Permit keys validly signed by a built-in or secondary CA cert (EXPERIMENTAL)" depends on SYSTEM_TRUSTED_KEYRING
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 300/739 drm: xlnx: zynqmp_dpsub: Add missing check for dma_set_mask
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jiasheng Jiang <[email protected]>
[ Upstream commit 1832fba7f9780aff67c96ad30f397c2d76141833 ]
Add check for dma_set_mask() and return the error if it fails.
--- drivers/gpu/drm/xlnx/zynqmp_dpsub.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/xlnx/zynqmp_dpsub.c +3 -1
@@ -227,7 +227,9 @@ static int zynqmp_dpsub_probe(struct platform_device *pdev) dpsub->dev = &pdev->dev;platform_set_drvdata (pdev, dpsub); -dma_set_mask (dpsub->dev,DMA_BIT_MASK (ZYNQMP_DISP_MAX_DMA_BIT )); + ret =dma_set_mask (dpsub->dev,DMA_BIT_MASK (ZYNQMP_DISP_MAX_DMA_BIT )); +if (ret) +return ret;/* Try the reserved memory. Proceed if there's none. */ of_reserved_mem_device_init (&pdev->dev);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 301/739 drm/msm/dpu: increase memtype count to 16 for sm8550
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jonathan Marek <[email protected]>
[ Upstream commit 42d0d253ed03b961c325ff756eec0480cb4adc6b ]
sm8550 has 16 vbif clients.
This fixes the extra 2 clients (DMA4/DMA5) not having their memtype initialized. This fixes DMA4/DMA5 planes not displaying correctly.
Patchwork: https://patchwork.freedesktop.org/patch/550968/
--- .../msm/disp/dpu1/catalog/dpu_9_0_sm8550.h | 4 ++-- .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 20 +++++++++++++++++++ 2 files changed, 22 insertions(+), 2 deletions(-)
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_9_0_sm8550.h +2 -2
@@ -245,8 +245,8 @@ const struct dpu_mdss_cfg dpu_sm8550_cfg = { .merge_3d = sm8550_merge_3d, .intf_count = ARRAY_SIZE(sm8550_intf), .intf = sm8550_intf, - .vbif_count = ARRAY_SIZE(sdm845_vbif), - .vbif = sdm845_vbif, + .vbif_count = ARRAY_SIZE(sm8550_vbif), + .vbif = sm8550_vbif, .perf = &sm8550_perf_data, .mdss_irqs =BIT (MDP_SSPP_TOP0_INTR ) | \ BIT(MDP_SSPP_TOP0_INTR2) | \
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c +20 -0
@@ -663,6 +663,26 @@ static const struct dpu_vbif_cfg sdm845_vbif[] = { }, }; +static const struct dpu_vbif_cfg sm8550_vbif[] = { + { + .name ="vbif_rt" , .id =VBIF_RT , + .base =0 , .len =0x1040 , + .features =BIT (DPU_VBIF_QOS_REMAP ), + .xin_halt_timeout =0x4000 , + .qos_rp_remap_size =0x40 , + .qos_rt_tbl = { + .npriority_lvl =ARRAY_SIZE (sdm845_rt_pri_lvl), + .priority_lvl = sdm845_rt_pri_lvl, + }, + .qos_nrt_tbl = { + .npriority_lvl =ARRAY_SIZE (sdm845_nrt_pri_lvl), + .priority_lvl = sdm845_nrt_pri_lvl, + }, + .memtype_count =16 , + .memtype = {3 ,3 ,3 ,3 ,3 ,3 ,3 ,3 ,3 ,3 ,3 ,3 ,3 ,3 ,3 ,3 }, + }, +}; +/************************************************************* * PERF data config *************************************************************/
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 302/739 drm/msm/dpu: inline DSC_BLK and DSC_BLK_1_2 macros
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Baryshkov <[email protected]>
[ Upstream commit 194347df5844e76bfc437e4aff2e1ece62af39c2 ]
To simplify making changes to the hardware block definitions, expand corresponding macros. This way making all the changes are more obvious and visible in the source files.
Patchwork: https://patchwork.freedesktop.org/patch/545370/
Stable-dep-of: e550ad0e5c3d ("drm/msm/dpu: fix DSC 1.2 block lengths")
--- .../msm/disp/dpu1/catalog/dpu_3_0_msm8998.h | 9 ++++- .../msm/disp/dpu1/catalog/dpu_4_0_sdm845.h | 17 +++++++-- .../msm/disp/dpu1/catalog/dpu_5_0_sm8150.h | 21 +++++++++-- .../msm/disp/dpu1/catalog/dpu_5_1_sc8180x.h | 31 +++++++++++++--- .../msm/disp/dpu1/catalog/dpu_6_0_sm8250.h | 21 +++++++++-- .../msm/disp/dpu1/catalog/dpu_6_4_sm6350.h | 6 ++- .../msm/disp/dpu1/catalog/dpu_6_9_sm6375.h | 6 ++- .../msm/disp/dpu1/catalog/dpu_7_0_sm8350.h | 25 +++++++++++-- .../msm/disp/dpu1/catalog/dpu_7_2_sc7280.h | 7 +++- .../msm/disp/dpu1/catalog/dpu_8_0_sc8280xp.h | 37 ++++++++++++++++--- .../msm/disp/dpu1/catalog/dpu_8_1_sm8450.h | 25 +++++++++++-- .../msm/disp/dpu1/catalog/dpu_9_0_sm8550.h | 25 +++++++++++-- .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 15 -------- 13 files changed, 189 insertions(+), 56 deletions(-)
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_3_0_msm8998.h +7 -2
@@ -127,8 +127,13 @@ static const struct dpu_pingpong_cfg msm8998_pp[] = { };static const struct dpu_dsc_cfg msm8998_dsc[] = { -DSC_BLK ("dsc_0" ,DSC_0 ,0x80000 ,0 ), -DSC_BLK ("dsc_1" ,DSC_1 ,0x80400 ,0 ), + { + .name ="dsc_0" , .id =DSC_0 , + .base =0x80000 , .len =0x140 , + }, { + .name ="dsc_1" , .id =DSC_1 , + .base =0x80400 , .len =0x140 , + }, };static const struct dpu_dspp_cfg msm8998_dspp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_4_0_sdm845.h +13 -4
@@ -136,10 +136,19 @@ static const struct dpu_pingpong_cfg sdm845_pp[] = { };static const struct dpu_dsc_cfg sdm845_dsc[] = { -DSC_BLK ("dsc_0" ,DSC_0 ,0x80000 ,0 ), -DSC_BLK ("dsc_1" ,DSC_1 ,0x80400 ,0 ), -DSC_BLK ("dsc_2" ,DSC_2 ,0x80800 ,0 ), -DSC_BLK ("dsc_3" ,DSC_3 ,0x80c00 ,0 ), + { + .name ="dsc_0" , .id =DSC_0 , + .base =0x80000 , .len =0x140 , + }, { + .name ="dsc_1" , .id =DSC_1 , + .base =0x80400 , .len =0x140 , + }, { + .name ="dsc_2" , .id =DSC_2 , + .base =0x80800 , .len =0x140 , + }, { + .name ="dsc_3" , .id =DSC_3 , + .base =0x80c00 , .len =0x140 , + }, };static const struct dpu_intf_cfg sdm845_intf[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_0_sm8150.h +17 -4
@@ -155,10 +155,23 @@ static const struct dpu_merge_3d_cfg sm8150_merge_3d[] = { };static const struct dpu_dsc_cfg sm8150_dsc[] = { -DSC_BLK ("dsc_0" ,DSC_0 ,0x80000 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_1" ,DSC_1 ,0x80400 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_2" ,DSC_2 ,0x80800 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_3" ,DSC_3 ,0x80c00 ,BIT (DPU_DSC_OUTPUT_CTRL )), + { + .name ="dsc_0" , .id =DSC_0 , + .base =0x80000 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_1" , .id =DSC_1 , + .base =0x80400 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_2" , .id =DSC_2 , + .base =0x80800 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_3" , .id =DSC_3 , + .base =0x80c00 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, };static const struct dpu_intf_cfg sm8150_intf[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_1_sc8180x.h +25 -6
@@ -154,12 +154,31 @@ static const struct dpu_merge_3d_cfg sc8180x_merge_3d[] = { };static const struct dpu_dsc_cfg sc8180x_dsc[] = { -DSC_BLK ("dsc_0" ,DSC_0 ,0x80000 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_1" ,DSC_1 ,0x80400 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_2" ,DSC_2 ,0x80800 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_3" ,DSC_3 ,0x80c00 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_4" ,DSC_4 ,0x81000 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_5" ,DSC_5 ,0x81400 ,BIT (DPU_DSC_OUTPUT_CTRL )), + { + .name ="dsc_0" , .id =DSC_0 , + .base =0x80000 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_1" , .id =DSC_1 , + .base =0x80400 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_2" , .id =DSC_2 , + .base =0x80800 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_3" , .id =DSC_3 , + .base =0x80c00 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_4" , .id =DSC_4 , + .base =0x81000 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_5" , .id =DSC_5 , + .base =0x81400 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, };static const struct dpu_intf_cfg sc8180x_intf[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_0_sm8250.h +17 -4
@@ -156,10 +156,23 @@ static const struct dpu_merge_3d_cfg sm8250_merge_3d[] = { };static const struct dpu_dsc_cfg sm8250_dsc[] = { -DSC_BLK ("dsc_0" ,DSC_0 ,0x80000 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_1" ,DSC_1 ,0x80400 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_2" ,DSC_2 ,0x80800 ,BIT (DPU_DSC_OUTPUT_CTRL )), -DSC_BLK ("dsc_3" ,DSC_3 ,0x80c00 ,BIT (DPU_DSC_OUTPUT_CTRL )), + { + .name ="dsc_0" , .id =DSC_0 , + .base =0x80000 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_1" , .id =DSC_1 , + .base =0x80400 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_2" , .id =DSC_2 , + .base =0x80800 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, { + .name ="dsc_3" , .id =DSC_3 , + .base =0x80c00 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, };static const struct dpu_intf_cfg sm8250_intf[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_4_sm6350.h +5 -1
@@ -98,7 +98,11 @@ static struct dpu_pingpong_cfg sm6350_pp[] = { };static const struct dpu_dsc_cfg sm6350_dsc[] = { -DSC_BLK ("dsc_0" ,DSC_0 ,0x80000 ,BIT (DPU_DSC_OUTPUT_CTRL )), + { + .name ="dsc_0" , .id =DSC_0 , + .base =0x80000 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, };static const struct dpu_intf_cfg sm6350_intf[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_9_sm6375.h +5 -1
@@ -67,7 +67,11 @@ static const struct dpu_pingpong_cfg sm6375_pp[] = { };static const struct dpu_dsc_cfg sm6375_dsc[] = { -DSC_BLK ("dsc_0" ,DSC_0 ,0x80000 ,BIT (DPU_DSC_OUTPUT_CTRL )), + { + .name ="dsc_0" , .id =DSC_0 , + .base =0x80000 , .len =0x140 , + .features =BIT (DPU_DSC_OUTPUT_CTRL ), + }, };static const struct dpu_intf_cfg sm6375_intf[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_7_0_sm8350.h +21 -4
@@ -159,10 +159,27 @@ static const struct dpu_merge_3d_cfg sm8350_merge_3d[] = {* its own different sub block address. */ static const struct dpu_dsc_cfg sm8350_dsc[] = { -DSC_BLK_1_2 ("dce_0_0" ,DSC_0 ,0x80000 ,0x29c ,0 , dsc_sblk_0), -DSC_BLK_1_2 ("dce_0_1" ,DSC_1 ,0x80000 ,0x29c ,0 , dsc_sblk_1), -DSC_BLK_1_2 ("dce_1_0" ,DSC_2 ,0x81000 ,0x29c ,BIT (DPU_DSC_NATIVE_42x_EN), dsc_sblk_0), -DSC_BLK_1_2 ("dce_1_1" ,DSC_3 ,0x81000 ,0x29c ,BIT (DPU_DSC_NATIVE_42x_EN), dsc_sblk_1), + { + .name ="dce_0_0" , .id =DSC_0 , + .base =0x80000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ), + .sblk = &dsc_sblk_0, + }, { + .name ="dce_0_1" , .id =DSC_1 , + .base =0x80000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ), + .sblk = &dsc_sblk_1, + }, { + .name ="dce_1_0" , .id =DSC_2 , + .base =0x81000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), + .sblk = &dsc_sblk_0, + }, { + .name ="dce_1_1" , .id =DSC_3 , + .base =0x81000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), + .sblk = &dsc_sblk_1, + }, };static const struct dpu_intf_cfg sm8350_intf[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_7_2_sc7280.h +6 -1
@@ -104,7 +104,12 @@ static const struct dpu_pingpong_cfg sc7280_pp[] = {/* NOTE: sc7280 only has one DSC hard slice encoder */ static const struct dpu_dsc_cfg sc7280_dsc[] = { -DSC_BLK_1_2 ("dce_0_0" ,DSC_0 ,0x80000 ,0x29c ,BIT (DPU_DSC_NATIVE_42x_EN), dsc_sblk_0), + { + .name ="dce_0_0" , .id =DSC_0 , + .base =0x80000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), + .sblk = &dsc_sblk_0, + }, };static const struct dpu_wb_cfg sc7280_wb[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_8_0_sc8280xp.h +31 -6
@@ -148,12 +148,37 @@ static const struct dpu_merge_3d_cfg sc8280xp_merge_3d[] = {* its own different sub block address. */ static const struct dpu_dsc_cfg sc8280xp_dsc[] = { -DSC_BLK_1_2 ("dce_0_0" ,DSC_0 ,0x80000 ,0x29c ,0 , dsc_sblk_0), -DSC_BLK_1_2 ("dce_0_1" ,DSC_1 ,0x80000 ,0x29c ,0 , dsc_sblk_1), -DSC_BLK_1_2 ("dce_1_0" ,DSC_2 ,0x81000 ,0x29c ,BIT (DPU_DSC_NATIVE_42x_EN), dsc_sblk_0), -DSC_BLK_1_2 ("dce_1_1" ,DSC_3 ,0x81000 ,0x29c ,BIT (DPU_DSC_NATIVE_42x_EN), dsc_sblk_1), -DSC_BLK_1_2 ("dce_2_0" ,DSC_4 ,0x82000 ,0x29c ,0 , dsc_sblk_0), -DSC_BLK_1_2 ("dce_2_1" ,DSC_5 ,0x82000 ,0x29c ,0 , dsc_sblk_1), + { + .name ="dce_0_0" , .id =DSC_0 , + .base =0x80000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ), + .sblk = &dsc_sblk_0, + }, { + .name ="dce_0_1" , .id =DSC_1 , + .base =0x80000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ), + .sblk = &dsc_sblk_1, + }, { + .name ="dce_1_0" , .id =DSC_2 , + .base =0x81000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), + .sblk = &dsc_sblk_0, + }, { + .name ="dce_1_1" , .id =DSC_3 , + .base =0x81000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), + .sblk = &dsc_sblk_1, + }, { + .name ="dce_2_0" , .id =DSC_4 , + .base =0x82000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ), + .sblk = &dsc_sblk_0, + }, { + .name ="dce_2_1" , .id =DSC_5 , + .base =0x82000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ), + .sblk = &dsc_sblk_1, + }, };/* TODO: INTF 3, 8 and 7 are used for MST, marked as INTF_NONE for now */
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_8_1_sm8450.h +21 -4
@@ -167,10 +167,27 @@ static const struct dpu_merge_3d_cfg sm8450_merge_3d[] = {* its own different sub block address. */ static const struct dpu_dsc_cfg sm8450_dsc[] = { -DSC_BLK_1_2 ("dce_0_0" ,DSC_0 ,0x80000 ,0x29c ,0 , dsc_sblk_0), -DSC_BLK_1_2 ("dce_0_1" ,DSC_1 ,0x80000 ,0x29c ,0 , dsc_sblk_1), -DSC_BLK_1_2 ("dce_1_0" ,DSC_2 ,0x81000 ,0x29c ,BIT (DPU_DSC_NATIVE_42x_EN), dsc_sblk_0), -DSC_BLK_1_2 ("dce_1_1" ,DSC_3 ,0x81000 ,0x29c ,BIT (DPU_DSC_NATIVE_42x_EN), dsc_sblk_1), + { + .name ="dce_0_0" , .id =DSC_0 , + .base =0x80000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ), + .sblk = &dsc_sblk_0, + }, { + .name ="dce_0_1" , .id =DSC_1 , + .base =0x80000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ), + .sblk = &dsc_sblk_1, + }, { + .name ="dce_1_0" , .id =DSC_2 , + .base =0x81000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), + .sblk = &dsc_sblk_0, + }, { + .name ="dce_1_1" , .id =DSC_3 , + .base =0x81000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), + .sblk = &dsc_sblk_1, + }, };static const struct dpu_intf_cfg sm8450_intf[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_9_0_sm8550.h +21 -4
@@ -171,10 +171,27 @@ static const struct dpu_merge_3d_cfg sm8550_merge_3d[] = {* its own different sub block address. */ static const struct dpu_dsc_cfg sm8550_dsc[] = { -DSC_BLK_1_2 ("dce_0_0" ,DSC_0 ,0x80000 ,0x29c ,0 , dsc_sblk_0), -DSC_BLK_1_2 ("dce_0_1" ,DSC_1 ,0x80000 ,0x29c ,0 , dsc_sblk_1), -DSC_BLK_1_2 ("dce_1_0" ,DSC_2 ,0x81000 ,0x29c ,BIT (DPU_DSC_NATIVE_42x_EN), dsc_sblk_0), -DSC_BLK_1_2 ("dce_1_1" ,DSC_3 ,0x81000 ,0x29c ,BIT (DPU_DSC_NATIVE_42x_EN), dsc_sblk_1), + { + .name ="dce_0_0" , .id =DSC_0 , + .base =0x80000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ), + .sblk = &dsc_sblk_0, + }, { + .name ="dce_0_1" , .id =DSC_1 , + .base =0x80000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ), + .sblk = &dsc_sblk_1, + }, { + .name ="dce_1_0" , .id =DSC_2 , + .base =0x81000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), + .sblk = &dsc_sblk_0, + }, { + .name ="dce_1_1" , .id =DSC_3 , + .base =0x81000 , .len =0x29c , + .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), + .sblk = &dsc_sblk_1, + }, };static const struct dpu_intf_cfg sm8550_intf[] = {
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c +0 -15
@@ -526,21 +526,6 @@ static const struct dpu_dsc_sub_blks dsc_sblk_1 = { .ctl = {.base = 0xF80, .len = 0x10}, }; -#define DSC_BLK (_name, _id, _base, _features) \ - {\ - .name = _name, .id = _id, \ - .base = _base, .len = 0x140, \ - .features = _features, \ - } - -#define DSC_BLK_1_2 (_name, _id, _base, _len, _features, _sblk) \ - {\ - .name = _name, .id = _id, \ - .base = _base, .len = _len, \ - .features = BIT(DPU_DSC_HW_REV_1_2) | _features, \ - .sblk = &_sblk, \ - } -/************************************************************* * INTF sub blocks config *************************************************************/
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 303/739 drm/msm/dpu: fix DSC 1.2 block lengths
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Baryshkov <[email protected]>
[ Upstream commit e550ad0e5c3d1a521413e6efb22729698a70110b ]
All DSC_BLK_1_2 declarations incorrectly pass 0x29c as the block length. This includes the common block itself, enc subblocks and some empty space around. Change that to pass 0x4 instead, the length of common register block itself.
Patchwork: https://patchwork.freedesktop.org/patch/550998/
--- .../gpu/drm/msm/disp/dpu1/catalog/dpu_7_0_sm8350.h | 8 ++++---- .../gpu/drm/msm/disp/dpu1/catalog/dpu_7_2_sc7280.h | 2 +- .../gpu/drm/msm/disp/dpu1/catalog/dpu_8_0_sc8280xp.h | 12 ++++++------ .../gpu/drm/msm/disp/dpu1/catalog/dpu_8_1_sm8450.h | 8 ++++---- .../gpu/drm/msm/disp/dpu1/catalog/dpu_9_0_sm8550.h | 8 ++++---- 5 files changed, 19 insertions(+), 19 deletions(-)
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_7_0_sm8350.h +4 -4
@@ -161,22 +161,22 @@ static const struct dpu_merge_3d_cfg sm8350_merge_3d[] = {static const struct dpu_dsc_cfg sm8350_dsc[] = { { .name ="dce_0_0" , .id =DSC_0 , - .base =0x80000 , .len =0x29c , + .base =0x80000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ), .sblk = &dsc_sblk_0, }, { .name ="dce_0_1" , .id =DSC_1 , - .base =0x80000 , .len =0x29c , + .base =0x80000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ), .sblk = &dsc_sblk_1, }, { .name ="dce_1_0" , .id =DSC_2 , - .base =0x81000 , .len =0x29c , + .base =0x81000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), .sblk = &dsc_sblk_0, }, { .name ="dce_1_1" , .id =DSC_3 , - .base =0x81000 , .len =0x29c , + .base =0x81000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), .sblk = &dsc_sblk_1, },
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_7_2_sc7280.h +1 -1
@@ -106,7 +106,7 @@ static const struct dpu_pingpong_cfg sc7280_pp[] = {static const struct dpu_dsc_cfg sc7280_dsc[] = { { .name ="dce_0_0" , .id =DSC_0 , - .base =0x80000 , .len =0x29c , + .base =0x80000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), .sblk = &dsc_sblk_0, },
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_8_0_sc8280xp.h +6 -6
@@ -150,32 +150,32 @@ static const struct dpu_merge_3d_cfg sc8280xp_merge_3d[] = {static const struct dpu_dsc_cfg sc8280xp_dsc[] = { { .name ="dce_0_0" , .id =DSC_0 , - .base =0x80000 , .len =0x29c , + .base =0x80000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ), .sblk = &dsc_sblk_0, }, { .name ="dce_0_1" , .id =DSC_1 , - .base =0x80000 , .len =0x29c , + .base =0x80000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ), .sblk = &dsc_sblk_1, }, { .name ="dce_1_0" , .id =DSC_2 , - .base =0x81000 , .len =0x29c , + .base =0x81000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), .sblk = &dsc_sblk_0, }, { .name ="dce_1_1" , .id =DSC_3 , - .base =0x81000 , .len =0x29c , + .base =0x81000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), .sblk = &dsc_sblk_1, }, { .name ="dce_2_0" , .id =DSC_4 , - .base =0x82000 , .len =0x29c , + .base =0x82000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ), .sblk = &dsc_sblk_0, }, { .name ="dce_2_1" , .id =DSC_5 , - .base =0x82000 , .len =0x29c , + .base =0x82000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ), .sblk = &dsc_sblk_1, },
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_8_1_sm8450.h +4 -4
@@ -169,22 +169,22 @@ static const struct dpu_merge_3d_cfg sm8450_merge_3d[] = {static const struct dpu_dsc_cfg sm8450_dsc[] = { { .name ="dce_0_0" , .id =DSC_0 , - .base =0x80000 , .len =0x29c , + .base =0x80000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ), .sblk = &dsc_sblk_0, }, { .name ="dce_0_1" , .id =DSC_1 , - .base =0x80000 , .len =0x29c , + .base =0x80000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ), .sblk = &dsc_sblk_1, }, { .name ="dce_1_0" , .id =DSC_2 , - .base =0x81000 , .len =0x29c , + .base =0x81000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), .sblk = &dsc_sblk_0, }, { .name ="dce_1_1" , .id =DSC_3 , - .base =0x81000 , .len =0x29c , + .base =0x81000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), .sblk = &dsc_sblk_1, },
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_9_0_sm8550.h +4 -4
@@ -173,22 +173,22 @@ static const struct dpu_merge_3d_cfg sm8550_merge_3d[] = {static const struct dpu_dsc_cfg sm8550_dsc[] = { { .name ="dce_0_0" , .id =DSC_0 , - .base =0x80000 , .len =0x29c , + .base =0x80000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ), .sblk = &dsc_sblk_0, }, { .name ="dce_0_1" , .id =DSC_1 , - .base =0x80000 , .len =0x29c , + .base =0x80000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ), .sblk = &dsc_sblk_1, }, { .name ="dce_1_0" , .id =DSC_2 , - .base =0x81000 , .len =0x29c , + .base =0x81000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), .sblk = &dsc_sblk_0, }, { .name ="dce_1_1" , .id =DSC_3 , - .base =0x81000 , .len =0x29c , + .base =0x81000 , .len =0x4 , .features =BIT (DPU_DSC_HW_REV_1_2 ) |BIT (DPU_DSC_NATIVE_42x_EN), .sblk = &dsc_sblk_1, },
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 304/739 drm/msm/dpu1: Rename sm8150_dspp_blk to sdm845_dspp_blk
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 9891b3df2b4300d24735c1a1822985d2d173aade ]
SDM845 was the first SoC to include both PCC v4 and GC v1.8. We don't currently support any other blocks but the common config for these two can be reused for a large amount of SoCs.
Rename it to indicate the origin of that combo.
Patchwork: https://patchwork.freedesktop.org/patch/533003/
Stable-dep-of: 57a1ca6cf73b ("drm/msm/dpu: fix DSC 1.2 enc subblock length")
--- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_4_0_sdm845.h | 8 ++++---- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_0_sm8150.h | 8 ++++---- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_1_sc8180x.h | 8 ++++---- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_0_sm8250.h | 8 ++++---- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_2_sc7180.h | 2 +- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_3_sm6115.h | 2 +- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_4_sm6350.h | 2 +- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_5_qcm2290.h | 2 +- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_9_sm6375.h | 2 +- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_7_0_sm8350.h | 8 ++++---- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_7_2_sc7280.h | 2 +- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_8_0_sc8280xp.h | 8 ++++---- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_8_1_sm8450.h | 8 ++++---- drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_9_0_sm8550.h | 8 ++++---- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 2 +- 15 files changed, 39 insertions(+), 39 deletions(-)
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_4_0_sdm845.h +4 -4
@@ -111,13 +111,13 @@ static const struct dpu_lm_cfg sdm845_lm[] = {static const struct dpu_dspp_cfg sdm845_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_1" ,DSPP_1 ,0x56000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_2" ,DSPP_2 ,0x58000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_3" ,DSPP_3 ,0x5a000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sdm845_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_0_sm8150.h +4 -4
@@ -118,13 +118,13 @@ static const struct dpu_lm_cfg sm8150_lm[] = {static const struct dpu_dspp_cfg sm8150_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_1" ,DSPP_1 ,0x56000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_2" ,DSPP_2 ,0x58000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_3" ,DSPP_3 ,0x5a000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sm8150_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_1_sc8180x.h +4 -4
@@ -117,13 +117,13 @@ static const struct dpu_lm_cfg sc8180x_lm[] = {static const struct dpu_dspp_cfg sc8180x_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_1" ,DSPP_1 ,0x56000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_2" ,DSPP_2 ,0x58000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_3" ,DSPP_3 ,0x5a000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sc8180x_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_0_sm8250.h +4 -4
@@ -119,13 +119,13 @@ static const struct dpu_lm_cfg sm8250_lm[] = {static const struct dpu_dspp_cfg sm8250_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_1" ,DSPP_1 ,0x56000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_2" ,DSPP_2 ,0x58000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_3" ,DSPP_3 ,0x5a000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sm8250_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_2_sc7180.h +1 -1
@@ -76,7 +76,7 @@ static const struct dpu_lm_cfg sc7180_lm[] = {static const struct dpu_dspp_cfg sc7180_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sc7180_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_3_sm6115.h +1 -1
@@ -56,7 +56,7 @@ static const struct dpu_lm_cfg sm6115_lm[] = {static const struct dpu_dspp_cfg sm6115_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sm6115_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_4_sm6350.h +1 -1
@@ -85,7 +85,7 @@ static const struct dpu_lm_cfg sm6350_lm[] = {static const struct dpu_dspp_cfg sm6350_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static struct dpu_pingpong_cfg sm6350_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_5_qcm2290.h +1 -1
@@ -53,7 +53,7 @@ static const struct dpu_lm_cfg qcm2290_lm[] = {static const struct dpu_dspp_cfg qcm2290_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg qcm2290_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_9_sm6375.h +1 -1
@@ -57,7 +57,7 @@ static const struct dpu_lm_cfg sm6375_lm[] = {static const struct dpu_dspp_cfg sm6375_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sm6375_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_7_0_sm8350.h +4 -4
@@ -117,13 +117,13 @@ static const struct dpu_lm_cfg sm8350_lm[] = {static const struct dpu_dspp_cfg sm8350_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_1" ,DSPP_1 ,0x56000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_2" ,DSPP_2 ,0x58000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_3" ,DSPP_3 ,0x5a000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sm8350_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_7_2_sc7280.h +1 -1
@@ -84,7 +84,7 @@ static const struct dpu_lm_cfg sc7280_lm[] = {static const struct dpu_dspp_cfg sc7280_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sc7280_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_8_0_sc8280xp.h +4 -4
@@ -112,13 +112,13 @@ static const struct dpu_lm_cfg sc8280xp_lm[] = {static const struct dpu_dspp_cfg sc8280xp_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_1" ,DSPP_1 ,0x56000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_2" ,DSPP_2 ,0x58000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_3" ,DSPP_3 ,0x5a000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sc8280xp_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_8_1_sm8450.h +4 -4
@@ -118,13 +118,13 @@ static const struct dpu_lm_cfg sm8450_lm[] = {static const struct dpu_dspp_cfg sm8450_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_1" ,DSPP_1 ,0x56000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_2" ,DSPP_2 ,0x58000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_3" ,DSPP_3 ,0x5a000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sm8450_pp[] = {
drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_9_0_sm8550.h +4 -4
@@ -123,13 +123,13 @@ static const struct dpu_lm_cfg sm8550_lm[] = {static const struct dpu_dspp_cfg sm8550_dspp[] = {DSPP_BLK ("dspp_0" ,DSPP_0 ,0x54000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_1" ,DSPP_1 ,0x56000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_2" ,DSPP_2 ,0x58000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk),DSPP_BLK ("dspp_3" ,DSPP_3 ,0x5a000 ,DSPP_SC7180_MASK , - &sm8150_dspp_sblk), + &sdm845_dspp_sblk), };static const struct dpu_pingpong_cfg sm8550_pp[] = { PP_BLK_DITHER("pingpong_0", PINGPONG_0, 0x69000, MERGE_3D_0, sc7280_pp_sblk,
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c +1 -1
@@ -448,7 +448,7 @@ static const struct dpu_dspp_sub_blks msm8998_dspp_sblk = { .len = 0x90, .version = 0x10007}, }; -static const struct dpu_dspp_sub_blks sm8150_dspp_sblk = { +static const struct dpu_dspp_sub_blks sdm845_dspp_sblk = { .pcc = {.id =DPU_DSPP_PCC , .base =0x1700 , .len =0x90 , .version =0x40000 }, };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 305/739 drm/msm/dpu: Define names for unnamed sblks
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ryan McCann <[email protected]>
[ Upstream commit 46998bf8431c30879be29bbbf67eefb583136ccb ]
Some sub-blocks in the hw catalog have not been given a name, so when the registers from that block are dumped, there is no name to reference. Define names for relevant sub-blocks to fix this.
Patchwork: https://patchwork.freedesktop.org/patch/546199/
Stable-dep-of: 57a1ca6cf73b ("drm/msm/dpu: fix DSC 1.2 enc subblock length")
--- .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-)
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c +10 -10
@@ -444,12 +444,12 @@ static const struct dpu_lm_sub_blks qcm2290_lm_sblk = {* DSPP sub blocks config *************************************************************/ static const struct dpu_dspp_sub_blks msm8998_dspp_sblk = { - .pcc = {.id =DPU_DSPP_PCC , .base =0x1700 , + .pcc = {.name ="pcc" , .id =DPU_DSPP_PCC , .base =0x1700 , .len =0x90 , .version =0x10007 }, };static const struct dpu_dspp_sub_blks sdm845_dspp_sblk = { - .pcc = {.id =DPU_DSPP_PCC , .base =0x1700 , + .pcc = {.name ="pcc" , .id =DPU_DSPP_PCC , .base =0x1700 , .len =0x90 , .version =0x40000 }, };
@@ -465,19 +465,19 @@ static const struct dpu_dspp_sub_blks sdm845_dspp_sblk = {* PINGPONG sub blocks config *************************************************************/ static const struct dpu_pingpong_sub_blks sdm845_pp_sblk_te = { - .te2 = {.id =DPU_PINGPONG_TE2 , .base =0x2000 , .len =0x0 , + .te2 = {.name ="te2" , .id =DPU_PINGPONG_TE2 , .base =0x2000 , .len =0x0 , .version =0x1 }, - .dither = {.id =DPU_PINGPONG_DITHER , .base =0x30e0 , + .dither = {.name ="dither" , .id =DPU_PINGPONG_DITHER , .base =0x30e0 , .len =0x20 , .version =0x10000 }, };static const struct dpu_pingpong_sub_blks sdm845_pp_sblk = { - .dither = {.id =DPU_PINGPONG_DITHER , .base =0x30e0 , + .dither = {.name ="dither" , .id =DPU_PINGPONG_DITHER , .base =0x30e0 , .len =0x20 , .version =0x10000 }, };static const struct dpu_pingpong_sub_blks sc7280_pp_sblk = { - .dither = {.id =DPU_PINGPONG_DITHER , .base =0xe0 , + .dither = {.name ="dither" , .id =DPU_PINGPONG_DITHER , .base =0xe0 , .len =0x20 , .version =0x20000 }, };
@@ -517,13 +517,13 @@ static const struct dpu_pingpong_sub_blks sc7280_pp_sblk = {* DSC sub blocks config *************************************************************/ static const struct dpu_dsc_sub_blks dsc_sblk_0 = { - .enc = {.base =0x100 , .len =0x100 }, - .ctl = {.base =0xF00 , .len =0x10 }, + .enc = {.name ="enc" , .base =0x100 , .len =0x100 }, + .ctl = {.name ="ctl" , .base =0xF00 , .len =0x10 }, };static const struct dpu_dsc_sub_blks dsc_sblk_1 = { - .enc = {.base =0x200 , .len =0x100 }, - .ctl = {.base =0xF80 , .len =0x10 }, + .enc = {.name ="enc" , .base =0x200 , .len =0x100 }, + .ctl = {.name ="ctl" , .base =0xF80 , .len =0x10 }, };/*************************************************************
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 306/739 drm/msm/dpu: fix DSC 1.2 enc subblock length
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Baryshkov <[email protected]>
[ Upstream commit 57a1ca6cf73b164ff93c2a541a6fc2337fd07b20 ]
Both struct dpu_dsc_sub_blks instances declare enc subblock length to be 0x100, while the actual length is 0x9c (last register having offset 0x98). Reduce subblock length to remove the empty register space from being dumped.
Patchwork: https://patchwork.freedesktop.org/patch/550999/
--- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c +2 -2
@@ -517,12 +517,12 @@ static const struct dpu_pingpong_sub_blks sc7280_pp_sblk = {* DSC sub blocks config *************************************************************/ static const struct dpu_dsc_sub_blks dsc_sblk_0 = { - .enc = {.name ="enc" , .base =0x100 , .len =0x100 }, + .enc = {.name ="enc" , .base =0x100 , .len =0x9c }, .ctl = {.name ="ctl" , .base =0xF00 , .len =0x10 }, };static const struct dpu_dsc_sub_blks dsc_sblk_1 = { - .enc = {.name ="enc" , .base =0x200 , .len =0x100 }, + .enc = {.name ="enc" , .base =0x200 , .len =0x9c }, .ctl = {.name ="ctl" , .base =0xF80 , .len =0x10 }, };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 307/739 arm64: dts: qcom: sm8550-mtp: Add missing supply for L1B regulator
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Abel Vesa <[email protected]>
[ Upstream commit 2c9e45dfeed126488aa73e7b82b3576c4c6f1036 ]
Even though currently there is no consumer for L1B, add the supply for it anyway.
--- arch/arm64/boot/dts/qcom/sm8550-mtp.dts | 1 + 1 file changed, 1 insertion(+)
arch/arm64/boot/dts/qcom/sm8550-mtp.dts +1 -0
@@ -186,6 +186,7 @@ regulators-0 { vdd-bob1-supply = <&vph_pwr>; vdd-bob2-supply = <&vph_pwr>; + vdd-l1-l4-l10-supply = <&vreg_s6g_1p8>; vdd-l2-l13-l14-supply = <&vreg_bob1>; vdd-l3-supply = <&vreg_s4g_1p3>; vdd-l5-l16-supply = <&vreg_bob1>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 308/739 soc: qcom: smem: Fix incompatible types in comparison
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Chen Jiahao <[email protected]>
[ Upstream commit 5f908786cf44fcb397cfe0f322ef2f41b0909e2a ]
This patch fixes the following sparse error:
drivers/soc/qcom/smem.c:738:30: error: incompatible types in comparison expression (different add ress spaces):drivers/soc/qcom/smem.c:738:30: void *drivers/soc/qcom/smem.c:738:30: void [noderef] __iomem *
In addr_in_range(), "base" is of type void __iomem *, converting void *addr to the same type to fix above sparse error.
--- drivers/soc/qcom/smem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/soc/qcom/smem.c +1 -1
@@ -724,7 +724,7 @@ EXPORT_SYMBOL_GPL(qcom_smem_get_free_space);static bool addr_in_range (void __iomem *base,size_t size,void *addr) { -return base && (addr >= base && addr < base + size); +return base && ((void __iomem *)addr >= base && (void __iomem *)addr < base + size); }/**
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 309/739 drm/msm/mdp5: Dont leak some plane state
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Daniel Vetter <[email protected]>
[ Upstream commit fd0ad3b2365c1c58aa5a761c18efc4817193beb6 ]
Apparently no one noticed that mdp5 plane states leak like a sieve ever since we introduced plane_state->commit refcount a few years ago in 21a01abbe32a ("drm/atomic: Fix freeing connector/plane state too early by tracking commits, v3.")
Fix it by using the right helpers.
Patchwork: https://patchwork.freedesktop.org/patch/551236/
--- drivers/gpu/drm/msm/disp/mdp5/mdp5_plane.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/gpu/drm/msm/disp/mdp5/mdp5_plane.c +1 -2
@@ -130,8 +130,7 @@ static void mdp5_plane_destroy_state(struct drm_plane *plane, {struct mdp5_plane_state *pstate =to_mdp5_plane_state (state); -if (state->fb) -drm_framebuffer_put (state->fb); +__drm_atomic_helper_plane_destroy_state (state);kfree (pstate); }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 310/739 firmware: meson_sm: fix to avoid potential NULL pointer dereference
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Zhang Shurong <[email protected]>
[ Upstream commit f2ed165619c16577c02b703a114a1f6b52026df4 ]
of_match_device() may fail and returns a NULL pointer.
Fix this by checking the return value of of_match_device.
--- drivers/firmware/meson/meson_sm.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/firmware/meson/meson_sm.c +2 -0
@@ -292,6 +292,8 @@ static int __init meson_sm_probe(struct platform_device *pdev)return -ENOMEM ; chip =of_match_device (meson_sm_ids, dev)->data; +if (!chip) +return -EINVAL ;if (chip->cmd_shmem_in_base) { fw->sm_shmem_in_base = meson_sm_map_shmem(chip->cmd_shmem_in_base,
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 311/739 drm/msm/dpu: fix the irq index in dpu_encoder_phys_wb_wait_for_commit_done
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Baryshkov <[email protected]>
[ Upstream commit d93cf453f51da168f4410ba73656f1e862096973 ]
Since commit 1e7ac595fa46 ("drm/msm/dpu: pass irq to dpu_encoder_helper_wait_for_irq()") the dpu_encoder_phys_wb_wait_for_commit_done expects the IRQ index rather than the IRQ index in phys_enc->intr table, however writeback got the older invocation in place. This was unnoticed for several releases, but now it's time to fix it.
Patchwork: https://patchwork.freedesktop.org/patch/550924/
--- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_wb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_wb.c +2 -1
@@ -446,7 +446,8 @@ static int dpu_encoder_phys_wb_wait_for_commit_done( wait_info.atomic_cnt = &phys_enc->pending_kickoff_cnt; wait_info.timeout_ms =KICKOFF_TIMEOUT_MS ; - ret =dpu_encoder_helper_wait_for_irq (phys_enc,INTR_IDX_WB_DONE , + ret =dpu_encoder_helper_wait_for_irq (phys_enc, + phys_enc->irq[INTR_IDX_WB_DONE ], dpu_encoder_phys_wb_done_irq, &wait_info);if (ret == -ETIMEDOUT )_dpu_encoder_phys_wb_handle_wbdone_timeout (phys_enc);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 312/739 arm64: dts: ti: k3-j784s4-evm: Correct Pin mux offset for ospi
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Udit Kumar <[email protected]>
[ Upstream commit f10f836ccfea21ae3ad3066eb9576625f1acdea2 ]
After splitting wkup_pmx pin mux for J784S4 into four regions. Pin mux offset for OSPI nodes were not updated to align with new regions, due to this while setting ospi pin muxes out of range error was seen.
Pin mux offsets for OSPI nodes are corrected in this patch.
--- arch/arm64/boot/dts/ti/k3-j784s4-evm.dts | 29 +++++++++++++++--------- 1 file changed, 18 insertions(+), 11 deletions(-)
arch/arm64/boot/dts/ti/k3-j784s4-evm.dts +18 -11
@@ -379,21 +379,28 @@ J784S4_WKUP_IOPAD(0x020, PIN_INPUT, 0) /* (D34) MCU_OSPI0_D5 */ J784S4_WKUP_IOPAD(0x024, PIN_INPUT, 0) /* (E34) MCU_OSPI0_D6 */ J784S4_WKUP_IOPAD(0x028, PIN_INPUT, 0) /* (E33) MCU_OSPI0_D7 */ J784S4_WKUP_IOPAD(0x008, PIN_INPUT, 0) /* (C34) MCU_OSPI0_DQS */ - J784S4_WKUP_IOPAD(0x03c, PIN_OUTPUT, 6) /* (C32) MCU_OSPI0_CSn3.MCU_OSPI0_ECC_FAIL */ - J784S4_WKUP_IOPAD(0x038, PIN_OUTPUT, 6) /* (B34) MCU_OSPI0_CSn2.MCU_OSPI0_RESET_OUT0 */ + >; + }; +}; + +&wkup_pmx1 { + mcu_fss0_ospi0_1_pins_default: mcu-fss0-ospi0-1-default-pins { + pinctrl-single,pins = < + J784S4_WKUP_IOPAD(0x004, PIN_OUTPUT, 6) /* (C32) MCU_OSPI0_ECC_FAIL */ + J784S4_WKUP_IOPAD(0x000, PIN_OUTPUT, 6) /* (B34) MCU_OSPI0_RESET_OUT0 */ >; }; mcu_fss0_ospi1_pins_default: mcu-fss0-ospi1-default-pins { pinctrl-single,pins = < - J784S4_WKUP_IOPAD(0x040, PIN_OUTPUT, 0) /* (F32) MCU_OSPI1_CLK */ - J784S4_WKUP_IOPAD(0x05c, PIN_OUTPUT, 0) /* (G32) MCU_OSPI1_CSn0 */ - J784S4_WKUP_IOPAD(0x04c, PIN_INPUT, 0) /* (E35) MCU_OSPI1_D0 */ - J784S4_WKUP_IOPAD(0x050, PIN_INPUT, 0) /* (D31) MCU_OSPI1_D1 */ - J784S4_WKUP_IOPAD(0x054, PIN_INPUT, 0) /* (G31) MCU_OSPI1_D2 */ - J784S4_WKUP_IOPAD(0x058, PIN_INPUT, 0) /* (F33) MCU_OSPI1_D3 */ - J784S4_WKUP_IOPAD(0x048, PIN_INPUT, 0) /* (F31) MCU_OSPI1_DQS */ - J784S4_WKUP_IOPAD(0x044, PIN_INPUT, 0) /* (C31) MCU_OSPI1_LBCLKO */ + J784S4_WKUP_IOPAD(0x008, PIN_OUTPUT, 0) /* (F32) MCU_OSPI1_CLK */ + J784S4_WKUP_IOPAD(0x024, PIN_OUTPUT, 0) /* (G32) MCU_OSPI1_CSn0 */ + J784S4_WKUP_IOPAD(0x014, PIN_INPUT, 0) /* (E35) MCU_OSPI1_D0 */ + J784S4_WKUP_IOPAD(0x018, PIN_INPUT, 0) /* (D31) MCU_OSPI1_D1 */ + J784S4_WKUP_IOPAD(0x01C, PIN_INPUT, 0) /* (G31) MCU_OSPI1_D2 */ + J784S4_WKUP_IOPAD(0x020, PIN_INPUT, 0) /* (F33) MCU_OSPI1_D3 */ + J784S4_WKUP_IOPAD(0x010, PIN_INPUT, 0) /* (F31) MCU_OSPI1_DQS */ + J784S4_WKUP_IOPAD(0x00C, PIN_INPUT, 0) /* (C31) MCU_OSPI1_LBCLKO */ >; }; };
@@ -437,7 +444,7 @@ &fss { &ospi0 { status = "okay"; pinctrl-names = "default"; - pinctrl-0 = <&mcu_fss0_ospi0_pins_default>; + pinctrl-0 = <&mcu_fss0_ospi0_pins_default>, <&mcu_fss0_ospi0_1_pins_default>; flash@0 { compatible = "jedec,spi-nor";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 313/739 arm64: dts: ti: k3-j721s2: correct pinmux offset for ospi
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Udit Kumar <[email protected]>
[ Upstream commit 06c4e7aa4af0682910ea52d7c23d85f59ea7dcc6 ]
Due to non-addressable regions in J721S2 SOC wkup_pmx was split into four regions from wkup_pmx0 to wkup_pmx3.
Correcting OSPI1 pin mux, which now falls under wkup_pmx1. Along with that removing unused pin mux for OSPI-0.
--- .../dts/ti/k3-j721s2-common-proc-board.dts | 19 ++++++++++--------- arch/arm64/boot/dts/ti/k3-j721s2-som-p0.dtsi | 3 --- 2 files changed, 10 insertions(+), 12 deletions(-)
arch/arm64/boot/dts/ti/k3-j721s2-common-proc-board.dts +10 -9
@@ -249,18 +249,19 @@ J721S2_WKUP_IOPAD(0x104, PIN_INPUT, 0) /* (N26) MCU_ADC1_AIN6 */ J721S2_WKUP_IOPAD(0x108, PIN_INPUT, 0) /* (N27) MCU_ADC1_AIN7 */ >; }; +}; +&wkup_pmx1 { mcu_fss0_ospi1_pins_default: mcu-fss0-ospi1-default-pins { pinctrl-single,pins = < - J721S2_WKUP_IOPAD(0x040, PIN_OUTPUT, 0) /* (A19) MCU_OSPI1_CLK */ - J721S2_WKUP_IOPAD(0x05c, PIN_OUTPUT, 0) /* (D20) MCU_OSPI1_CSn0 */ - J721S2_WKUP_IOPAD(0x060, PIN_OUTPUT, 0) /* (C21) MCU_OSPI1_CSn1 */ - J721S2_WKUP_IOPAD(0x04c, PIN_INPUT, 0) /* (D21) MCU_OSPI1_D0 */ - J721S2_WKUP_IOPAD(0x050, PIN_INPUT, 0) /* (G20) MCU_OSPI1_D1 */ - J721S2_WKUP_IOPAD(0x054, PIN_INPUT, 0) /* (C20) MCU_OSPI1_D2 */ - J721S2_WKUP_IOPAD(0x058, PIN_INPUT, 0) /* (A20) MCU_OSPI1_D3 */ - J721S2_WKUP_IOPAD(0x048, PIN_INPUT, 0) /* (B19) MCU_OSPI1_DQS */ - J721S2_WKUP_IOPAD(0x044, PIN_INPUT, 0) /* (B20) MCU_OSPI1_LBCLKO */ + J721S2_WKUP_IOPAD(0x008, PIN_OUTPUT, 0) /* (A19) MCU_OSPI1_CLK */ + J721S2_WKUP_IOPAD(0x024, PIN_OUTPUT, 0) /* (D20) MCU_OSPI1_CSn0 */ + J721S2_WKUP_IOPAD(0x014, PIN_INPUT, 0) /* (D21) MCU_OSPI1_D0 */ + J721S2_WKUP_IOPAD(0x018, PIN_INPUT, 0) /* (G20) MCU_OSPI1_D1 */ + J721S2_WKUP_IOPAD(0x01c, PIN_INPUT, 0) /* (C20) MCU_OSPI1_D2 */ + J721S2_WKUP_IOPAD(0x020, PIN_INPUT, 0) /* (A20) MCU_OSPI1_D3 */ + J721S2_WKUP_IOPAD(0x010, PIN_INPUT, 0) /* (B19) MCU_OSPI1_DQS */ + J721S2_WKUP_IOPAD(0x00c, PIN_INPUT, 0) /* (B20) MCU_OSPI1_LBCLKO */ >; }; };
arch/arm64/boot/dts/ti/k3-j721s2-som-p0.dtsi +0 -3
@@ -44,9 +44,6 @@ mcu_fss0_ospi0_pins_default: mcu-fss0-ospi0-default-pins { pinctrl-single,pins = < J721S2_WKUP_IOPAD(0x000, PIN_OUTPUT, 0) /* (D19) MCU_OSPI0_CLK */ J721S2_WKUP_IOPAD(0x02c, PIN_OUTPUT, 0) /* (F15) MCU_OSPI0_CSn0 */ - J721S2_WKUP_IOPAD(0x030, PIN_OUTPUT, 0) /* (G17) MCU_OSPI0_CSn1 */ - J721S2_WKUP_IOPAD(0x038, PIN_OUTPUT, 0) /* (F14) MCU_OSPI0_CSn2 */ - J721S2_WKUP_IOPAD(0x03c, PIN_OUTPUT, 0) /* (F17) MCU_OSPI0_CSn3 */ J721S2_WKUP_IOPAD(0x00c, PIN_INPUT, 0) /* (C19) MCU_OSPI0_D0 */ J721S2_WKUP_IOPAD(0x010, PIN_INPUT, 0) /* (F16) MCU_OSPI0_D1 */ J721S2_WKUP_IOPAD(0x014, PIN_INPUT, 0) /* (G15) MCU_OSPI0_D2 */
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 314/739 smackfs: Prevent underflow in smk_set_cipso()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dan Carpenter <[email protected]>
[ Upstream commit 3ad49d37cf5759c3b8b68d02e3563f633d9c1aee ]
There is a upper bound to "catlen" but no lower bound to prevent negatives. I don't see that this necessarily causes a problem but we may as well be safe.
--- security/smack/smackfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
security/smack/smackfs.c +1 -1
@@ -896,7 +896,7 @@ static ssize_t smk_set_cipso(struct file *file, const char __user *buf, } ret =sscanf (rule,"%d" , &catlen); -if (ret !=1 || catlen >SMACK_CIPSO_MAXCATNUM ) +if (ret !=1 || catlen <0 || catlen >SMACK_CIPSO_MAXCATNUM ) goto out; if (format == SMK_FIXED24_FMT &&
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 315/739 drm/amdgpu: Sort the includes in amdgpu/amdgpu_drv.c
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Srinivasan Shanmugam <[email protected]>
[ Upstream commit e2e42edfe8533af7b30f505d41d44e0d180065da ]
Sort the include files that are included in amdgpu_drv.c alphabetically.
Stable-dep-of: 4e2abc197f11 ("drm/amdgpu: Move vram, gtt & flash defines to amdgpu_ ttm & _psp.h")
--- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c +12 -13
@@ -26,30 +26,29 @@#include <drm/drm_drv.h> #include <drm/drm_fbdev_generic.h> #include <drm/drm_gem.h> -#include <drm/drm_vblank.h> #include <drm/drm_managed.h> -#include "amdgpu_drv.h" -#include <drm/drm_pciids.h> -#include <linux/module.h> -#include <linux/pm_runtime.h> -#include <linux/vga_switcheroo.h> #include <drm/drm_probe_helper.h> -#include <linux/mmu_notifier.h> -#include <linux/suspend.h> +#include <drm/drm_vblank.h> +#include <linux/cc_platform.h> #include <linux/dynamic_debug.h> +#include <linux/module.h> +#include <linux/mmu_notifier.h> +#include <linux/pm_runtime.h> +#include <linux/suspend.h> +#include <linux/vga_switcheroo.h> #include "amdgpu.h" -#include "amdgpu_irq.h" +#include "amdgpu_amdkfd.h" #include "amdgpu_dma_buf.h" -#include "amdgpu_sched.h" +#include "amdgpu_drv.h" #include "amdgpu_fdinfo.h" -#include "amdgpu_amdkfd.h" - +#include "amdgpu_irq.h" #include "amdgpu_ras.h" -#include "amdgpu_xgmi.h" #include "amdgpu_reset.h" +#include "amdgpu_sched.h" +#include "amdgpu_xgmi.h" #include "../amdxcp/amdgpu_xcp_drv.h" /*
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 316/739 drm/amdgpu: Move vram, gtt & flash defines to amdgpu_ ttm & _psp.h
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Srinivasan Shanmugam <[email protected]>
[ Upstream commit 4e2abc197f11e25b5813d4c42dada19d36b04666 ]
As amdgpu.h is getting decomposed, move vram and gtt extern defines into amdgpu_ttm.h & flash extern to amdgpu_psp.h
--- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_psp.h | 2 ++ drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.h | 3 +++ 3 files changed, 6 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c +1 -0
@@ -45,6 +45,7 @@#include "amdgpu_drv.h" #include "amdgpu_fdinfo.h" #include "amdgpu_irq.h" +#include "amdgpu_psp.h" #include "amdgpu_ras.h" #include "amdgpu_reset.h" #include "amdgpu_sched.h"
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.h +2 -0
@@ -39,6 +39,8 @@#define PSP_TMR_ALIGNMENT 0x100000#define PSP_FW_NAME_LEN 0x24 +extern const struct attribute_group amdgpu_flash_attr_group; +enum psp_shared_mem_size {PSP_ASD_SHARED_MEM_SIZE =0x0 ,PSP_XGMI_SHARED_MEM_SIZE =0x4000 ,
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.h +3 -0
@@ -39,6 +39,9 @@#define AMDGPU_POISON 0xd0bed0be +extern const struct attribute_group amdgpu_vram_mgr_attr_group; +extern const struct attribute_group amdgpu_gtt_mgr_attr_group; +struct hmm_range ;struct amdgpu_gtt_mgr {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 317/739 drm/amd/pm: fix variable dereferenced issue in amdgpu_device_attr_create()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yang Wang <[email protected]>
[ Upstream commit 25e6373a5b8efc623443f2699d2b929bf3067d76 ]
- fix variable ('attr') dereferenced issue.
- using condition check instead of BUG_ON().
--- drivers/gpu/drm/amd/pm/amdgpu_pm.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
drivers/gpu/drm/amd/pm/amdgpu_pm.c +7 -3
@@ -2172,15 +2172,19 @@ static int amdgpu_device_attr_create(struct amdgpu_device *adev, uint32_t mask, struct list_head *attr_list) { int ret = 0; -struct device_attribute *dev_attr = &attr->dev_attr; -const char *name = dev_attr->attr.name;enum amdgpu_device_attr_states attr_states =ATTR_STATE_SUPPORTED ;struct amdgpu_device_attr_entry *attr_entry; +struct device_attribute *dev_attr; +const char *name;int (*attr_update)(struct amdgpu_device *adev,struct amdgpu_device_attr *attr,uint32_t mask,enum amdgpu_device_attr_states *states) = default_attr_update; -BUG_ON (!attr); +if (!attr) +return -EINVAL ; + + dev_attr = &attr->dev_attr; + name = dev_attr->attr.name; attr_update = attr->attr_update ? attr->attr_update : default_attr_update;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 318/739 drm/msm/a2xx: Call adreno_gpu_init() earlier
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Fabio Estevam <[email protected]>
[ Upstream commit db07ce5da8b26bfeaf437a676ae49bd3bb1eace6 ]
The adreno_is_a20x() and adreno_is_a225() functions rely on the GPU revision, but such information is retrieved inside adreno_gpu_init(), which is called afterwards.
Fix this problem by caling adreno_gpu_init() earlier, so that the GPU information revision is available when adreno_is_a20x() and adreno_is_a225() run.
Tested on a imx53-qsb board.
Patchwork: https://patchwork.freedesktop.org/patch/543456/
--- drivers/gpu/drm/msm/adreno/a2xx_gpu.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/gpu/drm/msm/adreno/a2xx_gpu.c +4 -4
@@ -540,6 +540,10 @@ struct msm_gpu *a2xx_gpu_init(struct drm_device *dev) gpu->perfcntrs = perfcntrs; gpu->num_perfcntrs =ARRAY_SIZE (perfcntrs); + ret =adreno_gpu_init (dev, pdev, adreno_gpu, &funcs,1 ); +if (ret) + goto fail; +if (adreno_is_a20x (adreno_gpu)) adreno_gpu->registers = a200_registers;else if (adreno_is_a225 (adreno_gpu))
@@ -547,10 +551,6 @@ struct msm_gpu *a2xx_gpu_init(struct drm_device *dev)else adreno_gpu->registers = a220_registers; - ret =adreno_gpu_init (dev, pdev, adreno_gpu, &funcs,1 ); -if (ret) - goto fail; -if (!gpu->aspace) {dev_err (dev->dev,"No memory protection without MMU\n" );if (!allow_vram_carveout) {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 319/739 drm/msm/a6xx: Fix GMU lockdep splat
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rob Clark <[email protected]>
[ Upstream commit 3136a0f83519076edfbc14be65f286785434189a ]
For normal GPU devfreq, we need to acquire the GMU lock while already holding devfreq locks. But in the teardown path, we were calling dev_pm_domain_detach() while already holding the GMU lock, resulting in this lockdep splat:
======================================================
WARNING: possible circular locking dependency detected 6.4.3-debug+ #3 Not tainted
------------------------------------------------------
ring0/391 is trying to acquire lock:
ffffff80a025c078 (&devfreq->lock){+.+.}-{3:3}, at: qos_notifier_call+0x30/0x74
but task is already holding lock:
ffffff809b8c1ce8 (&(c->notifiers)->rwsem){++++}-{3:3}, at: blocking_notifier_call_chain+0x34/0x78
which lock already depends on the new lock.
the existing dependency chain (in reverse order) is:
-> #4 (&(c->notifiers)->rwsem){++++}-{3:3}:
down_write+0x58/0x74
__blocking_notifier_chain_register+0x64/0x84
blocking_notifier_chain_register+0x1c/0x28
freq_qos_add_notifier+0x5c/0x7c
dev_pm_qos_add_notifier+0xd4/0xf0
devfreq_add_device+0x42c/0x560
devm_devfreq_add_device+0x6c/0xb8
msm_devfreq_init+0xa8/0x16c [msm]
msm_gpu_init+0x368/0x54c [msm]
adreno_gpu_init+0x248/0x2b0 [msm]
a6xx_gpu_init+0x2d0/0x384 [msm]
adreno_bind+0x264/0x2bc [msm]
component_bind_all+0x124/0x1f4
msm_drm_bind+0x2d0/0x5f4 [msm]
try_to_bring_up_aggregate_device+0x88/0x1a4
__component_add+0xd4/0x128
component_add+0x1c/0x28
dp_display_probe+0x37c/0x3c0 [msm]
platform_probe+0x70/0xc0
really_probe+0x148/0x280
__driver_probe_device+0xfc/0x114
driver_probe_device+0x44/0x100
__device_attach_driver+0x64/0xdc
bus_for_each_drv+0xb0/0xd8
__device_attach+0xe4/0x140
device_initial_probe+0x1c/0x28
bus_probe_device+0x44/0xb0
deferred_probe_work_func+0xb0/0xc8
process_one_work+0x288/0x3d8
worker_thread+0x1f0/0x260
kthread+0xf0/0x100
ret_from_fork+0x10/0x20-> #3 (dev_pm_qos_mtx){+.+.}-{3:3}:
__mutex_lock+0xc8/0x388
mutex_lock_nested+0x2c/0x38
dev_pm_qos_remove_notifier+0x3c/0xc8
genpd_remove_device+0x40/0x11c
genpd_dev_pm_detach+0x88/0x130
dev_pm_domain_detach+0x2c/0x3c
a6xx_gmu_remove+0x44/0xdc [msm]
a6xx_destroy+0x7c/0xa4 [msm]
adreno_unbind+0x50/0x64 [msm]
component_unbind+0x44/0x64
component_unbind_all+0xb4/0xbc
msm_drm_uninit.isra.0+0x124/0x17c [msm]
msm_drm_bind+0x340/0x5f4 [msm]
try_to_bring_up_aggregate_device+0x88/0x1a4
__component_add+0xd4/0x128
component_add+0x1c/0x28
dp_display_probe+0x37c/0x3c0 [msm]
platform_probe+0x70/0xc0
really_probe+0x148/0x280
__driver_probe_device+0xfc/0x114
driver_probe_device+0x44/0x100
__device_attach_driver+0x64/0xdc
bus_for_each_drv+0xb0/0xd8
__device_attach+0xe4/0x140
device_initial_probe+0x1c/0x28
bus_probe_device+0x44/0xb0
deferred_probe_work_func+0xb0/0xc8
process_one_work+0x288/0x3d8
worker_thread+0x1f0/0x260
kthread+0xf0/0x100
ret_from_fork+0x10/0x20-> #2 (&a6xx_gpu->gmu.lock){+.+.}-{3:3}:
__mutex_lock+0xc8/0x388
mutex_lock_nested+0x2c/0x38
a6xx_gpu_set_freq+0x38/0x64 [msm]
msm_devfreq_target+0x170/0x18c [msm]
devfreq_set_target+0x90/0x1e4
devfreq_update_target+0xb4/0xf0
update_devfreq+0x1c/0x28
devfreq_monitor+0x3c/0x10c
process_one_work+0x288/0x3d8
worker_thread+0x1f0/0x260
kthread+0xf0/0x100
ret_from_fork+0x10/0x20-> #1 (&df->lock){+.+.}-{3:3}:
__mutex_lock+0xc8/0x388
mutex_lock_nested+0x2c/0x38
msm_devfreq_get_dev_status+0x4c/0x104 [msm]
devfreq_simple_ondemand_func+0x5c/0x128
devfreq_update_target+0x68/0xf0
update_devfreq+0x1c/0x28
devfreq_monitor+0x3c/0x10c
process_one_work+0x288/0x3d8
worker_thread+0x1f0/0x260
kthread+0xf0/0x100
ret_from_fork+0x10/0x20-> #0 (&devfreq->lock){+.+.}-{3:3}:
__lock_acquire+0xdf8/0x109c
lock_acquire+0x234/0x284
__mutex_lock+0xc8/0x388
mutex_lock_nested+0x2c/0x38
qos_notifier_call+0x30/0x74
qos_min_notifier_call+0x1c/0x28
notifier_call_chain+0xf4/0x114
blocking_notifier_call_chain+0x4c/0x78
pm_qos_update_target+0x184/0x190
freq_qos_apply+0x4c/0x64
apply_constraint+0xf8/0xfc
__dev_pm_qos_update_request+0x138/0x164
dev_pm_qos_update_request+0x44/0x68
msm_devfreq_boost+0x40/0x70 [msm]
msm_devfreq_active+0xc0/0xf0 [msm]
msm_gpu_submit+0xc8/0x12c [msm]
msm_job_run+0x88/0x128 [msm]
drm_sched_main+0x240/0x324 [gpu_sched]
kthread+0xf0/0x100
ret_from_fork+0x10/0x20 other info that might help us debug this:
Chain exists of:
&devfreq->lock --> dev_pm_qos_mtx --> &(c->notifiers)->rwsem
Possible unsafe locking scenario:
CPU0 CPU1
---- ----
rlock(&(c->notifiers)->rwsem);
lock(dev_pm_qos_mtx);
lock(&(c->notifiers)->rwsem);
lock(&devfreq->lock); *** DEADLOCK ***
4 locks held by ring0/391:
#0: ffffff809c811170 (&gpu->lock){+.+.}-{3:3}, at: msm_job_run+0x7c/0x128 [msm]
#1: ffffff809c811208 (&gpu->active_lock){+.+.}-{3:3}, at: msm_gpu_submit+0xa8/0x12c [msm]
#2: ffffffecbbb46600 (dev_pm_qos_mtx){+.+.}-{3:3}, at: dev_pm_qos_update_request+0x38/0x68
#3: ffffff809b8c1ce8 (&(c->notifiers)->rwsem){++++}-{3:3}, at: blocking_notifier_call_chain+0x34/0x78 stack backtrace:
CPU: 6 PID: 391 Comm: ring0 Not tainted 6.4.3debug+ #3
Hardware name: Google Villager (rev1+) with LTE (DT)
Call trace:
dump_backtrace+0xb4/0xf0
show_stack+0x20/0x30
dump_stack_lvl+0x60/0x84
dump_stack+0x18/0x24
print_circular_bug+0x1cc/0x234
check_noncircular+0x78/0xac
__lock_acquire+0xdf8/0x109c
lock_acquire+0x234/0x284
__mutex_lock+0xc8/0x388
mutex_lock_nested+0x2c/0x38
qos_notifier_call+0x30/0x74
qos_min_notifier_call+0x1c/0x28
notifier_call_chain+0xf4/0x114
blocking_notifier_call_chain+0x4c/0x78
pm_qos_update_target+0x184/0x190
freq_qos_apply+0x4c/0x64
apply_constraint+0xf8/0xfc
__dev_pm_qos_update_request+0x138/0x164
dev_pm_qos_update_request+0x44/0x68
msm_devfreq_boost+0x40/0x70 [msm]
msm_devfreq_active+0xc0/0xf0 [msm]
msm_gpu_submit+0xc8/0x12c [msm]
msm_job_run+0x88/0x128 [msm]
drm_sched_main+0x240/0x324 [gpu_sched]
kthread+0xf0/0x100
ret_from_fork+0x10/0x20Fix this by only synchronizing access to gmu->initialized.
Patchwork: https://patchwork.freedesktop.org/patch/551171/
--- drivers/gpu/drm/msm/adreno/a6xx_gmu.c | 11 ++++++++--- drivers/gpu/drm/msm/adreno/a6xx_gpu.c | 2 -- 2 files changed, 8 insertions(+), 5 deletions(-)
drivers/gpu/drm/msm/adreno/a6xx_gmu.c +8 -3
@@ -1435,8 +1435,15 @@ void a6xx_gmu_remove(struct a6xx_gpu *a6xx_gpu)struct a6xx_gmu *gmu = &a6xx_gpu->gmu;struct platform_device *pdev =to_platform_device (gmu->dev); -if (!gmu->initialized) +mutex_lock (&gmu->lock); +if (!gmu->initialized) { +mutex_unlock (&gmu->lock);return ; + } + + gmu->initialized = false; + +mutex_unlock (&gmu->lock);pm_runtime_force_suspend (gmu->dev);
@@ -1466,8 +1473,6 @@ void a6xx_gmu_remove(struct a6xx_gpu *a6xx_gpu)/* Drop reference taken in of_find_device_by_node */ put_device (gmu->dev); - - gmu->initialized = false; } static int cxpd_notifier_cb(struct notifier_block *nb,
drivers/gpu/drm/msm/adreno/a6xx_gpu.c +0 -2
@@ -2091,9 +2091,7 @@ static void a6xx_destroy(struct msm_gpu *gpu)a6xx_llc_slices_destroy (a6xx_gpu); -mutex_lock (&a6xx_gpu->gmu.lock);a6xx_gmu_remove (a6xx_gpu); -mutex_unlock (&a6xx_gpu->gmu.lock);adreno_gpu_cleanup (adreno_gpu);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 320/739 ASoC: SOF: Intel: hda-mlink: fix off-by-one error
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pierre-Louis Bossart <[email protected]>
[ Upstream commit 7075b0c91b3cd5d32b4ac7403f771a3253d3fbf6 ]
The HCHAN parameter should be the highest channel number, not the channel count.
While we're at it, handle LCHAN with the dual __ffs helper.
--- sound/soc/sof/intel/hda-mlink.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-)
sound/soc/sof/intel/hda-mlink.c +11 -1
@@ -781,6 +781,8 @@ int hdac_bus_eml_sdw_map_stream_ch(struct hdac_bus *bus, int sublink, int y, {struct hdac_ext2_link *h2link;u16 __iomem *pcmsycm; +int hchan; +int lchan;u16 val; h2link =find_ext2_link (bus, true,AZX_REG_ML_LEPTR_ID_SDW );
@@ -791,9 +793,17 @@ int hdac_bus_eml_sdw_map_stream_ch(struct hdac_bus *bus, int sublink, int y, h2link->instance_offset * sublink +AZX_REG_SDW_SHIM_PCMSyCM (y); +if (channel_mask) { + hchan =__fls (channel_mask); + lchan =__ffs (channel_mask); + }else { + hchan =0 ; + lchan =0 ; + } +mutex_lock (&h2link->eml_lock); -hdaml_shim_map_stream_ch (pcmsycm,0 ,hweight32 (channel_mask), +hdaml_shim_map_stream_ch (pcmsycm, lchan, hchan, stream_id, dir);mutex_unlock (&h2link->eml_lock);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 321/739 ASoC: SOF: Intel: fix u16/32 confusion in LSDIID
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pierre-Louis Bossart <[email protected]>
[ Upstream commit 7a52d7062e02af4a479da24b40cfd76b54c0cd6c ]
Likely a combination of copy-paste and test coverage problem. Oops.
--- sound/soc/sof/intel/hda-mlink.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
sound/soc/sof/intel/hda-mlink.c +4 -4
@@ -331,14 +331,14 @@ static bool hdaml_link_check_cmdsync(u32 __iomem *lsync, u32 cmdsync_mask)return !!(val & cmdsync_mask); } -static void hdaml_link_set_lsdiid (u32 __iomem *lsdiid,int dev_num) +static void hdaml_link_set_lsdiid (u16 __iomem *lsdiid,int dev_num) { -u32 val; +u16 val; - val =readl (lsdiid); + val =readw (lsdiid); val |=BIT (dev_num); -writel (val, lsdiid); +writew (val, lsdiid); } static void hdaml_shim_map_stream_ch(u16 __iomem *pcmsycm, int lchan, int hchan,
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 322/739 drm/mediatek: Fix uninitialized symbol
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Nancy.Lin <[email protected]>
[ Upstream commit 63ee9438f2aeffb2d1b2df2599c168ca08d35025 ]
Fix Smatch static checker warning
-Fix uninitialized symbol comp_pdev in mtk_ddp_comp_init.
--- drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)
drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c +8 -8
@@ -563,14 +563,15 @@ int mtk_ddp_comp_init(struct device_node *node, struct mtk_ddp_comp *comp,/* Not all drm components have a DTS device node, such as ovl_adaptor, * which is the drm bring up sub driver */ -if (node) { - comp_pdev =of_find_device_by_node (node); -if (!comp_pdev) { -DRM_INFO ("Waiting for device %s\n" , node->full_name); -return -EPROBE_DEFER ; - } - comp->dev = &comp_pdev->dev; +if (!node) +return 0 ; + + comp_pdev =of_find_device_by_node (node); +if (!comp_pdev) { +DRM_INFO ("Waiting for device %s\n" , node->full_name); +return -EPROBE_DEFER ; } + comp->dev = &comp_pdev->dev; if (type == MTK_DISP_AAL || type == MTK_DISP_BLS ||
@@ -580,7 +581,6 @@ int mtk_ddp_comp_init(struct device_node *node, struct mtk_ddp_comp *comp, type ==MTK_DISP_MERGE || type ==MTK_DISP_OVL || type ==MTK_DISP_OVL_2L || - type ==MTK_DISP_OVL_ADAPTOR || type ==MTK_DISP_PWM || type ==MTK_DISP_RDMA || type == MTK_DPI ||
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 323/739 audit: fix possible soft lockup in __audit_inode_child()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Gaosheng Cui <[email protected]>
[ Upstream commit b59bc6e37237e37eadf50cd5de369e913f524463 ]
Tracefs or debugfs maybe cause hundreds to thousands of PATH records, too many PATH records maybe cause soft lockup.
For example:
1. CONFIG_KASAN=y && CONFIG_PREEMPTION=n
2. auditctl -a exit,always -S open -k key
3. sysctl -w kernel.watchdog_thresh=5
4. mkdir /sys/kernel/debug/tracing/instances/test
There may be a soft lockup as follows:
watchdog: BUG: soft lockup - CPU#45 stuck for 7s! [mkdir:15498] Kernel panic - not syncing: softlockup: hung tasks Call trace: dump_backtrace+0x0/0x30c show_stack+0x20/0x30 dump_stack+0x11c/0x174 panic+0x27c/0x494 watchdog_timer_fn+0x2bc/0x390 __run_hrtimer+0x148/0x4fc __hrtimer_run_queues+0x154/0x210 hrtimer_interrupt+0x2c4/0x760 arch_timer_handler_phys+0x48/0x60 handle_percpu_devid_irq+0xe0/0x340 __handle_domain_irq+0xbc/0x130 gic_handle_irq+0x78/0x460 el1_irq+0xb8/0x140 __audit_inode_child+0x240/0x7bc tracefs_create_file+0x1b8/0x2a0 trace_create_file+0x18/0x50 event_create_dir+0x204/0x30c __trace_add_new_event+0xac/0x100 event_trace_add_tracer+0xa0/0x130 trace_array_create_dir+0x60/0x140 trace_array_create+0x1e0/0x370 instance_mkdir+0x90/0xd0 tracefs_syscall_mkdir+0x68/0xa0 vfs_mkdir+0x21c/0x34c do_mkdirat+0x1b4/0x1d4 __arm64_sys_mkdirat+0x4c/0x60 el0_svc_common.constprop.0+0xa8/0x240 do_el0_svc+0x8c/0xc0 el0_svc+0x20/0x30 el0_sync_handler+0xb0/0xb4 el0_sync+0x160/0x180
Therefore, we add cond_resched() to __audit_inode_child() to fix it.
--- kernel/auditsc.c | 2 ++ 1 file changed, 2 insertions(+)
kernel/auditsc.c +2 -0
@@ -2456,6 +2456,8 @@ void __audit_inode_child(struct inode *parent, } } +cond_resched (); +/* is there a matching child entry? */ list_for_each_entry (n, &context->names_list, list) {/* can only match entries that have a name */
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 324/739 block/mq-deadline: use correct way to throttling write requests
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Zhiguo Niu <[email protected]>
[ Upstream commit d47f9717e5cfd0dd8c0ba2ecfa47c38d140f1bb6 ]
The original formula was inaccurate:dd->async_depth = max(1UL, 3 * q->nr_requests / 4);
For write requests, when we assign a tags from sched_tags, data->shallow_depth will be passed to sbitmap_find_bit, see the following code:
nr = sbitmap_find_bit_in_word(&sb->map[index],
min_t (unsigned int, __map_depth(sb, index), depth), alloc_hint, wrap);
The smaller of data->shallow_depth and __map_depth(sb, index) will be used as the maximum range when allocating bits.
For a mmc device (one hw queue, deadline I/O scheduler):q->nr_requests = sched_tags = 128, so according to the previous calculation method, dd->async_depth = data->shallow_depth = 96, and the platform is 64bits with 8 cpus, sched_tags.bitmap_tags.sb.shift=5, sb.maps[]=32/32/32/32, 32 is smaller than 96, whether it is a read or a write I/O, tags can be allocated to the maximum range each time, which has not throttling effect.
In addition, refer to the methods of bfg/kyber I/O scheduler, limit ratiois are calculated base on sched_tags.bitmap_tags.sb.shift.
This patch can throttle write requests really.
--- block/mq-deadline.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
block/mq-deadline.c +2 -1
@@ -646,8 +646,9 @@ static void dd_depth_updated(struct blk_mq_hw_ctx *hctx)struct request_queue *q = hctx->queue;struct deadline_data *dd = q->elevator->elevator_data;struct blk_mq_tags *tags = hctx->sched_tags; +unsigned int shift = tags->bitmap_tags.sb.shift; - dd->async_depth =max (1UL ,3 * q->nr_requests /4 ); + dd->async_depth =max (1U ,3 * (1U << shift) /4 );sbitmap_queue_min_shallow_depth (&tags->bitmap_tags, dd->async_depth); }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 325/739 io_uring: fix drain stalls by invalid SQE
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pavel Begunkov <[email protected]>
[ Upstream commit cfdbaa3a291d6fd2cb4a1a70d74e63b4abc2f5ec ]
cq_extra is protected by ->completion_lock, which io_get_sqe() misses. The bug is harmless as it doesn't happen in real life, requires invalid SQ index array and racing with submission, and only messes up the userspace, i.e. stall requests execution but will be cleaned up on ring destruction.
--- io_uring/io_uring.c | 2 ++ 1 file changed, 2 insertions(+)
io_uring/io_uring.c +2 -0
@@ -2382,7 +2382,9 @@ static bool io_get_sqe(struct io_ring_ctx *ctx, const struct io_uring_sqe **sqe) }/* drop invalid entries */ +spin_lock (&ctx->completion_lock); ctx->cq_extra--; +spin_unlock (&ctx->completion_lock);WRITE_ONCE (ctx->rings->sq_dropped,READ_ONCE (ctx->rings->sq_dropped) +1 );return false;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 326/739 block: move the BIO_CLONED checks out of __bio_try_merge_page
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christoph Hellwig <[email protected]>
[ Upstream commit 939e1a370330841b2c0292a483d7b38f3ee45f88 ]
__bio_try_merge_page is a way too low-level helper to assert that the bio is not cloned. Move the check into bio_add_page and bio_iov_iter_get_pages instead, which are the high level entry points that should enforce this variant. bio_add_hw_page already this check, coverig the third (indirect) caller of __bio_try_merge_page.
Stable-dep-of: 0ece1d649b6d ("bio-integrity: create multi-page bvecs in bio_integrity_add_page()")
--- block/bio.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-)
block/bio.c +6 -3
@@ -945,9 +945,6 @@ static inline bool page_is_mergeable(const struct bio_vec *bv,static bool __bio_try_merge_page (struct bio *bio,struct page *page,unsigned int len,unsigned int off,bool *same_page) { -if (WARN_ON_ONCE (bio_flagged (bio,BIO_CLONED ))) -return false; -if (bio->bi_vcnt >0 ) {struct bio_vec *bv = &bio->bi_io_vec[bio->bi_vcnt -1 ];
@@ -1129,6 +1126,9 @@ int bio_add_page(struct bio *bio, struct page *page, {bool same_page = false; +if (WARN_ON_ONCE (bio_flagged (bio,BIO_CLONED ))) +return 0 ; +if (!__bio_try_merge_page (bio, page, len, offset, &same_page)) {if (bio_full (bio, len))return 0 ;
@@ -1337,6 +1337,9 @@ int bio_iov_iter_get_pages(struct bio *bio, struct iov_iter *iter) {int ret =0 ; +if (WARN_ON_ONCE (bio_flagged (bio,BIO_CLONED ))) +return -EIO ; +if (iov_iter_is_bvec (iter)) {bio_iov_bvec_set (bio, iter);iov_iter_advance (iter, bio->bi_iter.bi_size);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 327/739 block: move the bi_vcnt check out of __bio_try_merge_page
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christoph Hellwig <[email protected]>
[ Upstream commit 0eca8b6f97ac705c5806f7d062207379094fb114 ]
Move the bi_vcnt out of __bio_try_merge_page and into the two callers that don't already have it in preparation for additional changes to __bio_try_merge_page.
Stable-dep-of: 0ece1d649b6d ("bio-integrity: create multi-page bvecs in bio_integrity_add_page()")
--- block/bio.c | 45 ++++++++++++++++++++++----------------------- 1 file changed, 22 insertions(+), 23 deletions(-)
block/bio.c +22 -23
@@ -945,20 +945,17 @@ static inline bool page_is_mergeable(const struct bio_vec *bv,static bool __bio_try_merge_page (struct bio *bio,struct page *page,unsigned int len,unsigned int off,bool *same_page) { -if (bio->bi_vcnt >0 ) { -struct bio_vec *bv = &bio->bi_io_vec[bio->bi_vcnt -1 ]; - -if (page_is_mergeable (bv, page, len, off, same_page)) { -if (bio->bi_iter.bi_size >UINT_MAX - len) { - *same_page = false; -return false; - } - bv->bv_len += len; - bio->bi_iter.bi_size += len; -return true; - } +struct bio_vec *bv = &bio->bi_io_vec[bio->bi_vcnt -1 ]; + +if (!page_is_mergeable (bv, page, len, off, same_page)) +return false; +if (bio->bi_iter.bi_size >UINT_MAX - len) { + *same_page = false; +return false; } -return false; + bv->bv_len += len; + bio->bi_iter.bi_size += len; +return true; }/*
@@ -1129,11 +1126,13 @@ int bio_add_page(struct bio *bio, struct page *page,if (WARN_ON_ONCE (bio_flagged (bio,BIO_CLONED )))return 0 ; -if (!__bio_try_merge_page (bio, page, len, offset, &same_page)) { -if (bio_full (bio, len)) -return 0 ; -__bio_add_page (bio, page, len, offset); - } +if (bio->bi_vcnt >0 && +__bio_try_merge_page (bio, page, len, offset, &same_page)) +return len; + +if (bio_full (bio, len)) +return 0 ; +__bio_add_page (bio, page, len, offset);return len; }EXPORT_SYMBOL (bio_add_page);
@@ -1207,13 +1206,13 @@ static int bio_iov_add_page(struct bio *bio, struct page *page, {bool same_page = false; -if (!__bio_try_merge_page (bio, page, len, offset, &same_page)) { -__bio_add_page (bio, page, len, offset); +if (bio->bi_vcnt >0 && +__bio_try_merge_page (bio, page, len, offset, &same_page)) { +if (same_page) +bio_release_page (bio, page);return 0 ; } - -if (same_page) -bio_release_page (bio, page); +__bio_add_page (bio, page, len, offset);return 0 ; }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 328/739 block: move the bi_size overflow check in __bio_try_merge_page
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christoph Hellwig <[email protected]>
[ Upstream commit 613699050a49760f1d70c74f71bd0b013ca3c356 ]
Checking for availability in bi_size in a function that attempts to merge into an existing segment is a bit odd, as the limit also applies when adding a new segment. This code works fine as we always call __bio_try_merge_page, but contributes to sub-optimal calling conventions and doesn't lead to clear code.
Move it to two of the callers instead, the third one already has a more strict check that includes max_hw_segments anyway.
Stable-dep-of: 0ece1d649b6d ("bio-integrity: create multi-page bvecs in bio_integrity_add_page()")
--- block/bio.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-)
block/bio.c +5 -4
@@ -949,10 +949,6 @@ static bool __bio_try_merge_page(struct bio *bio, struct page *page,if (!page_is_mergeable (bv, page, len, off, same_page))return false; -if (bio->bi_iter.bi_size >UINT_MAX - len) { - *same_page = false; -return false; - } bv->bv_len += len; bio->bi_iter.bi_size += len;return true;
@@ -1125,6 +1121,8 @@ int bio_add_page(struct bio *bio, struct page *page,if (WARN_ON_ONCE (bio_flagged (bio,BIO_CLONED )))return 0 ; +if (bio->bi_iter.bi_size >UINT_MAX - len) +return 0 ;if (bio->bi_vcnt >0 &&__bio_try_merge_page (bio, page, len, offset, &same_page))
@@ -1206,6 +1204,9 @@ static int bio_iov_add_page(struct bio *bio, struct page *page, {bool same_page = false; +if (WARN_ON_ONCE (bio->bi_iter.bi_size >UINT_MAX - len)) +return -EIO ; +if (bio->bi_vcnt >0 &&__bio_try_merge_page (bio, page, len, offset, &same_page)) {if (same_page)
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 329/739 block: move the bi_size update out of __bio_try_merge_page
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christoph Hellwig <[email protected]>
[ Upstream commit 858c708d9efb7e8e5c6320793b778cc17cf8368a ]
The update of bi_size is the only thing in __bio_try_merge_page that needs a bio. Move it to the callers, and merge __bio_try_merge_page and page_is_mergeable into a single bvec_try_merge_page that only takes the current bvec instead of a full bio. This will allow reusing this function for supporting multi-page integrity payload bvecs.
Stable-dep-of: 0ece1d649b6d ("bio-integrity: create multi-page bvecs in bio_integrity_add_page()")
--- block/bio.c | 57 +++++++++++++++++++---------------------------------- 1 file changed, 20 insertions(+), 37 deletions(-)
block/bio.c +20 -37
@@ -903,9 +903,8 @@ static inline bool bio_full(struct bio *bio, unsigned len)return false; } -static inline bool page_is_mergeable (const struct bio_vec *bv, -struct page *page,unsigned int len,unsigned int off, -bool *same_page) +static bool bvec_try_merge_page (struct bio_vec *bv,struct page *page, +unsigned int len,unsigned int off,bool *same_page) {size_t bv_end = bv->bv_offset + bv->bv_len;phys_addr_t vec_end_addr =page_to_phys (bv->bv_page) + bv_end -1 ;
@@ -919,38 +918,14 @@ static inline bool page_is_mergeable(const struct bio_vec *bv,return false; *same_page = ((vec_end_addr &PAGE_MASK ) == page_addr); -if (*same_page) -return true; -else if (IS_ENABLED (CONFIG_KMSAN )) -return false; -return (bv->bv_page + bv_end /PAGE_SIZE ) == (page + off /PAGE_SIZE ); -} - -/** -* __bio_try_merge_page - try appending data to an existing bvec. -* @bio: destination bio -* @page: start page to add -* @len: length of the data to add -* @off: offset of the data relative to @page -* @same_page: return if the segment has been merged inside the same page -* -* Try to add the data at @page + @off to the last bvec of @bio. This is a -* useful optimisation for file systems with a block size smaller than the -* page size. -* -* Warn if (@len, @off) crosses pages in case that @same_page is true. -* -* Return %true on success or %false on failure. -*/ -static bool __bio_try_merge_page (struct bio *bio,struct page *page, -unsigned int len,unsigned int off,bool *same_page) -{ -struct bio_vec *bv = &bio->bi_io_vec[bio->bi_vcnt -1 ]; +if (!*same_page) { +if (IS_ENABLED (CONFIG_KMSAN )) +return false; +if (bv->bv_page + bv_end /PAGE_SIZE != page + off /PAGE_SIZE ) +return false; + } -if (!page_is_mergeable (bv, page, len, off, same_page)) -return false; bv->bv_len += len; - bio->bi_iter.bi_size += len;return true; }
@@ -972,7 +947,7 @@ static bool bio_try_merge_hw_seg(struct request_queue *q, struct bio *bio,return false;if (bv->bv_len + len >queue_max_segment_size (q))return false; -return __bio_try_merge_page (bio, page, len, offset, same_page); +return bvec_try_merge_page (bv, page, len, offset, same_page); }/**
@@ -1001,8 +976,11 @@ int bio_add_hw_page(struct request_queue *q, struct bio *bio,return 0 ;if (bio->bi_vcnt >0 ) { -if (bio_try_merge_hw_seg (q, bio, page, len, offset, same_page)) +if (bio_try_merge_hw_seg (q, bio, page, len, offset, + same_page)) { + bio->bi_iter.bi_size += len;return len; + }/* * If the queue doesn't support SG gaps and adding this segment
@@ -1125,8 +1103,11 @@ int bio_add_page(struct bio *bio, struct page *page,return 0 ;if (bio->bi_vcnt >0 && -__bio_try_merge_page (bio, page, len, offset, &same_page)) +bvec_try_merge_page (&bio->bi_io_vec[bio->bi_vcnt -1 ], + page, len, offset, &same_page)) { + bio->bi_iter.bi_size += len;return len; + }if (bio_full (bio, len))return 0 ;
@@ -1208,7 +1189,9 @@ static int bio_iov_add_page(struct bio *bio, struct page *page,return -EIO ;if (bio->bi_vcnt >0 && -__bio_try_merge_page (bio, page, len, offset, &same_page)) { +bvec_try_merge_page (&bio->bi_io_vec[bio->bi_vcnt -1 ], + page, len, offset, &same_page)) { + bio->bi_iter.bi_size += len;if (same_page)bio_release_page (bio, page);return 0 ;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 330/739 block: dont pass a bio to bio_try_merge_hw_seg
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christoph Hellwig <[email protected]>
[ Upstream commit ae42f0b3bf65912e122fc2e8d5f6d94b51156dba ]
There is no good reason to pass the bio to bio_try_merge_hw_seg. Just pass the current bvec and rename the function to bvec_try_merge_hw_page. This will allow reusing this function for supporting multi-page integrity payload bvecs.
Stable-dep-of: 0ece1d649b6d ("bio-integrity: create multi-page bvecs in bio_integrity_add_page()")
--- block/bio.c | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-)
block/bio.c +7 -9
@@ -934,11 +934,10 @@ static bool bvec_try_merge_page(struct bio_vec *bv, struct page *page,* size limit. This is not for normal read/write bios, but for passthrough * or Zone Append operations that we can't split. */ -static bool bio_try_merge_hw_seg (struct request_queue *q,struct bio *bio, -struct page *page,unsigned len, -unsigned offset,bool *same_page) +static bool bvec_try_merge_hw_page (struct request_queue *q,struct bio_vec *bv, +struct page *page,unsigned len,unsigned offset, +bool *same_page) { -struct bio_vec *bv = &bio->bi_io_vec[bio->bi_vcnt -1 ];unsigned long mask =queue_segment_boundary (q);phys_addr_t addr1 =page_to_phys (bv->bv_page) + bv->bv_offset;phys_addr_t addr2 =page_to_phys (page) + offset + len -1 ;
@@ -967,8 +966,6 @@ int bio_add_hw_page(struct request_queue *q, struct bio *bio, struct page *page, unsigned int len, unsigned int offset, unsigned int max_sectors, bool *same_page) { - struct bio_vec *bvec; - if (WARN_ON_ONCE(bio_flagged(bio, BIO_CLONED))) return 0;
@@ -976,7 +973,9 @@ int bio_add_hw_page(struct request_queue *q, struct bio *bio,return 0 ;if (bio->bi_vcnt >0 ) { -if (bio_try_merge_hw_seg (q, bio, page, len, offset, +struct bio_vec *bv = &bio->bi_io_vec[bio->bi_vcnt -1 ]; + +if (bvec_try_merge_hw_page (q, bv, page, len, offset, same_page)) { bio->bi_iter.bi_size += len;return len;
@@ -986,8 +985,7 @@ int bio_add_hw_page(struct request_queue *q, struct bio *bio,* If the queue doesn't support SG gaps and adding this segment * would create a gap, disallow it. */ - bvec = &bio->bi_io_vec[bio->bi_vcnt -1 ]; -if (bvec_gap_to_prev (&q->limits, bvec, offset)) +if (bvec_gap_to_prev (&q->limits, bv, offset))return 0 ; }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 331/739 block: make bvec_try_merge_hw_page() non-static
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jinyoung Choi <[email protected]>
[ Upstream commit 7c8998f75d2d42ddefb172239b0f689392958309 ]
This will be used for multi-page configuration for integrity payload.
Stable-dep-of: 0ece1d649b6d ("bio-integrity: create multi-page bvecs in bio_integrity_add_page()")
--- block/bio.c | 2 +- block/blk.h | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-)
block/bio.c +1 -1
@@ -934,7 +934,7 @@ static bool bvec_try_merge_page(struct bio_vec *bv, struct page *page,* size limit. This is not for normal read/write bios, but for passthrough * or Zone Append operations that we can't split. */ -static bool bvec_try_merge_hw_page (struct request_queue *q,struct bio_vec *bv, +bool bvec_try_merge_hw_page (struct request_queue *q,struct bio_vec *bv,struct page *page,unsigned len,unsigned offset,bool *same_page) {
block/blk.h +4 -0
@@ -76,6 +76,10 @@ struct bio_vec *bvec_alloc(mempool_t *pool, unsigned short *nr_vecs, gfp_t gfp_mask);void bvec_free (mempool_t *pool,struct bio_vec *bv,unsigned short nr_vecs); +bool bvec_try_merge_hw_page (struct request_queue *q,struct bio_vec *bv, +struct page *page,unsigned len,unsigned offset, +bool *same_page); +static inline bool biovec_phys_mergeable (struct request_queue *q,struct bio_vec *vec1,struct bio_vec *vec2) {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 332/739 bio-integrity: create multi-page bvecs in bio_integrity_add_page()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jinyoung Choi <[email protected]>
[ Upstream commit 0ece1d649b6dd615925a72bc1824d6b9fa5b998a ]
In general, the bvec data structure consists of one for physically continuous pages. But, in the bvec configuration for bip, physically continuous integrity pages are composed of each bvec.
Allow bio_integrity_add_page() to create multi-page bvecs, just like the bio payloads. This simplifies adding larger payloads, and fixes support for non-tiny workloads with nvme, which stopped using scatterlist for metadata a while ago.
--- block/bio-integrity.c | 31 ++++++++++++++++++++++++------- 1 file changed, 24 insertions(+), 7 deletions(-)
block/bio-integrity.c +24 -7
@@ -123,17 +123,34 @@ void bio_integrity_free(struct bio *bio)int bio_integrity_add_page (struct bio *bio,struct page *page,unsigned int len,unsigned int offset) { +struct request_queue *q =bdev_get_queue (bio->bi_bdev);struct bio_integrity_payload *bip =bio_integrity (bio); -if (bip->bip_vcnt >= bip->bip_max_vcnt) { -printk (KERN_ERR "%s: bip_vec full\n" , __func__); +if (((bip->bip_iter.bi_size + len) >>SECTOR_SHIFT ) > +queue_max_hw_sectors (q))return 0 ; - } -if (bip->bip_vcnt && -bvec_gap_to_prev (&bdev_get_queue (bio->bi_bdev)->limits, - &bip->bip_vec[bip->bip_vcnt -1 ], offset)) -return 0 ; +if (bip->bip_vcnt >0 ) { +struct bio_vec *bv = &bip->bip_vec[bip->bip_vcnt -1 ]; +bool same_page = false; + +if (bvec_try_merge_hw_page (q, bv, page, len, offset, + &same_page)) { + bip->bip_iter.bi_size += len; +return len; + } + +if (bip->bip_vcnt >= +min (bip->bip_max_vcnt,queue_max_integrity_segments (q))) +return 0 ; + +/* +* If the queue doesn't support SG gaps and adding this segment +* would create a gap, disallow it. +*/ +if (bvec_gap_to_prev (&q->limits, bv, offset)) +return 0 ; + }bvec_set_page (&bip->bip_vec[bip->bip_vcnt], page, len, offset); bip->bip_vcnt++;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 333/739 drm/mediatek: dp: Add missing error checks in mtk_dp_parse_capabilities
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: AngeloGioacchino Del Regno <[email protected]>
[ Upstream commit cfc146137a9f12e883ba64bc496b6da4d23f26d5 ]
If reading the RX capabilities fails the training pattern will be set
wrongly: add error checking for drm_dp_read_dpcd_caps() and return if anything went wrong with it.
While at it, also add a less critical error check when writing to clear the ESI0 IRQ vector.
--- drivers/gpu/drm/mediatek/mtk_dp.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-)
drivers/gpu/drm/mediatek/mtk_dp.c +10 -5
@@ -1588,7 +1588,9 @@ static int mtk_dp_parse_capabilities(struct mtk_dp *mtk_dp)u8 val;ssize_t ret; -drm_dp_read_dpcd_caps (&mtk_dp->aux, mtk_dp->rx_cap); + ret =drm_dp_read_dpcd_caps (&mtk_dp->aux, mtk_dp->rx_cap); +if (ret <0 ) +return ret;if (drm_dp_tps4_supported (mtk_dp->rx_cap)) mtk_dp->train_info.channel_eq_pattern =DP_TRAINING_PATTERN_4 ;
@@ -1615,10 +1617,13 @@ static int mtk_dp_parse_capabilities(struct mtk_dp *mtk_dp)return ret ==0 ? -EIO : ret; } -if (val) -drm_dp_dpcd_writeb (&mtk_dp->aux, -DP_DEVICE_SERVICE_IRQ_VECTOR_ESI0 , - val); +if (val) { + ret =drm_dp_dpcd_writeb (&mtk_dp->aux, +DP_DEVICE_SERVICE_IRQ_VECTOR_ESI0 , + val); +if (ret <0 ) +return ret; + } }return 0 ;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 334/739 arm64: dts: ti: k3-j784s4-evm: Correct Pin mux offset for ADC
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Udit Kumar <[email protected]>
[ Upstream commit 8be3ac2d8bd77bb9cb9ddbb7a545decf9f5e4181 ]
After splitting wkup_pmx pin mux for J784S4 into four regions. Pin mux offset for ADC nodes were not updated to align with new regions, due to this while probing ADC driver out of range error was seen.
Pin mux offsets for ADC nodes are corrected in this patch.
--- arch/arm64/boot/dts/ti/k3-j784s4-evm.dts | 32 ++++++++++++------------ 1 file changed, 16 insertions(+), 16 deletions(-)
arch/arm64/boot/dts/ti/k3-j784s4-evm.dts +16 -16
@@ -340,27 +340,27 @@ J784S4_WKUP_IOPAD(0x030, PIN_INPUT, 0) /* (B35) MCU_MDIO0_MDIO */ mcu_adc0_pins_default: mcu-adc0-default-pins { pinctrl-single,pins = < - J784S4_WKUP_IOPAD(0x134, PIN_INPUT, 0) /* (P36) MCU_ADC0_AIN0 */ - J784S4_WKUP_IOPAD(0x138, PIN_INPUT, 0) /* (V36) MCU_ADC0_AIN1 */ - J784S4_WKUP_IOPAD(0x13c, PIN_INPUT, 0) /* (T34) MCU_ADC0_AIN2 */ - J784S4_WKUP_IOPAD(0x140, PIN_INPUT, 0) /* (T36) MCU_ADC0_AIN3 */ - J784S4_WKUP_IOPAD(0x144, PIN_INPUT, 0) /* (P34) MCU_ADC0_AIN4 */ - J784S4_WKUP_IOPAD(0x148, PIN_INPUT, 0) /* (R37) MCU_ADC0_AIN5 */ - J784S4_WKUP_IOPAD(0x14c, PIN_INPUT, 0) /* (R33) MCU_ADC0_AIN6 */ - J784S4_WKUP_IOPAD(0x150, PIN_INPUT, 0) /* (V38) MCU_ADC0_AIN7 */ + J784S4_WKUP_IOPAD(0x0cc, PIN_INPUT, 0) /* (P36) MCU_ADC0_AIN0 */ + J784S4_WKUP_IOPAD(0x0d0, PIN_INPUT, 0) /* (V36) MCU_ADC0_AIN1 */ + J784S4_WKUP_IOPAD(0x0d4, PIN_INPUT, 0) /* (T34) MCU_ADC0_AIN2 */ + J784S4_WKUP_IOPAD(0x0d8, PIN_INPUT, 0) /* (T36) MCU_ADC0_AIN3 */ + J784S4_WKUP_IOPAD(0x0dc, PIN_INPUT, 0) /* (P34) MCU_ADC0_AIN4 */ + J784S4_WKUP_IOPAD(0x0e0, PIN_INPUT, 0) /* (R37) MCU_ADC0_AIN5 */ + J784S4_WKUP_IOPAD(0x0e4, PIN_INPUT, 0) /* (R33) MCU_ADC0_AIN6 */ + J784S4_WKUP_IOPAD(0x0e8, PIN_INPUT, 0) /* (V38) MCU_ADC0_AIN7 */ >; }; mcu_adc1_pins_default: mcu-adc1-default-pins { pinctrl-single,pins = < - J784S4_WKUP_IOPAD(0x154, PIN_INPUT, 0) /* (Y38) MCU_ADC1_AIN0 */ - J784S4_WKUP_IOPAD(0x158, PIN_INPUT, 0) /* (Y34) MCU_ADC1_AIN1 */ - J784S4_WKUP_IOPAD(0x15c, PIN_INPUT, 0) /* (V34) MCU_ADC1_AIN2 */ - J784S4_WKUP_IOPAD(0x160, PIN_INPUT, 0) /* (W37) MCU_ADC1_AIN3 */ - J784S4_WKUP_IOPAD(0x164, PIN_INPUT, 0) /* (AA37) MCU_ADC1_AIN4 */ - J784S4_WKUP_IOPAD(0x168, PIN_INPUT, 0) /* (W33) MCU_ADC1_AIN5 */ - J784S4_WKUP_IOPAD(0x16c, PIN_INPUT, 0) /* (U33) MCU_ADC1_AIN6 */ - J784S4_WKUP_IOPAD(0x170, PIN_INPUT, 0) /* (Y36) MCU_ADC1_AIN7 */ + J784S4_WKUP_IOPAD(0x0ec, PIN_INPUT, 0) /* (Y38) MCU_ADC1_AIN0 */ + J784S4_WKUP_IOPAD(0x0f0, PIN_INPUT, 0) /* (Y34) MCU_ADC1_AIN1 */ + J784S4_WKUP_IOPAD(0x0f4, PIN_INPUT, 0) /* (V34) MCU_ADC1_AIN2 */ + J784S4_WKUP_IOPAD(0x0f8, PIN_INPUT, 0) /* (W37) MCU_ADC1_AIN3 */ + J784S4_WKUP_IOPAD(0x0fc, PIN_INPUT, 0) /* (AA37) MCU_ADC1_AIN4 */ + J784S4_WKUP_IOPAD(0x100, PIN_INPUT, 0) /* (W33) MCU_ADC1_AIN5 */ + J784S4_WKUP_IOPAD(0x104, PIN_INPUT, 0) /* (U33) MCU_ADC1_AIN6 */ + J784S4_WKUP_IOPAD(0x108, PIN_INPUT, 0) /* (Y36) MCU_ADC1_AIN7 */ >; }; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 335/739 arm64: dts: ti: k3-j784s4: Fix interrupt ranges for wkup & main gpio
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Apelete Seketeli <[email protected]>
[ Upstream commit 05a1f130101e7a49ff1e8734939facd43596ea26 ]
This patch fixes the interrupt range for wakeup and main domain gpio interrupt routers. They were wrongly subtracted by 32 instead of following what is defined in the interrupt map in the TRM (Table 9-35).
--- arch/arm64/boot/dts/ti/k3-j784s4-main.dtsi | 2 +- arch/arm64/boot/dts/ti/k3-j784s4-mcu-wakeup.dtsi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/ti/k3-j784s4-main.dtsi +1 -1
@@ -60,7 +60,7 @@ main_gpio_intr: interrupt-controller@a00000 { #interrupt-cells = <1>; ti,sci = <&sms>; ti,sci-dev-id = <10>; - ti,interrupt-ranges = <8 360 56>; + ti,interrupt-ranges = <8 392 56>; }; main_pmx0: pinctrl@11c000 {
arch/arm64/boot/dts/ti/k3-j784s4-mcu-wakeup.dtsi +1 -1
@@ -107,7 +107,7 @@ wkup_gpio_intr: interrupt-controller@42200000 { #interrupt-cells = <1>; ti,sci = <&sms>; ti,sci-dev-id = <177>; - ti,interrupt-ranges = <16 928 16>; + ti,interrupt-ranges = <16 960 16>; }; /* MCU_TIMERIO pad input CTRLMMR_MCU_TIMER*_CTRL registers */
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 336/739 bus: ti-sysc: Fix build warning for 64-bit build
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Tony Lindgren <[email protected]>
[ Upstream commit e1e1e9bb9d943ec690670a609a5f660ca10eaf85 ]
Fix "warning: cast from pointer to integer of different size" on 64-bit builds.
Note that this is a cosmetic fix at this point as the driver is not yet used for 64-bit systems.
--- drivers/bus/ti-sysc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/bus/ti-sysc.c +1 -1
@@ -3106,7 +3106,7 @@ static int sysc_init_static_data(struct sysc *ddata) match =soc_device_match (sysc_soc_match);if (match && match->data) - sysc_soc->soc = (int )match->data; + sysc_soc->soc = (enum sysc_soc )match->data;/* * Check and warn about possible old incomplete dtb. We now want to see
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 337/739 drm/mediatek: Remove freeing not dynamic allocated memory
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jason-JH.Lin <[email protected]>
[ Upstream commit 27b9e2ea3f2757da26bb8280e46f7fdbb1acb219 ]
Fixing the coverity issue of:mtk_drm_cmdq_pkt_destroy frees address of mtk_crtc->cmdq_handle
So remove the free function.
--- drivers/gpu/drm/mediatek/mtk_drm_crtc.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
drivers/gpu/drm/mediatek/mtk_drm_crtc.c +2 -5
@@ -116,10 +116,9 @@ static int mtk_drm_cmdq_pkt_create(struct cmdq_client *client, struct cmdq_pkt *dma_addr_t dma_addr; pkt->va_base =kzalloc (size,GFP_KERNEL ); -if (!pkt->va_base) { -kfree (pkt); +if (!pkt->va_base)return -ENOMEM ; - } + pkt->buf_size = size; pkt->cl = (void *)client;
@@ -129,7 +128,6 @@ static int mtk_drm_cmdq_pkt_create(struct cmdq_client *client, struct cmdq_pkt *if (dma_mapping_error (dev, dma_addr)) {dev_err (dev,"dma map failed, size=%u\n" , (u32 )(u64 )size);kfree (pkt->va_base); -kfree (pkt);return -ENOMEM ; }
@@ -145,7 +143,6 @@ static void mtk_drm_cmdq_pkt_destroy(struct cmdq_pkt *pkt)dma_unmap_single (client->chan->mbox->dev, pkt->pa_base, pkt->buf_size,DMA_TO_DEVICE ); kfree(pkt->va_base); - kfree(pkt); }#endif
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 338/739 drm/mediatek: Add cnt checking for coverity issue
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jason-JH.Lin <[email protected]>
[ Upstream commit d761b9450e31e5abd212f0085d424ed32760de5a ]
CERT-C Characters and Strings (CERT STR31-C) all_drm_priv[cnt] evaluates to an address that could be at negative offset of an array.
In mtk_drm_get_all_drm_priv():
Guarantee that storage for strings has sufficient space for character data and the null terminator.
So change cnt to unsigned int and check its max value.
--- drivers/gpu/drm/mediatek/mtk_drm_drv.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/gpu/drm/mediatek/mtk_drm_drv.c +4 -1
@@ -354,7 +354,7 @@ static bool mtk_drm_get_all_drm_priv(struct device *dev)const struct of_device_id *of_id;struct device_node *node;struct device *drm_dev; -int cnt =0 ; +unsigned int cnt =0 ;int i, j;for_each_child_of_node (phandle->parent, node) {
@@ -375,6 +375,9 @@ static bool mtk_drm_get_all_drm_priv(struct device *dev) all_drm_priv[cnt] =dev_get_drvdata (drm_dev);if (all_drm_priv[cnt] && all_drm_priv[cnt]->mtk_drm_bound) cnt++; + +if (cnt ==MAX_CRTC ) +break ; }if (drm_priv->data->mmsys_dev_num == cnt) {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 339/739 arm64: dts: imx8mp-debix: remove unused fec pinctrl node
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Marco Felsch <[email protected]>
[ Upstream commit 574e4099d787c2eb41a43f14c453e422515bf658 ]
The SoM A uses the EQOS ethernet interface and not the FEC, so drop the interface pinctrl node from the device tree.
--- .../dts/freescale/imx8mp-debix-model-a.dts | 22 ------------------- 1 file changed, 22 deletions(-)
arch/arm64/boot/dts/freescale/imx8mp-debix-model-a.dts +0 -22
@@ -355,28 +355,6 @@ MX8MP_IOMUXC_SAI1_TXD6__GPIO4_IO18 0x19 >; }; - pinctrl_fec: fecgrp { - fsl,pins = < - MX8MP_IOMUXC_SAI1_RXD2__ENET1_MDC 0x3 - MX8MP_IOMUXC_SAI1_RXD3__ENET1_MDIO 0x3 - MX8MP_IOMUXC_SAI1_RXD4__ENET1_RGMII_RD0 0x91 - MX8MP_IOMUXC_SAI1_RXD5__ENET1_RGMII_RD1 0x91 - MX8MP_IOMUXC_SAI1_RXD6__ENET1_RGMII_RD2 0x91 - MX8MP_IOMUXC_SAI1_RXD7__ENET1_RGMII_RD3 0x91 - MX8MP_IOMUXC_SAI1_TXC__ENET1_RGMII_RXC 0x91 - MX8MP_IOMUXC_SAI1_TXFS__ENET1_RGMII_RX_CTL 0x91 - MX8MP_IOMUXC_SAI1_TXD0__ENET1_RGMII_TD0 0x1f - MX8MP_IOMUXC_SAI1_TXD1__ENET1_RGMII_TD1 0x1f - MX8MP_IOMUXC_SAI1_TXD2__ENET1_RGMII_TD2 0x1f - MX8MP_IOMUXC_SAI1_TXD3__ENET1_RGMII_TD3 0x1f - MX8MP_IOMUXC_SAI1_TXD4__ENET1_RGMII_TX_CTL 0x1f - MX8MP_IOMUXC_SAI1_TXD5__ENET1_RGMII_TXC 0x1f - MX8MP_IOMUXC_SAI1_RXD1__ENET1_1588_EVENT1_OUT 0x1f - MX8MP_IOMUXC_SAI1_RXD0__ENET1_1588_EVENT1_IN 0x1f - MX8MP_IOMUXC_SAI1_TXD7__GPIO4_IO19 0x19 - >; - }; - pinctrl_gpio_led: gpioledgrp { fsl,pins = < MX8MP_IOMUXC_NAND_READY_B__GPIO3_IO16 0x19
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 340/739 ARM: dts: qcom: ipq4019: correct SDHCI XO clock
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Robert Marko <[email protected]>
[ Upstream commit b5ed7a5c1fdb3981713f7b637b72aa390c3db036 ]
Using GCC_DCD_XO_CLK as the XO clock for SDHCI controller is not correct, it seems that I somehow made a mistake of passing it instead of the fixed XO clock.
--- arch/arm/boot/dts/qcom/qcom-ipq4019.dtsi | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-)
arch/arm/boot/dts/qcom/qcom-ipq4019.dtsi +6 -3
@@ -230,9 +230,12 @@ sdhci: mmc@7824900 { interrupts = <GIC_SPI 123 IRQ_TYPE_LEVEL_HIGH>, <GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>; interrupt-names = "hc_irq", "pwr_irq"; bus-width = <8>; - clocks = <&gcc GCC_SDCC1_AHB_CLK>, <&gcc GCC_SDCC1_APPS_CLK>, - <&gcc GCC_DCD_XO_CLK>; - clock-names = "iface", "core", "xo"; + clocks = <&gcc GCC_SDCC1_AHB_CLK>, + <&gcc GCC_SDCC1_APPS_CLK>, + <&xo>; + clock-names = "iface", + "core", + "xo"; status = "disabled"; };
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 341/739 arm64: dts: ti: k3-am62x-sk-common: Update main-i2c1 frequency
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Aradhya Bhatia <[email protected]>
[ Upstream commit 73387da70f9c26b6fba4f62371d013cce14663d9 ]
The Display Data Channel (DDC) transactions between an HDMI transmitter (SIL9022A in this case) and an HDMI monitor, occur at a maximum of 100KHz. That's the maximum supported frequency within DDC standards.
While the SIL9022A can transact with the core at 400KHz, it needs to drop the frequency to 100KHz when communicating with the monitor, otherwise, the i2c controller times out and shows warning like this.
[ 985.773431] omap_i2c 20010000.i2c: controller timed out
That feature, however, has not been enabled in the SIL9022 driver.
Since, dropping the frequency doesn't affect any other devices on the bus, drop the main-i2c1 frequency from 400KHz to 100KHz.
--- arch/arm64/boot/dts/ti/k3-am62x-sk-common.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/ti/k3-am62x-sk-common.dtsi +1 -1
@@ -300,7 +300,7 @@ &main_i2c1 { status = "okay"; pinctrl-names = "default"; pinctrl-0 = <&main_i2c1_pins_default>; - clock-frequency = <400000>; + clock-frequency = <100000>; tlv320aic3106: audio-codec@1b { #sound-dai-cells = <0>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 342/739 drm/mediatek: Fix potential memory leak if vmap() fail
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Sui Jingfeng <[email protected]>
[ Upstream commit 379091e0f6d179d1a084c65de90fa44583b14a70 ]
Also return -ENOMEM if such a failure happens, the implement should take responsibility for the error handling.
--- drivers/gpu/drm/mediatek/mtk_drm_gem.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/gpu/drm/mediatek/mtk_drm_gem.c +5 -1
@@ -247,7 +247,11 @@ int mtk_drm_gem_prime_vmap(struct drm_gem_object *obj, struct iosys_map *map) mtk_gem->kvaddr =vmap (mtk_gem->pages, npages,VM_MAP ,pgprot_writecombine (PAGE_KERNEL )); - +if (!mtk_gem->kvaddr) { +kfree (sgt); +kfree (mtk_gem->pages); +return -ENOMEM ; + } out:kfree (sgt);iosys_map_set_vaddr (map, mtk_gem->kvaddr);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 343/739 drm/mediatek: Fix void-pointer-to-enum-cast warning
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jason-JH.Lin <[email protected]>
[ Upstream commit 89cba955f879b1c6a9a71f67c8fb92ea8f5dfdc4 ]
1. Fix build warning message in mtk_disp_ovl_adaptor.c
Quoted 1 line
Quoted 1 line
drivers/gpu/drm/mediatek/mtk_disp_ovl_adaptor.c:415:10:
warning: cast to smaller integer type 'enum mtk_ovl_adaptor_comp_type' from 'const void *' [-Wvoid-pointer-to-enum-cast]
type = (enum mtk_ovl_adaptor_comp_type)of_id->data;
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 warning generated.
2. Also fix the same warning message in mtk_drm_drv.c
Quoted 1 line
Quoted 1 line
drivers/gpu/drm/mediatek/mtk_drm_drv.c:832:15:
warning: cast to smaller integer type 'enum mtk_ddp_comp_type' from 'const void *' [-Wvoid-pointer-to-enum-cast]
comp_type = (enum mtk_ddp_comp_type)of_id->data;
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 warning generated.
--- drivers/gpu/drm/mediatek/mtk_disp_ovl_adaptor.c | 2 +- drivers/gpu/drm/mediatek/mtk_drm_drv.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/mediatek/mtk_disp_ovl_adaptor.c +1 -1
@@ -426,7 +426,7 @@ static int ovl_adaptor_comp_init(struct device *dev, struct component_match **macontinue ; } - type = (enum mtk_ovl_adaptor_comp_type )of_id->data; + type = (enum mtk_ovl_adaptor_comp_type )(uintptr_t )of_id->data; id =ovl_adaptor_comp_get_id (dev, node, type);if (id <0 ) { dev_warn(dev, "Skipping unknown component %pOF\n",
drivers/gpu/drm/mediatek/mtk_drm_drv.c +1 -1
@@ -832,7 +832,7 @@ static int mtk_drm_probe(struct platform_device *pdev)continue ; } - comp_type = (enum mtk_ddp_comp_type )of_id->data; + comp_type = (enum mtk_ddp_comp_type )(uintptr_t )of_id->data;if (comp_type ==MTK_DISP_MUTEX ) {int id;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 344/739 arm64: dts: qcom: apq8016-sbc: Fix ov5640 regulator supply names
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Bryan O'Donoghue <[email protected]>
[ Upstream commit 43a684580819e7f35b6cb38236be63c4cba26ef4 ]
The ov5640 driver expects DOVDD, AVDD and DVDD as regulator supply names.
The ov5640 has depended on these names since the driver was committed upstream in 2017. Similarly apq8016-sbc.dtsi has had completely different regulator names since its own initial commit in 2020.
Perhaps the regulators were left on in previous 410c bootloaders. In any case today on 6.5 we won't switch on the ov5640 without correctly naming the regulators.
--- arch/arm64/boot/dts/qcom/apq8016-sbc.dts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
arch/arm64/boot/dts/qcom/apq8016-sbc.dts +3 -3
@@ -287,9 +287,9 @@ camera_rear@3b { clock-names = "xclk"; clock-frequency = <23880000>; - vdddo-supply = <&camera_vdddo_1v8>; - vdda-supply = <&camera_vdda_2v8>; - vddd-supply = <&camera_vddd_1v5>; + DOVDD-supply = <&camera_vdddo_1v8>; + AVDD-supply = <&camera_vdda_2v8>; + DVDD-supply = <&camera_vddd_1v5>; /* No camera mezzanine by default */ status = "disabled";
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 345/739 arm64: dts: qcom: apq8016-sbc: Rename ov5640 enable-gpios to powerdown-gpios
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Bryan O'Donoghue <[email protected]>
[ Upstream commit 4facccb44a82129195878750eed8f9890091c1b8 ]
There are two control lines controlled by GPIO going into ov5640
- Reset
- Powerdown
The driver and yaml expect "reset-gpios" and "powerdown-gpios" there has never been an "enable-gpios".
--- arch/arm64/boot/dts/qcom/apq8016-sbc.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/apq8016-sbc.dts +1 -1
@@ -278,7 +278,7 @@ camera_rear@3b { compatible = "ovti,ov5640"; reg = <0x3b>; - enable-gpios = <&tlmm 34 GPIO_ACTIVE_HIGH>; + powerdown-gpios = <&tlmm 34 GPIO_ACTIVE_HIGH>; reset-gpios = <&tlmm 35 GPIO_ACTIVE_LOW>; pinctrl-names = "default"; pinctrl-0 = <&camera_rear_default>;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 346/739 arm64: dts: qcom: msm8998: Drop bus clock reference from MMSS SMMU
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit a3ce236364b82688ca4c7605f63c4efd68e9589c ]
The MMSS SMMU has been abusingly consuming the exposed RPM interconnect clock. Drop it.
--- arch/arm64/boot/dts/qcom/msm8998.dtsi | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
arch/arm64/boot/dts/qcom/msm8998.dtsi +3 -3
@@ -2737,10 +2737,10 @@ mmss_smmu: iommu@cd00000 { clocks = <&mmcc MNOC_AHB_CLK>, <&mmcc BIMC_SMMU_AHB_CLK>, - <&rpmcc RPM_SMD_MMAXI_CLK>, <&mmcc BIMC_SMMU_AXI_CLK>; - clock-names = "iface-mm", "iface-smmu", - "bus-mm", "bus-smmu"; + clock-names = "iface-mm", + "iface-smmu", + "bus-smmu"; #global-interrupts = <0>; interrupts =
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 347/739 arm64: dts: qcom: msm8998: Add missing power domain to MMSS SMMU
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 7f828f3207142351750e9545527341425187de7b ]
The MMSS SMMU has its own power domain. Attach it so that we can drop the "keep it always-on" hack.
--- arch/arm64/boot/dts/qcom/msm8998.dtsi | 2 ++ 1 file changed, 2 insertions(+)
arch/arm64/boot/dts/qcom/msm8998.dtsi +2 -0
@@ -2764,6 +2764,8 @@ mmss_smmu: iommu@cd00000 { <GIC_SPI 261 IRQ_TYPE_LEVEL_HIGH>, <GIC_SPI 262 IRQ_TYPE_LEVEL_HIGH>, <GIC_SPI 272 IRQ_TYPE_LEVEL_HIGH>; + + power-domains = <&mmcc BIMC_SMMU_GDSC>; }; remoteproc_adsp: remoteproc@17300000 {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 348/739 ARM: dts: qcom: sdx65-mtp: Update the pmic used in sdx65
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rohit Agarwal <[email protected]>
[ Upstream commit f636d6c356b339b0d29eed025f8bf9efcb6eb274 ]
Update the pmic used in sdx65 platform to pm7250b.
--- arch/arm/boot/dts/qcom/qcom-sdx65-mtp.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/qcom/qcom-sdx65-mtp.dts +1 -1
@@ -7,7 +7,7 @@ #include "qcom-sdx65.dtsi" #include <dt-bindings/regulator/qcom,rpmh-regulator.h> #include <arm64/qcom/pmk8350.dtsi> -#include <arm64/qcom/pm8150b.dtsi> +#include <arm64/qcom/pm7250b.dtsi> #include "qcom-pmx65.dtsi" / {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 349/739 arm64: dts: qcom: msm8996: Fix dsi1 interrupts
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: David Wronek <[email protected]>
[ Upstream commit bd3b4ac11845b428996cfd2c7b8302ba6a07340d ]
Fix IRQ flags mismatch which was keeping dsi1 from probing by changing interrupts = <4> to interrupts = <5>.
--- arch/arm64/boot/dts/qcom/msm8996.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/msm8996.dtsi +1 -1
@@ -1075,7 +1075,7 @@ mdss_dsi1: dsi@996000 { reg-names = "dsi_ctrl"; interrupt-parent = <&mdss>; - interrupts = <4>; + interrupts = <5>; clocks = <&mmcc MDSS_MDP_CLK>, <&mmcc MDSS_BYTE1_CLK>,
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 350/739 arm64: dts: qcom: sc8280xp-x13s: Unreserve NC pins
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konrad Dybcio <[email protected]>
[ Upstream commit 7868ed0144b33903e16a50485775f669c109e41a ]
Pins 83-86 and 158-160 are NC, so there's no point in keeping them reserved. Take care of that.
--- arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts +1 -1
@@ -1246,7 +1246,7 @@ hastings_reg_en: hastings-reg-en-state { }; &tlmm { - gpio-reserved-ranges = <70 2>, <74 6>, <83 4>, <125 2>, <128 2>, <154 7>; + gpio-reserved-ranges = <70 2>, <74 6>, <125 2>, <128 2>, <154 4>; bt_default: bt-default-state { hstp-bt-en-pins {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 351/739 drm/msm/a690: Switch to a660_gmu.bin
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rob Clark <[email protected]>
[ Upstream commit 18ff50e582a08eb365729b7c5507a86c41f2edf8 ]
There isn't actually a a690_gmu.bin. But it appears that the normal a660_gmu.bin works fine. Normally all the devices within a sub- generation (or "family") will use the same fw, and a690 is in the a660 family.
Patchwork: https://patchwork.freedesktop.org/patch/552406/
--- drivers/gpu/drm/msm/adreno/adreno_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/msm/adreno/adreno_device.c +1 -1
@@ -371,7 +371,7 @@ static const struct adreno_info gpulist[] = { .rev = ADRENO_REV(6, 9, 0, ANY_ID), .fw = { [ADRENO_FW_SQE] = "a660_sqe.fw", - [ADRENO_FW_GMU] = "a690_gmu.bin", + [ADRENO_FW_GMU] = "a660_gmu.bin", }, .gmem = SZ_4M, .inactive_period = DRM_MSM_INACTIVE_PERIOD,
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 352/739 bus: ti-sysc: Fix cast to enum warning
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Tony Lindgren <[email protected]>
[ Upstream commit de44bf2f7683347f75690ef6cf61a1d5ba8f0891 ]
Fix warning for "cast to smaller integer type 'enum sysc_soc' from 'const void *'".
--- drivers/bus/ti-sysc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/bus/ti-sysc.c +1 -1
@@ -3106,7 +3106,7 @@ static int sysc_init_static_data(struct sysc *ddata) match =soc_device_match (sysc_soc_match);if (match && match->data) - sysc_soc->soc = (enum sysc_soc )match->data; + sysc_soc->soc = (enum sysc_soc )(uintptr_t )match->data;/* * Check and warn about possible old incomplete dtb. We now want to see
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 353/739 block: uapi: Fix compilation errors using ioprio.h with C++
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Damien Le Moal <[email protected]>
[ Upstream commit c7b4b23b36edf32239e7fc3b922797ff1d32b072 ]
The use of the "class" argument name in the ioprio_value() inline function in include/uapi/linux/ioprio.h confuses C++ compilers resulting in compilation errors such as:
/usr/include/linux/ioprio.h:110:43: error: expected primary-expression before ‘int’
110 | static __always_inline __u16 ioprio_value(int class, int level, int hint)
| ^~~
for user C++ programs including linux/ioprio.h.
Avoid these errors by renaming the arguments of the ioprio_value() function to prioclass, priolevel and priohint. For consistency, the arguments of the IOPRIO_PRIO_VALUE() and IOPRIO_PRIO_VALUE_HINT() macros are also renamed in the same manner.
--- include/uapi/linux/ioprio.h | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-)
include/uapi/linux/ioprio.h +11 -10
@@ -107,20 +107,21 @@ enum {/* * Return an I/O priority value based on a class, a level and a hint. */ -static __always_inline __u16 ioprio_value(int class, int level, int hint) +static __always_inline __u16 ioprio_value(int prioclass, int priolevel, +int priohint) { -if (IOPRIO_BAD_VALUE (class,IOPRIO_NR_CLASSES ) || -IOPRIO_BAD_VALUE (level,IOPRIO_NR_LEVELS ) || -IOPRIO_BAD_VALUE (hint,IOPRIO_NR_HINTS )) +if (IOPRIO_BAD_VALUE (prioclass,IOPRIO_NR_CLASSES ) || +IOPRIO_BAD_VALUE (priolevel,IOPRIO_NR_LEVELS ) || +IOPRIO_BAD_VALUE (priohint,IOPRIO_NR_HINTS ))return IOPRIO_CLASS_INVALID <<IOPRIO_CLASS_SHIFT ; -return (class <<IOPRIO_CLASS_SHIFT ) | - (hint <<IOPRIO_HINT_SHIFT ) | level; +return (prioclass <<IOPRIO_CLASS_SHIFT ) | + (priohint <<IOPRIO_HINT_SHIFT ) | priolevel; } -#define IOPRIO_PRIO_VALUE (class, level) \ - ioprio_value(class, level, IOPRIO_HINT_NONE) -#define IOPRIO_PRIO_VALUE_HINT (class, level, hint) \ - ioprio_value(class, level, hint) +#define IOPRIO_PRIO_VALUE (prioclass, priolevel) \ + ioprio_value(prioclass, priolevel, IOPRIO_HINT_NONE) +#define IOPRIO_PRIO_VALUE_HINT (prioclass, priolevel, priohint) \ + ioprio_value(prioclass, priolevel, priohint)#endif /* _UAPI_LINUX_IOPRIO_H */
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 354/739 md/raid5-cache: fix a deadlock in r5l_exit_log()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yu Kuai <[email protected]>
[ Upstream commit a705b11b358dee677aad80630e7608b2d5f56691 ]
Commit b13015af94cf ("md/raid5-cache: Clear conf->log after finishing work") introduce a new problem:
// caller hold reconfig_mutexr5l_exit_log
flush_work(&log->disable_writeback_work)
r5c_disable_writeback_async wait_event /* * conf->log is not NULL, and mddev_trylock() * will fail, wait_event() can never pass. */
conf->log = NULL
Fix this problem by setting 'config->log' to NULL before wake_up() as it used to be, so that wait_event() from r5c_disable_writeback_async() can exist. In the meantime, move forward md_unregister_thread() so that null-ptr-deref this commit fixed can still be fixed.
--- drivers/md/raid5-cache.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-)
drivers/md/raid5-cache.c +6 -3
@@ -3168,12 +3168,15 @@ void r5l_exit_log(struct r5conf *conf) {struct r5l_log *log = conf->log; -/* Ensure disable_writeback_work wakes up and exits */ -wake_up (&conf->mddev->sb_wait); -flush_work (&log->disable_writeback_work);md_unregister_thread (&log->reclaim_thread); +/* +* 'reconfig_mutex' is held by caller, set 'confg->log' to NULL to +* ensure disable_writeback_work wakes up and exits. +*/ conf->log =NULL ; +wake_up (&conf->mddev->sb_wait); +flush_work (&log->disable_writeback_work);mempool_exit (&log->meta_pool);bioset_exit (&log->bs);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 355/739 md/raid5-cache: fix null-ptr-deref for r5l_flush_stripe_to_raid()
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yu Kuai <[email protected]>
[ Upstream commit 0d0bd28c500173bfca78aa840f8f36d261ef1765 ]
r5l_flush_stripe_to_raid() will check if the list 'flushing_ios' is empty, and then submit 'flush_bio', however, r5l_log_flush_endio() is clearing the list first and then clear the bio, which will cause null-ptr-deref:
T1: submit flush io
raid5d
handle_active_stripes
r5l_flush_stripe_to_raid
// list is empty
// add 'io_end_ios' to the list
bio_init
submit_bio
// io1
T2: io1 is doner5l_log_flush_endio
list_splice_tail_init
// clear the list
T3: submit new flush io ... r5l_flush_stripe_to_raid // list is empty // add 'io_end_ios' to the list bio_init bio_uninit // clear bio->bi_blkg submit_bio // null-ptr-deref
Fix this problem by clearing bio before clearing the list in r5l_log_flush_endio().
--- drivers/md/raid5-cache.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/md/raid5-cache.c +1 -2
@@ -1260,14 +1260,13 @@ static void r5l_log_flush_endio(struct bio *bio)if (bio->bi_status)md_error (log->rdev->mddev, log->rdev); +bio_uninit (bio);spin_lock_irqsave (&log->io_list_lock, flags);list_for_each_entry (io, &log->flushing_ios, log_sibling)r5l_io_run_stripes (io);list_splice_tail_init (&log->flushing_ios, &log->finished_ios);spin_unlock_irqrestore (&log->io_list_lock, flags); - -bio_uninit (bio); }/*
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 356/739 firmware: cs_dsp: Fix new control name check
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Vlad Karpovich <[email protected]>
[ Upstream commit 7ac1102b227b36550452b663fd39ab1c09378a95 ]
Before adding a new FW control, its name is checked against existing controls list. But the string length in strncmp used to compare controls names is taken from the list, so if beginnings of the controls are matching, then the new control is not created. For example, if CAL_R control already exists, CAL_R_SELECTED is not created.
The fix is to compare string lengths as well.
--- drivers/firmware/cirrus/cs_dsp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/firmware/cirrus/cs_dsp.c +2 -1
@@ -978,7 +978,8 @@ static int cs_dsp_create_control(struct cs_dsp *dsp, ctl->alg_region.alg == alg_region->alg && ctl->alg_region.type == alg_region->type) {if ((!subname && !ctl->subname) || - (subname && !strncmp (ctl->subname, subname, ctl->subname_len))) { + (subname && (ctl->subname_len == subname_len) && + !strncmp (ctl->subname, subname, ctl->subname_len))) {if (!ctl->enabled) ctl->enabled =1 ;return 0 ;
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 357/739 blk-cgroup: Fix NULL deref caused by blkg_policy_data being installed before init
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Tejun Heo <[email protected]>
[ Upstream commit ec14a87ee1999b19d8b7ed0fa95fea80644624ae ]
blk-iocost sometimes causes the following crash:
BUG: kernel NULL pointer dereference, address: 00000000000000e0 ... RIP: 0010:_raw_spin_lock+0x17/0x30 Code: be 01 02 00 00 e8 79 38 39 ff 31 d2 89 d0 5d c3 0f 1f 00 0f 1f 44 00 00 55 48 89 e5 65 ff 05 48 d0 34 7e b9 01 00 00 00 31 c0 <f0> 0f b1 0f 75 02 5d c3 89 c6 e8 ea 04 00 00 5d c3 0f 1f 84 00 00 RSP: 0018:ffffc900023b3d40 EFLAGS: 00010046 RAX: 0000000000000000 RBX: 00000000000000e0 RCX: 0000000000000001 RDX: ffffc900023b3d20 RSI: ffffc900023b3cf0 RDI: 00000000000000e0 RBP: ffffc900023b3d40 R08: ffffc900023b3c10 R09: 0000000000000003 R10: 0000000000000064 R11: 000000000000000a R12: ffff888102337000 R13: fffffffffffffff2 R14: ffff88810af408c8 R15: ffff8881070c3600 FS: 00007faaaf364fc0(0000) GS:ffff88842fdc0000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00000000000000e0 CR3: 00000001097b1000 CR4: 0000000000350ea0 Call Trace: <TASK> ioc_weight_write+0x13d/0x410 cgroup_file_write+0x7a/0x130 kernfs_fop_write_iter+0xf5/0x170 vfs_write+0x298/0x370 ksys_write+0x5f/0xb0 __x64_sys_write+0x1b/0x20 do_syscall_64+0x3d/0x80 entry_SYSCALL_64_after_hwframe+0x46/0xb0
This happens because iocg->ioc is NULL. The field is initialized by ioc_pd_init() and never cleared. The NULL deref is caused by blkcg_activate_policy() installing blkg_policy_data before initializing it.
blkcg_activate_policy() was doing the following:
1. Allocate pd's for all existing blkg's and install them in blkg->pd[].
2. Initialize all pd's.
3. Online all pd's.
blkcg_activate_policy() only grabs the queue_lock and may release and re-acquire the lock as allocation may need to sleep. ioc_weight_write() grabs blkcg->lock and iterates all its blkg's. The two can race and if ioc_weight_write() runs during #1 or between #1 and #2, it can encounter a pd which is not initialized yet, leading to crash.
The crash can be reproduced with the following script:
#!/bin/bash
echo +io > /sys/fs/cgroup/cgroup.subtree_control systemd-run --unit touch-sda --scope dd if=/dev/sda of=/dev/null bs=1M count=1 iflag=direct echo 100 > /sys/fs/cgroup/system.slice/io.weight bash -c "echo '8:0 enable=1' > /sys/fs/cgroup/io.cost.qos" & sleep .2 echo 100 > /sys/fs/cgroup/system.slice/io.weight
with the following patch applied:
Quoted 7 lines
block/blk-cgroup.c +0
-0@@ -1553,6 +1553,12 @@ int blkcg_activate_policy(struct gendisk *disk, const struct blkcg_policy *pol) pd->online = false; }
block/blk-cgroup.c int blkcg_activate_policy(struct gendisk *disk, const struct blkcg_policy *pol) · line 1564
Quoted 10 lines
block/blk-cgroup.c +6
-0+if (system_state ==SYSTEM_RUNNING ) { +spin_unlock_irq (&q->queue_lock); +ssleep (1 ); +spin_lock_irq (&q->queue_lock); + } +/* all allocated, init in the same order */ if (pol->pd_init_fn)list_for_each_entry_reverse (blkg, &q->blkg_list, q_node)
I don't see a reason why all pd's should be allocated, initialized and onlined together. The only ordering requirement is that parent blkgs to be initialized and onlined before children, which is guaranteed from the walking order. Let's fix the bug by allocating, initializing and onlining pd for each blkg and holding blkcg->lock over initialization and onlining. This ensures that an installed blkg is always fully initialized and onlined removing the the race window.
--- block/blk-cgroup.c | 32 ++++++++++++++++++-------------- 1 file changed, 18 insertions(+), 14 deletions(-)
block/blk-cgroup.c +18 -14
@@ -1511,7 +1511,7 @@ int blkcg_activate_policy(struct gendisk *disk, const struct blkcg_policy *pol) retry:spin_lock_irq (&q->queue_lock); -/* blkg_list is pushed at the head, reverse walk to allocate parents first */ +/* blkg_list is pushed at the head, reverse walk to initialize parents first */ list_for_each_entry_reverse (blkg, &q->blkg_list, q_node) {struct blkg_policy_data *pd;
@@ -1549,21 +1549,20 @@ int blkcg_activate_policy(struct gendisk *disk, const struct blkcg_policy *pol) goto enomem; } - blkg->pd[pol->plid] = pd; +spin_lock (&blkg->blkcg->lock); + pd->blkg = blkg; pd->plid = pol->plid; - pd->online = false; - } + blkg->pd[pol->plid] = pd; -/* all allocated, init in the same order */ -if (pol->pd_init_fn) -list_for_each_entry_reverse (blkg, &q->blkg_list, q_node) - pol->pd_init_fn (blkg->pd[pol->plid]); +if (pol->pd_init_fn) + pol->pd_init_fn (pd); -list_for_each_entry_reverse (blkg, &q->blkg_list, q_node) {if (pol->pd_online_fn) - pol->pd_online_fn (blkg->pd[pol->plid]); - blkg->pd[pol->plid]->online = true; + pol->pd_online_fn (pd); + pd->online = true; + +spin_unlock (&blkg->blkcg->lock); }__set_bit (pol->plid, q->blkcg_pols);
@@ -1580,14 +1579,19 @@ int blkcg_activate_policy(struct gendisk *disk, const struct blkcg_policy *pol)return ret; enomem: -/* alloc failed, nothing's initialized yet, free everything */ +/* alloc failed, take down everything */ spin_lock_irq (&q->queue_lock);list_for_each_entry (blkg, &q->blkg_list, q_node) {struct blkcg *blkcg = blkg->blkcg; +struct blkg_policy_data *pd;spin_lock (&blkcg->lock); -if (blkg->pd[pol->plid]) { - pol->pd_free_fn (blkg->pd[pol->plid]); + pd = blkg->pd[pol->plid]; +if (pd) { +if (pd->online && pol->pd_offline_fn) + pol->pd_offline_fn (pd); + pd->online = false; + pol->pd_free_fn (pd); blkg->pd[pol->plid] =NULL ; }spin_unlock (&blkcg->lock);
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 358/739 md/raid1: free the r1bio before waiting for blocked rdev
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Xueshi Hu <[email protected]>
[ Upstream commit 992db13a4aee766c8bfbf046ad15c2db5fa7cab8 ]
Raid1 reshape will change mempool and r1conf::raid_disks which are needed to free r1bio. allow_barrier() make a concurrent raid1_reshape() possible. So, free the in-flight r1bio before waiting blocked rdev.
--- drivers/md/raid1.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/md/raid1.c +2 -2
@@ -1373,6 +1373,7 @@ static void raid1_write_request(struct mddev *mddev, struct bio *bio,return ; } + retry_write: r1_bio =alloc_r1bio (mddev, bio); r1_bio->sectors = max_write_sectors;
@@ -1388,7 +1389,6 @@ static void raid1_write_request(struct mddev *mddev, struct bio *bio,*/ disks = conf->raid_disks *2 ; - retry_write: blocked_rdev =NULL ;rcu_read_lock (); max_sectors = r1_bio->sectors;
@@ -1468,7 +1468,7 @@ static void raid1_write_request(struct mddev *mddev, struct bio *bio,for (j =0 ; j < i; j++)if (r1_bio->bios[j])rdev_dec_pending (conf->mirrors[j].rdev, mddev); - r1_bio->state =0 ; +free_r1bio (r1_bio);allow_barrier (conf, bio->bi_iter.bi_sector);if (bio->bi_opf &REQ_NOWAIT ) {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 359/739 md/raid1: hold the barrier until handle_read_error() finishes
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Xueshi Hu <[email protected]>
[ Upstream commit c069da449a13669ffa754fd971747e7e17e7d691 ]
handle_read_error() will call allow_barrier() to match the former barrier raising. However, it should put the allow_barrier() at the end to avoid a concurrent raid reshape.
--- drivers/md/raid1.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/md/raid1.c +3 -1
@@ -2498,6 +2498,7 @@ static void handle_read_error(struct r1conf *conf, struct r1bio *r1_bio)struct mddev *mddev = conf->mddev;struct bio *bio;struct md_rdev *rdev; +sector_t sector;clear_bit (R1BIO_ReadError, &r1_bio->state);/* we got a read error. Maybe the drive is bad. Maybe just
@@ -2527,12 +2528,13 @@ static void handle_read_error(struct r1conf *conf, struct r1bio *r1_bio) }rdev_dec_pending (rdev, conf->mddev); -allow_barrier (conf, r1_bio->sector); + sector = r1_bio->sector; bio = r1_bio->master_bio;/* Reuse the old r1_bio so that the IO_BLOCKED settings are preserved */ r1_bio->state =0 ;raid1_read_request (mddev, bio, r1_bio->sectors, r1_bio); +allow_barrier (conf, sector); }static void raid1d (struct md_thread *thread)
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 360/739 md/raid0: Factor out helper for mapping and submitting a bio
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jan Kara <[email protected]>
[ Upstream commit af50e20afb401cc203bd2a9ff62ece0ae4976103 ]
Factor out helper function for mapping and submitting a bio out of raid0_make_request(). We will use it later for submitting both parts of a split bio.
Stable-dep-of: 319ff40a5427 ("md/raid0: Fix performance regression for large sequential writes")
--- drivers/md/raid0.c | 79 +++++++++++++++++++++++----------------------- 1 file changed, 40 insertions(+), 39 deletions(-)
drivers/md/raid0.c +40 -39
@@ -557,54 +557,21 @@ static void raid0_handle_discard(struct mddev *mddev, struct bio *bio)bio_endio (bio); } -static bool raid0_make_request (struct mddev *mddev,struct bio *bio) +static void raid0_map_submit_bio (struct mddev *mddev,struct bio *bio) {struct r0conf *conf = mddev->private;struct strip_zone *zone;struct md_rdev *tmp_dev; -sector_t bio_sector; -sector_t sector; -sector_t orig_sector; -unsigned chunk_sects; -unsigned sectors; - -if (unlikely (bio->bi_opf &REQ_PREFLUSH ) - &&md_flush_request (mddev, bio)) -return true; - -if (unlikely ((bio_op (bio) ==REQ_OP_DISCARD ))) { -raid0_handle_discard (mddev, bio); -return true; - } - - bio_sector = bio->bi_iter.bi_sector; - sector = bio_sector; - chunk_sects = mddev->chunk_sectors; - - sectors = chunk_sects - - (likely (is_power_of_2 (chunk_sects)) - ? (sector & (chunk_sects-1 )) - :sector_div (sector, chunk_sects)); - -/* Restore due to sector_div */ - sector = bio_sector; - -if (sectors <bio_sectors (bio)) { -struct bio *split =bio_split (bio, sectors,GFP_NOIO , - &mddev->bio_set); -bio_chain (split, bio); -submit_bio_noacct (bio); - bio = split; - } +sector_t bio_sector = bio->bi_iter.bi_sector; +sector_t sector = bio_sector;if (bio->bi_pool != &mddev->bio_set)md_account_bio (mddev, &bio); - orig_sector = sector; zone =find_zone (mddev->private, §or);switch (conf->layout) {case RAID0_ORIG_LAYOUT : - tmp_dev =map_sector (mddev, zone, orig_sector, §or); + tmp_dev =map_sector (mddev, zone, bio_sector, §or);break ;case RAID0_ALT_MULTIZONE_LAYOUT : tmp_dev =map_sector (mddev, zone, sector, §or);
@@ -612,13 +579,13 @@ static bool raid0_make_request(struct mddev *mddev, struct bio *bio)default :WARN (1 ,"md/raid0:%s: Invalid layout\n" ,mdname (mddev));bio_io_error (bio); -return true; +return ; }if (unlikely (is_rdev_broken (tmp_dev))) {bio_io_error (bio);md_error (mddev, tmp_dev); -return true; +return ; }bio_set_dev (bio, tmp_dev->bdev);
@@ -630,6 +597,40 @@ static bool raid0_make_request(struct mddev *mddev, struct bio *bio) bio_sector);mddev_check_write_zeroes (mddev, bio);submit_bio_noacct (bio); +} + +static bool raid0_make_request (struct mddev *mddev,struct bio *bio) +{ +sector_t sector; +unsigned chunk_sects; +unsigned sectors; + +if (unlikely (bio->bi_opf &REQ_PREFLUSH ) + &&md_flush_request (mddev, bio)) +return true; + +if (unlikely ((bio_op (bio) ==REQ_OP_DISCARD ))) { +raid0_handle_discard (mddev, bio); +return true; + } + + sector = bio->bi_iter.bi_sector; + chunk_sects = mddev->chunk_sectors; + + sectors = chunk_sects - + (likely (is_power_of_2 (chunk_sects)) + ? (sector & (chunk_sects-1 )) + :sector_div (sector, chunk_sects)); + +if (sectors <bio_sectors (bio)) { +struct bio *split =bio_split (bio, sectors,GFP_NOIO , + &mddev->bio_set); +bio_chain (split, bio); +submit_bio_noacct (bio); + bio = split; + } + +raid0_map_submit_bio (mddev, bio);return true; }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 361/739 md/raid0: Fix performance regression for large sequential writes
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jan Kara <[email protected]>
[ Upstream commit 319ff40a542736d67e5bce18635de35d0e7a0bff ]
Commit f00d7c85be9e ("md/raid0: fix up bio splitting.") among other things changed how bio that needs to be split is submitted. Before this commit, we have split the bio, mapped and submitted each part. After this commit, we map only the first part of the split bio and submit the second part unmapped. Due to bio sorting in __submit_bio_noacct() this results in the following request ordering:
9,0 18 1181 0.525037895 15995 Q WS 1479315464 + 63392
Split off chunk-sized (1024 sectors) request:
9,0 18 1182 0.629019647 15995 X WS 1479315464 / 1479316488
Request is unaligned to the chunk so it's split in raid0_make_request(). This is the first part mapped and punted to bio_list:
8,0 18 7053 0.629020455 15995 A WS 739921928 + 1016 <- (9,0) 1479315464
Now raid0_make_request() returns, second part is postponed on bio_list. __submit_bio_noacct() resorts the bio_list, mapped request is submitted to the underlying device:
8,0 18 7054 0.629022782 15995 G WS 739921928 + 1016
Now we take another request from the bio_list which is the remainder of the original huge request. Split off another chunk-sized bit from it and the situation repeats:
9,0 18 1183 0.629024499 15995 X WS 1479316488 / 1479317512 8,16 18 6998 0.629025110 15995 A WS 739921928 + 1016 <- (9,0) 1479316488 8,16 18 6999 0.629026728 15995 G WS 739921928 + 1016 ... 9,0 18 1184 0.629032940 15995 X WS 1479317512 / 1479318536 [libnetacq-write] 8,0 18 7059 0.629033294 15995 A WS 739922952 + 1016 <- (9,0) 1479317512 8,0 18 7060 0.629033902 15995 G WS 739922952 + 1016
...
This repeats until we consume the whole original huge request. Now we finally get to processing the second parts of the split off requests (in reverse order):
8,16 18 7181 0.629161384 15995 A WS 739952640 + 8 <- (9,0) 1479377920 8,0 18 7239 0.629162140 15995 A WS 739952640 + 8 <- (9,0) 1479376896 8,16 18 7186 0.629163881 15995 A WS 739951616 + 8 <- (9,0) 1479375872 8,0 18 7242 0.629164421 15995 A WS 739951616 + 8 <- (9,0) 1479374848
...
I guess it is obvious that this IO pattern is extremely inefficient way to perform sequential IO. It also makes bio_list to grow to rather long lengths.
Change raid0_make_request() to map both parts of the split bio. Since we know we are provided with at most chunk-sized bios, we will always need to split the incoming bio at most once.
--- drivers/md/raid0.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/md/raid0.c +1 -1
@@ -626,7 +626,7 @@ static bool raid0_make_request(struct mddev *mddev, struct bio *bio)struct bio *split =bio_split (bio, sectors,GFP_NOIO , &mddev->bio_set);bio_chain (split, bio); -submit_bio_noacct (bio); +raid0_map_submit_bio (mddev, bio); bio = split; }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 362/739 md: raid0: account for split bio in iostat accounting
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: David Jeffery <[email protected]>
[ Upstream commit cc22b5407e9ca76adb7efeed843146510b1b72a5 ]
When a bio is split by md raid0, the newly created bio will not be tracked by md for I/O accounting. Only the portion of I/O still assigned to the original bio which was reduced by the split will be accounted for. This results in md iostat data sometimes showing I/O values far below the actual amount of data being sent through md.
md_account_bio() needs to be called for all bio generated by the bio split.
A simple example of the issue was generated using a raid0 device on partitions to the same device. Since all raid0 I/O then goes to one device, it makes it easy to see a gap between the md device and its sd storage. Reading an lvm device on top of the md device, the iostat output (some 0 columns and extra devices removed to make the data more compact) was:
Device tps kB_read/s kB_wrtn/s kB_dscd/s kB_read
md2 0.00 0.00 0.00 0.00 0 sde 0.00 0.00 0.00 0.00 0 md2 1364.00 411496.00 0.00 0.00 411496 sde 1734.00 646144.00 0.00 0.00 646144 md2 1699.00 510680.00 0.00 0.00 510680 sde 2155.00 802784.00 0.00 0.00 802784 md2 803.00 241480.00 0.00 0.00 241480 sde 1016.00 377888.00 0.00 0.00 377888 md2 0.00 0.00 0.00 0.00 0 sde 0.00 0.00 0.00 0.00 0
I/O was generated doing large direct I/O reads (12M) with dd to a linear lvm volume on top of the 4 leg raid0 device.
The md2 reads were showing as roughly 2/3 of the reads to the sde device containing all of md2's raid partitions. The sum of reads to sde was 1826816 kB, which was the expected amount as it was the amount read by dd. With the patch, the total reads from md will match the reads from sde and be consistent with the amount of I/O generated.
--- drivers/md/raid0.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/md/raid0.c +1 -2
@@ -565,8 +565,7 @@ static void raid0_map_submit_bio(struct mddev *mddev, struct bio *bio)sector_t bio_sector = bio->bi_iter.bi_sector;sector_t sector = bio_sector; -if (bio->bi_pool != &mddev->bio_set) -md_account_bio (mddev, &bio); +md_account_bio (mddev, &bio); zone =find_zone (mddev->private, §or);switch (conf->layout) {
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 363/739 ASoC: pxa: merge DAI call back functions into ops
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kuninori Morimoto <[email protected]>
[ Upstream commit 98e268a7205706f809658345399eead7c7d1b8bb ]
ALSA SoC merges DAI call backs into .ops.
This patch merge these into one.
--- sound/soc/pxa/mmp-sspa.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/soc/pxa/mmp-sspa.c +1 -1
@@ -340,6 +340,7 @@ static int mmp_sspa_probe(struct snd_soc_dai *dai) SNDRV_PCM_FMTBIT_S32_LE) static const struct snd_soc_dai_ops mmp_sspa_dai_ops = { + .probe = mmp_sspa_probe, .startup = mmp_sspa_startup, .shutdown = mmp_sspa_shutdown, .trigger = mmp_sspa_trigger,
@@ -350,7 +351,6 @@ static const struct snd_soc_dai_ops mmp_sspa_dai_ops = { };static struct snd_soc_dai_driver mmp_sspa_dai = { - .probe = mmp_sspa_probe, .playback = { .channels_min =1 , .channels_max =128 ,
Signature · 1 line
2.40.1
Re: [PATCH 6.5 363/739] ASoC: pxa: merge DAI call back functions into ops
Quoted 10 lines · Greg Kroah-Hartman
6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kuninori Morimoto <[email protected]>
[ Upstream commit
98e268a7205706f809658345399eead7c7d1b8bb]ALSA SoC merges DAI call backs into .ops.
This patch merge these into one.
This is obviously not stable material.
Greg Kroah-Hartman
maintainerRe: [PATCH 6.5 363/739] ASoC: pxa: merge DAI call back functions into ops
Quoted 5 lines · Mark Brown
Quoted 4 lines · Greg Kroah-Hartman
6.5-stable review patch. If anyone has any objections, please let me know.
------------------
Quoted 8 lines
Quoted 6 lines
From: Kuninori Morimoto <[email protected]>
[ Upstream commit
98e268a7205706f809658345399eead7c7d1b8bb]ALSA SoC merges DAI call backs into .ops.
This patch merge these into one.This is obviously not stable material.
Odd, Sasha, how did these get picked by your scripts?
I've dropped all 3 now, thanks for noticing them.
greg k-h
Greg Kroah-Hartman
maintainerPATCH 364/739 ASoC: soc-dai.h: merge DAI call back functions into ops
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kuninori Morimoto <[email protected]>
[ Upstream commit 3e8bcec0787d1a73703c915c31cb00a2fd18ccbf ]
snd_soc_dai_driver has .ops for call back functions (A), but it also has other call back functions (B). It is duplicated and confusable.
struct snd_soc_dai_driver {
... ^ int (*probe)(...);
| int (*remove)(...);
(B) int (*compress_new)(...);
| int (*pcm_new)(...);
v ...
(A) const struct snd_soc_dai_ops *ops; ... }
This patch merges (B) into (A).
Stable-dep-of: 5e5f68ca836e ("ASoC: fsl: merge DAI call back functions into ops")
--- include/sound/soc-dai.h | 13 ++++++++ sound/soc/generic/audio-graph-card.c | 2 +- sound/soc/soc-core.c | 25 ++++++++++++++++ sound/soc/soc-dai.c | 44 ++++++++++++++++------------ 4 files changed, 64 insertions(+), 20 deletions(-)
include/sound/soc-dai.h +13 -0
@@ -272,6 +272,15 @@ int snd_soc_dai_compr_get_metadata(struct snd_soc_dai *dai, struct snd_compr_metadata *metadata);struct snd_soc_dai_ops { +/* DAI driver callbacks */ +int (*probe)(struct snd_soc_dai *dai); +int (*remove)(struct snd_soc_dai *dai); +/* compress dai */ +int (*compress_new)(struct snd_soc_pcm_runtime *rtd,int num); +/* Optional Callback used at pcm creation*/ +int (*pcm_new)(struct snd_soc_pcm_runtime *rtd, +struct snd_soc_dai *dai); +/* * DAI clocking configuration, all optional. * Called by soc_card drivers, normally in their hw_params.
@@ -353,6 +362,10 @@ struct snd_soc_dai_ops {u64 *auto_selectable_formats;int num_auto_selectable_formats; +/* probe ordering - for components with runtime dependencies */ +int probe_order; +int remove_order; +/* bit field */ unsigned int no_capture_mute:1; };
sound/soc/generic/audio-graph-card.c +1 -1
@@ -60,7 +60,7 @@ static bool soc_component_is_pcm(struct snd_soc_dai_link_component *dlc)struct snd_soc_dai *dai =snd_soc_find_dai_with_mutex (dlc);if (dai && (dai->component->driver->pcm_construct || - dai->driver->pcm_new)) + (dai->driver->ops && dai->driver->ops->pcm_new)))return true;return false;
sound/soc/soc-core.c +25 -0
@@ -2422,6 +2422,7 @@ struct snd_soc_dai *snd_soc_register_dai(struct snd_soc_component *component, {struct device *dev = component->dev;struct snd_soc_dai *dai; +struct snd_soc_dai_ops *ops;/* REMOVE ME */ lockdep_assert_held (&client_mutex);
@@ -2450,6 +2451,30 @@ struct snd_soc_dai *snd_soc_register_dai(struct snd_soc_component *component,if (!dai->name)return NULL ; +/* REMOVE ME */ +if (dai_drv->probe || + dai_drv->remove || + dai_drv->compress_new || + dai_drv->pcm_new || + dai_drv->probe_order || + dai_drv->remove_order) { + + ops =devm_kzalloc (dev,sizeof (struct snd_soc_dai_ops ),GFP_KERNEL ); +if (!ops) +return NULL ; +if (dai_drv->ops) +memcpy (ops, dai_drv->ops,sizeof (struct snd_soc_dai_ops )); + + ops->probe = dai_drv->probe; + ops->remove = dai_drv->remove; + ops->compress_new = dai_drv->compress_new; + ops->pcm_new = dai_drv->pcm_new; + ops->probe_order = dai_drv->probe_order; + ops->remove_order = dai_drv->remove_order; + + dai_drv->ops = ops; + } + dai->component = component; dai->dev = dev; dai->driver = dai_drv;
sound/soc/soc-dai.c +25 -19
76 lines not on this page · raw message
Signature · 1 line
2.40.1
Re: [PATCH 6.5 364/739] ASoC: soc-dai.h: merge DAI call back functions into ops
Quoted 8 lines · Greg Kroah-Hartman
6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kuninori Morimoto <[email protected]>
[ Upstream commit
3e8bcec0787d1a73703c915c31cb00a2fd18ccbf]
Quoted 8 lines
snd_soc_dai_driverhas .ops for call back functions (A), but it also has other call back functions (B). It is duplicated and confusable.Signed-off-by Mark Brown <[email protected]>Stable-dep-of:
5e5f68ca836e("ASoC: fsl: merge DAI call back functions into ops")Signed-off-by Sasha Levin <[email protected]>---
This is a code refactoring. It is obviously not suitable for stable, it's not even a warning fix or anything - just a refactoring. You've marked it as a dependency of another patch which is doing the refactoring in a specific driver which obviously shouldn't be being backported either.
To repeat what I said the other day in response to the other wildly inappropriate backports (one was an entirely new driver...) I thought that there was supposed to be some manual review of the patches being included in stable prior to them being sent out. How on earth are things like this getting as far as being even proposed for stable?
Re: [PATCH 6.5 364/739] ASoC: soc-dai.h: merge DAI call back functions into ops
Hi
Quoted 1 line
Quoted 1 line
[ Upstream commit
3e8bcec0787d1a73703c915c31cb00a2fd18ccbf]
(snip)
Quoted 11 lines
This is a code refactoring. It is obviously not suitable for stable, it's not even a warning fix or anything - just a refactoring. You've marked it as a dependency of another patch which is doing the refactoring in a specific driver which obviously shouldn't be being backported either.
To repeat what I said the other day in response to the other wildly inappropriate backports (one was an entirely new driver...) I thought that there was supposed to be some manual review of the patches being included in stable prior to them being sent out. How on earth are things like this getting as far as being even proposed for stable?
I have noticed about this, but my guess was that because this each patch modifies driver file with wide range. Thus, other main/important patch can't be backported without this patch (to fsl/pxa) ?
(I'm not 100% understanding stable rules...)
Fortunatry, this patch-set adds (1) add new style, (2) switch to new style
(3) remove old style. We can keep compatibility if (3) was not added.
Best regards
---
Kuninori Morimoto
Re: [PATCH 6.5 364/739] ASoC: soc-dai.h: merge DAI call back functions into ops
Quoted 4 lines · Kuninori Morimoto
I have noticed about this, but my guess was that because this each patch modifies driver file with wide range. Thus, other main/important patch can't be backported without this patch (to fsl/pxa) ?
(I'm not 100% understanding stable rules...)
If it were that I'd have expected it to have a Stable-dep-of tag in it saying what was pulling it back, but even there it would be more sensible to do a manual backport than pull in a refactoring.
Greg Kroah-Hartman
maintainerPATCH 365/739 ASoC: fsl: merge DAI call back functions into ops
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kuninori Morimoto <[email protected]>
[ Upstream commit 5e5f68ca836e740c1d788f04efa84b37ed185606 ]
ALSA SoC merges DAI call backs into .ops.
This patch merge these into one.
--- sound/soc/fsl/fsl_asrc.c | 16 ++++++++-------- sound/soc/fsl/fsl_aud2htx.c | 10 +++++----- sound/soc/fsl/fsl_easrc.c | 16 ++++++++-------- sound/soc/fsl/fsl_esai.c | 20 ++++++++++---------- sound/soc/fsl/fsl_micfil.c | 14 +++++++------- sound/soc/fsl/fsl_sai.c | 24 ++++++++++++------------ sound/soc/fsl/fsl_spdif.c | 17 ++++++++--------- sound/soc/fsl/fsl_ssi.c | 3 +-- sound/soc/fsl/fsl_xcvr.c | 16 ++++++++-------- 9 files changed, 67 insertions(+), 69 deletions(-)
sound/soc/fsl/fsl_asrc.c +8 -8
@@ -780,13 +780,6 @@ static int fsl_asrc_dai_trigger(struct snd_pcm_substream *substream, int cmd,return 0 ; } -static const struct snd_soc_dai_ops fsl_asrc_dai_ops = { - .startup = fsl_asrc_dai_startup, - .hw_params = fsl_asrc_dai_hw_params, - .hw_free = fsl_asrc_dai_hw_free, - .trigger = fsl_asrc_dai_trigger, -}; -static int fsl_asrc_dai_probe (struct snd_soc_dai *dai) {struct fsl_asrc *asrc =snd_soc_dai_get_drvdata (dai);
@@ -797,12 +790,19 @@ static int fsl_asrc_dai_probe(struct snd_soc_dai *dai)return 0 ; } +static const struct snd_soc_dai_ops fsl_asrc_dai_ops = { + .probe = fsl_asrc_dai_probe, + .startup = fsl_asrc_dai_startup, + .hw_params = fsl_asrc_dai_hw_params, + .hw_free = fsl_asrc_dai_hw_free, + .trigger = fsl_asrc_dai_trigger, +}; +#define FSL_ASRC_FORMATS (SNDRV_PCM_FMTBIT_S24_LE | \ SNDRV_PCM_FMTBIT_S16_LE | \ SNDRV_PCM_FMTBIT_S24_3LE)static struct snd_soc_dai_driver fsl_asrc_dai = { - .probe = fsl_asrc_dai_probe, .playback = { .stream_name ="ASRC-Playback" , .channels_min =1 ,
sound/soc/fsl/fsl_aud2htx.c +5 -5
@@ -49,10 +49,6 @@ static int fsl_aud2htx_trigger(struct snd_pcm_substream *substream, int cmd,return 0 ; } -static const struct snd_soc_dai_ops fsl_aud2htx_dai_ops = { - .trigger = fsl_aud2htx_trigger, -}; -static int fsl_aud2htx_dai_probe (struct snd_soc_dai *cpu_dai) {struct fsl_aud2htx *aud2htx =dev_get_drvdata (cpu_dai->dev);
@@ -84,8 +80,12 @@ static int fsl_aud2htx_dai_probe(struct snd_soc_dai *cpu_dai)return 0 ; } +static const struct snd_soc_dai_ops fsl_aud2htx_dai_ops = { + .probe = fsl_aud2htx_dai_probe, + .trigger = fsl_aud2htx_trigger, +}; +static struct snd_soc_dai_driver fsl_aud2htx_dai = { - .probe = fsl_aud2htx_dai_probe, .playback = { .stream_name ="CPU-Playback" , .channels_min =1 ,
sound/soc/fsl/fsl_easrc.c +8 -8
@@ -1531,13 +1531,6 @@ static int fsl_easrc_hw_free(struct snd_pcm_substream *substream,return 0 ; } -static const struct snd_soc_dai_ops fsl_easrc_dai_ops = { - .startup = fsl_easrc_startup, - .trigger = fsl_easrc_trigger, - .hw_params = fsl_easrc_hw_params, - .hw_free = fsl_easrc_hw_free, -}; -static int fsl_easrc_dai_probe (struct snd_soc_dai *cpu_dai) {struct fsl_asrc *easrc =dev_get_drvdata (cpu_dai->dev);
@@ -1548,8 +1541,15 @@ static int fsl_easrc_dai_probe(struct snd_soc_dai *cpu_dai)return 0 ; } +static const struct snd_soc_dai_ops fsl_easrc_dai_ops = { + .probe = fsl_easrc_dai_probe, + .startup = fsl_easrc_startup, + .trigger = fsl_easrc_trigger, + .hw_params = fsl_easrc_hw_params, + .hw_free = fsl_easrc_hw_free, +}; +static struct snd_soc_dai_driver fsl_easrc_dai = { - .probe = fsl_easrc_dai_probe, .playback = { .stream_name ="ASRC-Playback" , .channels_min =1 ,
sound/soc/fsl/fsl_esai.c +10 -10
@@ -785,15 +785,6 @@ static int fsl_esai_trigger(struct snd_pcm_substream *substream, int cmd,return 0 ; } -static const struct snd_soc_dai_ops fsl_esai_dai_ops = { - .startup = fsl_esai_startup, - .trigger = fsl_esai_trigger, - .hw_params = fsl_esai_hw_params, - .set_sysclk = fsl_esai_set_dai_sysclk, - .set_fmt = fsl_esai_set_dai_fmt, - .set_tdm_slot = fsl_esai_set_dai_tdm_slot, -}; -static int fsl_esai_dai_probe (struct snd_soc_dai *dai) {struct fsl_esai *esai_priv =snd_soc_dai_get_drvdata (dai);
@@ -804,8 +795,17 @@ static int fsl_esai_dai_probe(struct snd_soc_dai *dai)return 0 ; } +static const struct snd_soc_dai_ops fsl_esai_dai_ops = { + .probe = fsl_esai_dai_probe, + .startup = fsl_esai_startup, + .trigger = fsl_esai_trigger, + .hw_params = fsl_esai_hw_params, + .set_sysclk = fsl_esai_set_dai_sysclk, + .set_fmt = fsl_esai_set_dai_fmt, + .set_tdm_slot = fsl_esai_set_dai_tdm_slot, +}; +static struct snd_soc_dai_driver fsl_esai_dai = { - .probe = fsl_esai_dai_probe, .playback = { .stream_name ="CPU-Playback" , .channels_min =1 ,
sound/soc/fsl/fsl_micfil.c +7 -7
@@ -717,12 +717,6 @@ static int fsl_micfil_hw_params(struct snd_pcm_substream *substream,return 0 ; } -static const struct snd_soc_dai_ops fsl_micfil_dai_ops = { - .startup = fsl_micfil_startup, - .trigger = fsl_micfil_trigger, - .hw_params = fsl_micfil_hw_params, -}; -static int fsl_micfil_dai_probe (struct snd_soc_dai *cpu_dai) {struct fsl_micfil *micfil =dev_get_drvdata (cpu_dai->dev);
@@ -760,8 +754,14 @@ static int fsl_micfil_dai_probe(struct snd_soc_dai *cpu_dai)return 0 ; } +static const struct snd_soc_dai_ops fsl_micfil_dai_ops = { + .probe = fsl_micfil_dai_probe, + .startup = fsl_micfil_startup, + .trigger = fsl_micfil_trigger, + .hw_params = fsl_micfil_hw_params, +}; +static struct snd_soc_dai_driver fsl_micfil_dai = { - .probe = fsl_micfil_dai_probe, .capture = { .stream_name ="CPU-Capture" , .channels_min =1 ,
sound/soc/fsl/fsl_sai.c +12 -12
@@ -849,17 +849,6 @@ static int fsl_sai_startup(struct snd_pcm_substream *substream,return ret; } -static const struct snd_soc_dai_ops fsl_sai_pcm_dai_ops = { - .set_bclk_ratio = fsl_sai_set_dai_bclk_ratio, - .set_sysclk = fsl_sai_set_dai_sysclk, - .set_fmt = fsl_sai_set_dai_fmt, - .set_tdm_slot = fsl_sai_set_dai_tdm_slot, - .hw_params = fsl_sai_hw_params, - .hw_free = fsl_sai_hw_free, - .trigger = fsl_sai_trigger, - .startup = fsl_sai_startup, -}; -static int fsl_sai_dai_probe (struct snd_soc_dai *cpu_dai) {struct fsl_sai *sai =dev_get_drvdata (cpu_dai->dev);
@@ -885,6 +874,18 @@ static int fsl_sai_dai_probe(struct snd_soc_dai *cpu_dai)return 0 ; } +static const struct snd_soc_dai_ops fsl_sai_pcm_dai_ops = { + .probe = fsl_sai_dai_probe, + .set_bclk_ratio = fsl_sai_set_dai_bclk_ratio, + .set_sysclk = fsl_sai_set_dai_sysclk, + .set_fmt = fsl_sai_set_dai_fmt, + .set_tdm_slot = fsl_sai_set_dai_tdm_slot, + .hw_params = fsl_sai_hw_params, + .hw_free = fsl_sai_hw_free, + .trigger = fsl_sai_trigger, + .startup = fsl_sai_startup, +}; +static int fsl_sai_dai_resume (struct snd_soc_component *component) {struct fsl_sai *sai =snd_soc_component_get_drvdata (component);
@@ -903,7 +904,6 @@ static int fsl_sai_dai_resume(struct snd_soc_component *component) }static struct snd_soc_dai_driver fsl_sai_dai_template = { - .probe = fsl_sai_dai_probe, .playback = { .stream_name ="CPU-Playback" , .channels_min =1 ,
sound/soc/fsl/fsl_spdif.c +8 -9
@@ -761,14 +761,6 @@ static int fsl_spdif_trigger(struct snd_pcm_substream *substream,return 0 ; } -static const struct snd_soc_dai_ops fsl_spdif_dai_ops = { - .startup = fsl_spdif_startup, - .hw_params = fsl_spdif_hw_params, - .trigger = fsl_spdif_trigger, - .shutdown = fsl_spdif_shutdown, -}; - -/* * FSL SPDIF IEC958 controller(mixer) functions *
@@ -1279,8 +1271,15 @@ static int fsl_spdif_dai_probe(struct snd_soc_dai *dai)return 0 ; } +static const struct snd_soc_dai_ops fsl_spdif_dai_ops = { + .probe = fsl_spdif_dai_probe, + .startup = fsl_spdif_startup, + .hw_params = fsl_spdif_hw_params, + .trigger = fsl_spdif_trigger, + .shutdown = fsl_spdif_shutdown, +}; +static struct snd_soc_dai_driver fsl_spdif_dai = { - .probe = &fsl_spdif_dai_probe, .playback = { .stream_name ="CPU-Playback" , .channels_min =2 ,
sound/soc/fsl/fsl_ssi.c +1 -2
@@ -1152,6 +1152,7 @@ static int fsl_ssi_dai_probe(struct snd_soc_dai *dai) }static const struct snd_soc_dai_ops fsl_ssi_dai_ops = { + .probe = fsl_ssi_dai_probe, .startup = fsl_ssi_startup, .shutdown = fsl_ssi_shutdown, .hw_params = fsl_ssi_hw_params,
@@ -1162,7 +1163,6 @@ static const struct snd_soc_dai_ops fsl_ssi_dai_ops = { };static struct snd_soc_dai_driver fsl_ssi_dai_template = { - .probe = fsl_ssi_dai_probe, .playback = { .stream_name ="CPU-Playback" , .channels_min =1 ,
@@ -1187,7 +1187,6 @@ static const struct snd_soc_component_driver fsl_ssi_component = {static struct snd_soc_dai_driver fsl_ssi_ac97_dai = { .symmetric_channels =1 , - .probe = fsl_ssi_dai_probe, .playback = { .stream_name ="CPU AC97 Playback" , .channels_min =2 ,
sound/soc/fsl/fsl_xcvr.c +8 -8
@@ -888,13 +888,6 @@ static struct snd_kcontrol_new fsl_xcvr_tx_ctls[] = { }, }; -static const struct snd_soc_dai_ops fsl_xcvr_dai_ops = { - .prepare = fsl_xcvr_prepare, - .startup = fsl_xcvr_startup, - .shutdown = fsl_xcvr_shutdown, - .trigger = fsl_xcvr_trigger, -}; -static int fsl_xcvr_dai_probe (struct snd_soc_dai *dai) {struct fsl_xcvr *xcvr =snd_soc_dai_get_drvdata (dai);
@@ -915,8 +908,15 @@ static int fsl_xcvr_dai_probe(struct snd_soc_dai *dai)return 0 ; } +static const struct snd_soc_dai_ops fsl_xcvr_dai_ops = { + .probe = fsl_xcvr_dai_probe, + .prepare = fsl_xcvr_prepare, + .startup = fsl_xcvr_startup, + .shutdown = fsl_xcvr_shutdown, + .trigger = fsl_xcvr_trigger, +}; +static struct snd_soc_dai_driver fsl_xcvr_dai = { - .probe = fsl_xcvr_dai_probe, .ops = &fsl_xcvr_dai_ops, .playback = { .stream_name ="CPU-Playback" ,
Signature · 1 line
2.40.1
Re: [PATCH 6.5 365/739] ASoC: fsl: merge DAI call back functions into ops
Quoted 10 lines · Greg Kroah-Hartman
6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kuninori Morimoto <[email protected]>
[ Upstream commit
5e5f68ca836e740c1d788f04efa84b37ed185606]ALSA SoC merges DAI call backs into .ops.
This patch merge these into one.
This is obviously not stable material.
Greg Kroah-Hartman
maintainerPATCH 366/739 ASoC: SOF: amd: clear dsp to host interrupt status
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Vijendar Mukunda <[email protected]>
[ Upstream commit 38592ae6dc9f84b7a994c43de2136b8115ca30f6 ]
DSP_SW_INTR_STAT_OFFSET is a common interrupt register which will be accessed by both ACP firmware and driver. This register contains register bits corresponds to host to dsp interrupts and vice versa.
when dsp to host interrupt is reported, only clear dsp to host interrupt bit in DSP_SW_INTR_STAT_OFFSET.
--- sound/soc/sof/amd/acp.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
sound/soc/sof/amd/acp.c +3 -3
@@ -355,9 +355,9 @@ static irqreturn_t acp_irq_handler(int irq, void *dev_id)unsigned int val; val =snd_sof_dsp_read (sdev,ACP_DSP_BAR , base +DSP_SW_INTR_STAT_OFFSET ); -if (val) { - val |=ACP_DSP_TO_HOST_IRQ ; -snd_sof_dsp_write (sdev,ACP_DSP_BAR , base +DSP_SW_INTR_STAT_OFFSET , val); +if (val &ACP_DSP_TO_HOST_IRQ ) { +snd_sof_dsp_write (sdev,ACP_DSP_BAR , base +DSP_SW_INTR_STAT_OFFSET , +ACP_DSP_TO_HOST_IRQ );return IRQ_WAKE_THREAD ; }
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 367/739 of: overlay: Call of_changeset_init() early
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Geert Uytterhoeven <[email protected]>
[ Upstream commit a9515ff4fb142b690a0d2b58782b15903b990dba ]
When of_overlay_fdt_apply() fails, the changeset may be partially applied, and the caller is still expected to call of_overlay_remove() to clean up this partial state.
However, of_overlay_apply() calls of_resolve_phandles() before init_overlay_changeset(). Hence if the overlay fails to apply due to an unresolved symbol, the overlay_changeset.cset.entries list is still uninitialized, and cleanup will crash with a NULL-pointer dereference in overlay_removal_is_ok().
Fix this by moving the call to of_changeset_init() from init_overlay_changeset() to of_overlay_fdt_apply(), where all other early initialization is done.
--- drivers/of/overlay.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/of/overlay.c +1 -2
@@ -752,8 +752,6 @@ static int init_overlay_changeset(struct overlay_changeset *ovcs)if (!of_node_is_root (ovcs->overlay_root))pr_debug ("%s() ovcs->overlay_root is not root\n" , __func__); -of_changeset_init (&ovcs->cset); - cnt =0 ;/* fragment nodes */
@@ -1013,6 +1011,7 @@ int of_overlay_fdt_apply(const void *overlay_fdt, u32 overlay_fdt_size,INIT_LIST_HEAD (&ovcs->ovcs_list);list_add_tail (&ovcs->ovcs_list, &ovcs_list); +of_changeset_init (&ovcs->cset);/* * Must create permanent copy of FDT because of_fdt_unflatten_tree()
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 368/739 of: unittest: Fix overlay type in apply/revert check
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Geert Uytterhoeven <[email protected]>
[ Upstream commit 6becf8f845ae1f0b1cfed395bbeccbd23654162d ]
The removal check in of_unittest_apply_revert_overlay_check() always uses the platform device overlay type, while it should use the actual overlay type, as passed as a parameter to the function.
This has no impact on any current test, as all tests calling of_unittest_apply_revert_overlay_check() use the platform device overlay type.
--- drivers/of/unittest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/of/unittest.c +1 -1
@@ -2182,7 +2182,7 @@ static int __init of_unittest_apply_revert_overlay_check(int overlay_nr,of_unittest_untrack_overlay (save_ovcs_id);/* unittest device must be again in before state */ -if (of_unittest_device_exists (unittest_nr,PDEV_OVERLAY ) != before) { +if (of_unittest_device_exists (unittest_nr, ovtype) != before) { unittest(0, "%s with device @\"%s\" %s\n", overlay_name_from_nr(overlay_nr), unittest_path(unittest_nr, ovtype),
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 369/739 ALSA: ac97: Fix possible error value of *rac97
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Su Hui <[email protected]>
[ Upstream commit 67de40c9df94037769967ba28c7d951afb45b7fb ]
Before committing 79597c8bf64c, *rac97 always be NULL if there is an error. When error happens, make sure *rac97 is NULL is safer.
For examble, in snd_vortex_mixer():
err = snd_ac97_mixer(pbus, &ac97, &vortex->codec); vortex->isquad = ((vortex->codec == NULL) ? 0 : (vortex->codec->ext_id&0x80));
If error happened but vortex->codec isn't NULL, this may cause some problems.
Move the judgement order to be clearer and better.
--- sound/pci/ac97/ac97_codec.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
sound/pci/ac97/ac97_codec.c +2 -3
@@ -2069,10 +2069,9 @@ int snd_ac97_mixer(struct snd_ac97_bus *bus, struct snd_ac97_template *template, .dev_disconnect = snd_ac97_dev_disconnect, }; -if (!rac97) -return -EINVAL ; -if (snd_BUG_ON (!bus || !template)) +if (snd_BUG_ON (!bus || !template || !rac97))return -EINVAL ; + *rac97 =NULL ;if (snd_BUG_ON (template->num >=4 ))return -EINVAL ;if (bus->codec[template->num])
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 370/739 ALSA: usb-audio: Attach legacy rawmidi after probing all UMP EPs
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Takashi Iwai <[email protected]>
[ Upstream commit 5f11dd938fe7657899ca79b2ffc4d708e43f4737 ]
The legacy rawmidi devices are the shadows of the main UMP devices, hence it's better to initialize them after all UMP Endpoints are parsed. Then, at the moment the legacy rawmidi is created, we already know the static flag or the proper EP name string, and we can fill those information at UMP core side instead of fiddling the attributes at a later point.
--- sound/core/ump.c | 2 ++ sound/usb/midi2.c | 15 ++++++++------- 2 files changed, 10 insertions(+), 7 deletions(-)
sound/core/ump.c +2 -0
@@ -1150,6 +1150,8 @@ int snd_ump_attach_legacy_rawmidi(struct snd_ump_endpoint *ump,if (output)snd_rawmidi_set_ops (rmidi,SNDRV_RAWMIDI_STREAM_OUTPUT , &snd_ump_legacy_output_ops); +snprintf (rmidi->name,sizeof (rmidi->name),"%s (MIDI 1.0)" , + ump->info.name); rmidi->info_flags = ump->core.info_flags & ~SNDRV_RAWMIDI_INFO_UMP ; rmidi->ops = &snd_ump_legacy_ops; rmidi->private_data = ump;
sound/usb/midi2.c +8 -7
@@ -990,7 +990,7 @@ static int parse_midi_2_0(struct snd_usb_midi2_interface *umidi) } } -return attach_legacy_rawmidi (umidi); +return 0 ; }/* is the given interface for MIDI 2.0? */
@@ -1059,12 +1059,6 @@ static void set_fallback_rawmidi_names(struct snd_usb_midi2_interface *umidi)usb_string (dev, dev->descriptor.iSerialNumber, ump->info.product_id,sizeof (ump->info.product_id)); -#if IS_ENABLED (CONFIG_SND_UMP_LEGACY_RAWMIDI ) -if (ump->legacy_rmidi && !*ump->legacy_rmidi->name) -snprintf (ump->legacy_rmidi->name, -sizeof (ump->legacy_rmidi->name), -"%s (MIDI 1.0)" , ump->info.name); -#endif } }
@@ -1157,6 +1151,13 @@ int snd_usb_midi_v2_create(struct snd_usb_audio *chip, }set_fallback_rawmidi_names (umidi); + + err =attach_legacy_rawmidi (umidi); +if (err <0 ) { +usb_audio_err (chip,"Failed to create legacy rawmidi\n" ); + goto error; + } +return 0 ; error:
Signature · 1 line
2.40.1
Greg Kroah-Hartman
maintainerPATCH 371/739 ALSA: ump: Fill group names for legacy rawmidi substreams
In reply to Greg Kroah-Hartman6.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Takashi Iwai <[email protected]>
[ Upstream commit 1761f4cc114af531020ea190df6a24dd288a8221 ]
To make it clearer which legacy substream corresponds to which UMP group, fill the subname field of each substream object with the group number and the endpoint name, e.g. "Group 1 (My Device)".
Ideally speaking, we should have some better link information to the derived UMP, but it's another feature extension.
--- sound/core/ump.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+)
sound/core/ump.c +15 -0
@@ -1123,6 +1123,16 @@ static void process_legacy_input(struct snd_ump_endpoint *ump, const u32 *src,spin_unlock_irqrestore (&ump->legacy_locks[dir], flags); } +static void fill_substream_names (struct snd_ump_endpoint *ump, +struct snd_rawmidi *rmidi,int dir) +{ +struct snd_rawmidi_substream *s; + +list_for_each_entry (s, &rmidi->streams[dir].substreams, list) +snprintf (s->name,sizeof (s->name),"Group %d (%s)" , + s->number +1 , ump->info.name); +} +int snd_ump_attach_legacy_rawmidi (struct snd_ump_endpoint *ump,char *id,int device) {
@@ -1156,6 +1166,11 @@ int snd_ump_attach_legacy_rawmidi(struct snd_ump_endpoint *ump, rmidi->ops = &snd_ump_legacy_ops; rmidi->private_data = ump; ump->legacy_rmidi = rmidi; +if (input) +fill_substream_names (ump, rmidi,SNDRV_RAWMIDI_STREAM_INPUT ); +if (output) +fill_substream_names (ump, rmidi,SNDRV_RAWMIDI_STREAM_OUTPUT ); +ump_dbg (ump,"Created a legacy rawmidi #%d (%s)\n" , device, id);return 0 ; }
Signature · 1 line
2.40.1