mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-12 07:37:31 -04:00
Merge edd54a3236 on remote branch
Change-Id: I3b104cb9a2ecab9cdf6a53684f05898ab2060d89
This commit is contained in:
commit
f2c07e3656
491 changed files with 109708 additions and 112123 deletions
2
Makefile
2
Makefile
|
|
@ -1,7 +1,7 @@
|
|||
# SPDX-License-Identifier: GPL-2.0
|
||||
VERSION = 5
|
||||
PATCHLEVEL = 4
|
||||
SUBLEVEL = 259
|
||||
SUBLEVEL = 265
|
||||
EXTRAVERSION =
|
||||
NAME = Kleptomaniac Octopus
|
||||
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
LTS_5.4.259_70db018a109
|
||||
LTS_5.4.265_a34cc1dcf78d
|
||||
|
|
|
|||
165660
android/abi_gki_aarch64.xml
165660
android/abi_gki_aarch64.xml
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
|
@ -381,7 +381,7 @@
|
|||
&mmc2 {
|
||||
status = "okay";
|
||||
vmmc-supply = <&wl12xx_vmmc>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
bus-width = <4>;
|
||||
cap-power-off-card;
|
||||
pinctrl-names = "default";
|
||||
|
|
|
|||
|
|
@ -22,7 +22,6 @@
|
|||
pinctrl-0 = <&emmc_pins>;
|
||||
bus-width = <8>;
|
||||
status = "okay";
|
||||
non-removable;
|
||||
};
|
||||
|
||||
&am33xx_pinmux {
|
||||
|
|
|
|||
|
|
@ -75,6 +75,7 @@
|
|||
bus-width = <4>;
|
||||
non-removable;
|
||||
cap-power-off-card;
|
||||
ti,needs-special-hs-handling;
|
||||
keep-power-in-suspend;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&mmc3_pins &wl18xx_pins>;
|
||||
|
|
|
|||
|
|
@ -389,6 +389,7 @@
|
|||
bus-width = <4>;
|
||||
non-removable;
|
||||
cap-power-off-card;
|
||||
ti,needs-special-hs-handling;
|
||||
keep-power-in-suspend;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&mmc3_pins &wl18xx_pins>;
|
||||
|
|
|
|||
|
|
@ -75,6 +75,7 @@
|
|||
bus-width = <4>;
|
||||
non-removable;
|
||||
cap-power-off-card;
|
||||
ti,needs-special-hs-handling;
|
||||
keep-power-in-suspend;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&mmc3_pins &wl18xx_pins>;
|
||||
|
|
|
|||
|
|
@ -782,7 +782,8 @@
|
|||
bus-width = <4>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&mmc3_pins &wlan_pins>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
ti,needs-special-hs-handling;
|
||||
cap-power-off-card;
|
||||
keep-power-in-suspend;
|
||||
|
||||
|
|
|
|||
|
|
@ -700,7 +700,7 @@
|
|||
&mmc2 {
|
||||
status = "okay";
|
||||
vmmc-supply = <&wl12xx_vmmc>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
bus-width = <4>;
|
||||
cap-power-off-card;
|
||||
keep-power-in-suspend;
|
||||
|
|
|
|||
|
|
@ -361,7 +361,7 @@
|
|||
pinctrl-0 = <&emmc_pins>;
|
||||
vmmc-supply = <&vmmcsd_fixed>;
|
||||
bus-width = <8>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -176,7 +176,7 @@
|
|||
vmmc-supply = <&vmmcsd_fixed>;
|
||||
bus-width = <8>;
|
||||
pinctrl-0 = <&mmc1_pins_default>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -473,7 +473,7 @@
|
|||
vmmc-supply = <&vmmcsd_fixed>;
|
||||
bus-width = <8>;
|
||||
pinctrl-0 = <&mmc2_pins_default>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -341,7 +341,7 @@
|
|||
pinctrl-0 = <&emmc_pins>;
|
||||
vmmc-supply = <&ldo3_reg>;
|
||||
bus-width = <8>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
};
|
||||
|
||||
&mmc3 {
|
||||
|
|
@ -351,7 +351,7 @@
|
|||
pinctrl-0 = <&wireless_pins>;
|
||||
vmmmc-supply = <&v3v3c_reg>;
|
||||
bus-width = <4>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
dmas = <&edma_xbar 12 0 1
|
||||
&edma_xbar 13 0 2>;
|
||||
dma-names = "tx", "rx";
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@
|
|||
pinctrl-0 = <&emmc_pins>;
|
||||
vmmc-supply = <&vmmc_reg>;
|
||||
bus-width = <8>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -1333,8 +1333,10 @@
|
|||
ranges = <0x0 0x60000 0x1000>;
|
||||
|
||||
mmc1: mmc@0 {
|
||||
compatible = "ti,am335-sdhci";
|
||||
compatible = "ti,omap4-hsmmc";
|
||||
ti,dual-volt;
|
||||
ti,needs-special-reset;
|
||||
ti,needs-special-hs-handling;
|
||||
dmas = <&edma 24 0>, <&edma 25 0>;
|
||||
dma-names = "tx", "rx";
|
||||
interrupts = <64>;
|
||||
|
|
@ -1824,7 +1826,7 @@
|
|||
ranges = <0x0 0xd8000 0x1000>;
|
||||
|
||||
mmc2: mmc@0 {
|
||||
compatible = "ti,am335-sdhci";
|
||||
compatible = "ti,omap4-hsmmc";
|
||||
ti,needs-special-reset;
|
||||
dmas = <&edma 2 0
|
||||
&edma 3 0>;
|
||||
|
|
|
|||
|
|
@ -259,11 +259,10 @@
|
|||
ranges = <0x0 0x47810000 0x1000>;
|
||||
|
||||
mmc3: mmc@0 {
|
||||
compatible = "ti,am335-sdhci";
|
||||
compatible = "ti,omap4-hsmmc";
|
||||
ti,needs-special-reset;
|
||||
interrupts = <29>;
|
||||
reg = <0x0 0x1000>;
|
||||
status = "disabled";
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -250,11 +250,10 @@
|
|||
ranges = <0x0 0x47810000 0x1000>;
|
||||
|
||||
mmc3: mmc@0 {
|
||||
compatible = "ti,am437-sdhci";
|
||||
compatible = "ti,omap4-hsmmc";
|
||||
ti,needs-special-reset;
|
||||
interrupts = <GIC_SPI 29 IRQ_TYPE_LEVEL_HIGH>;
|
||||
reg = <0x0 0x1000>;
|
||||
status = "disabled";
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -291,7 +291,7 @@
|
|||
pinctrl-0 = <&emmc_pins>;
|
||||
vmmc-supply = <&vmmc_3v3>;
|
||||
bus-width = <8>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
};
|
||||
|
||||
&spi0 {
|
||||
|
|
|
|||
|
|
@ -872,7 +872,7 @@
|
|||
pinctrl-names = "default", "sleep";
|
||||
pinctrl-0 = <&emmc_pins_default>;
|
||||
pinctrl-1 = <&emmc_pins_sleep>;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
};
|
||||
|
||||
&mmc3 {
|
||||
|
|
@ -889,7 +889,7 @@
|
|||
pinctrl-1 = <&mmc3_pins_sleep>;
|
||||
cap-power-off-card;
|
||||
keep-power-in-suspend;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
|
|
|||
|
|
@ -1104,8 +1104,9 @@
|
|||
ranges = <0x0 0x60000 0x1000>;
|
||||
|
||||
mmc1: mmc@0 {
|
||||
compatible = "ti,am437-sdhci";
|
||||
compatible = "ti,omap4-hsmmc";
|
||||
reg = <0x0 0x1000>;
|
||||
ti,dual-volt;
|
||||
ti,needs-special-reset;
|
||||
dmas = <&edma 24 0>,
|
||||
<&edma 25 0>;
|
||||
|
|
@ -1640,7 +1641,7 @@
|
|||
ranges = <0x0 0xd8000 0x1000>;
|
||||
|
||||
mmc2: mmc@0 {
|
||||
compatible = "ti,am437-sdhci";
|
||||
compatible = "ti,omap4-hsmmc";
|
||||
reg = <0x0 0x1000>;
|
||||
ti,needs-special-reset;
|
||||
dmas = <&edma 2 0>,
|
||||
|
|
|
|||
|
|
@ -694,7 +694,7 @@
|
|||
pinctrl-1 = <&mmc3_pins_sleep>;
|
||||
cap-power-off-card;
|
||||
keep-power-in-suspend;
|
||||
non-removable;
|
||||
ti,non-removable;
|
||||
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
|
|
|||
|
|
@ -578,7 +578,7 @@
|
|||
status = "disabled";
|
||||
};
|
||||
|
||||
gpt: gpt@2098000 {
|
||||
gpt: timer@2098000 {
|
||||
compatible = "fsl,imx6q-gpt", "fsl,imx31-gpt";
|
||||
reg = <0x02098000 0x4000>;
|
||||
interrupts = <0 55 IRQ_TYPE_LEVEL_HIGH>;
|
||||
|
|
|
|||
|
|
@ -386,7 +386,7 @@
|
|||
clock-names = "ipg", "per";
|
||||
};
|
||||
|
||||
gpt: gpt@2098000 {
|
||||
gpt: timer@2098000 {
|
||||
compatible = "fsl,imx6sl-gpt";
|
||||
reg = <0x02098000 0x4000>;
|
||||
interrupts = <0 55 IRQ_TYPE_LEVEL_HIGH>;
|
||||
|
|
|
|||
|
|
@ -475,7 +475,7 @@
|
|||
status = "disabled";
|
||||
};
|
||||
|
||||
gpt: gpt@2098000 {
|
||||
gpt: timer@2098000 {
|
||||
compatible = "fsl,imx6sx-gpt", "fsl,imx6dl-gpt";
|
||||
reg = <0x02098000 0x4000>;
|
||||
interrupts = <GIC_SPI 55 IRQ_TYPE_LEVEL_HIGH>;
|
||||
|
|
|
|||
|
|
@ -433,7 +433,7 @@
|
|||
status = "disabled";
|
||||
};
|
||||
|
||||
gpt1: gpt@2098000 {
|
||||
gpt1: timer@2098000 {
|
||||
compatible = "fsl,imx6ul-gpt", "fsl,imx6sx-gpt";
|
||||
reg = <0x02098000 0x4000>;
|
||||
interrupts = <GIC_SPI 55 IRQ_TYPE_LEVEL_HIGH>;
|
||||
|
|
@ -707,7 +707,7 @@
|
|||
reg = <0x020e4000 0x4000>;
|
||||
};
|
||||
|
||||
gpt2: gpt@20e8000 {
|
||||
gpt2: timer@20e8000 {
|
||||
compatible = "fsl,imx6ul-gpt", "fsl,imx6sx-gpt";
|
||||
reg = <0x020e8000 0x4000>;
|
||||
interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>;
|
||||
|
|
|
|||
|
|
@ -446,8 +446,8 @@
|
|||
fsl,input-sel = <&iomuxc>;
|
||||
};
|
||||
|
||||
gpt1: gpt@302d0000 {
|
||||
compatible = "fsl,imx7d-gpt", "fsl,imx6sx-gpt";
|
||||
gpt1: timer@302d0000 {
|
||||
compatible = "fsl,imx7d-gpt", "fsl,imx6dl-gpt";
|
||||
reg = <0x302d0000 0x10000>;
|
||||
interrupts = <GIC_SPI 55 IRQ_TYPE_LEVEL_HIGH>;
|
||||
clocks = <&clks IMX7D_GPT1_ROOT_CLK>,
|
||||
|
|
@ -455,8 +455,8 @@
|
|||
clock-names = "ipg", "per";
|
||||
};
|
||||
|
||||
gpt2: gpt@302e0000 {
|
||||
compatible = "fsl,imx7d-gpt", "fsl,imx6sx-gpt";
|
||||
gpt2: timer@302e0000 {
|
||||
compatible = "fsl,imx7d-gpt", "fsl,imx6dl-gpt";
|
||||
reg = <0x302e0000 0x10000>;
|
||||
interrupts = <GIC_SPI 54 IRQ_TYPE_LEVEL_HIGH>;
|
||||
clocks = <&clks IMX7D_GPT2_ROOT_CLK>,
|
||||
|
|
@ -465,8 +465,8 @@
|
|||
status = "disabled";
|
||||
};
|
||||
|
||||
gpt3: gpt@302f0000 {
|
||||
compatible = "fsl,imx7d-gpt", "fsl,imx6sx-gpt";
|
||||
gpt3: timer@302f0000 {
|
||||
compatible = "fsl,imx7d-gpt", "fsl,imx6dl-gpt";
|
||||
reg = <0x302f0000 0x10000>;
|
||||
interrupts = <GIC_SPI 53 IRQ_TYPE_LEVEL_HIGH>;
|
||||
clocks = <&clks IMX7D_GPT3_ROOT_CLK>,
|
||||
|
|
@ -475,8 +475,8 @@
|
|||
status = "disabled";
|
||||
};
|
||||
|
||||
gpt4: gpt@30300000 {
|
||||
compatible = "fsl,imx7d-gpt", "fsl,imx6sx-gpt";
|
||||
gpt4: timer@30300000 {
|
||||
compatible = "fsl,imx7d-gpt", "fsl,imx6dl-gpt";
|
||||
reg = <0x30300000 0x10000>;
|
||||
interrupts = <GIC_SPI 52 IRQ_TYPE_LEVEL_HIGH>;
|
||||
clocks = <&clks IMX7D_GPT4_ROOT_CLK>,
|
||||
|
|
|
|||
|
|
@ -82,14 +82,12 @@
|
|||
};
|
||||
};
|
||||
|
||||
regulators {
|
||||
vsdcc_fixed: vsdcc-regulator {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "SDCC Power";
|
||||
regulator-min-microvolt = <2700000>;
|
||||
regulator-max-microvolt = <2700000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
vsdcc_fixed: vsdcc-regulator {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "SDCC Power";
|
||||
regulator-min-microvolt = <2700000>;
|
||||
regulator-max-microvolt = <2700000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
soc: soc {
|
||||
|
|
|
|||
|
|
@ -10,10 +10,6 @@
|
|||
|
||||
#include <linux/interrupt.h>
|
||||
|
||||
#ifdef CONFIG_FUNCTION_GRAPH_TRACER
|
||||
#define __exception_irq_entry __irq_entry
|
||||
#else
|
||||
#define __exception_irq_entry
|
||||
#endif
|
||||
|
||||
#endif /* __ASM_ARM_EXCEPTION_H */
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@
|
|||
ENTRY(mmioset)
|
||||
ENTRY(memset)
|
||||
UNWIND( .fnstart )
|
||||
and r1, r1, #255 @ cast to unsigned char
|
||||
ands r3, r0, #3 @ 1 unaligned?
|
||||
mov ip, r0 @ preserve r0 as return value
|
||||
bne 6f @ 1
|
||||
|
|
|
|||
|
|
@ -502,6 +502,10 @@ static int imx_mmdc_perf_init(struct platform_device *pdev, void __iomem *mmdc_b
|
|||
|
||||
name = devm_kasprintf(&pdev->dev,
|
||||
GFP_KERNEL, "mmdc%d", ret);
|
||||
if (!name) {
|
||||
ret = -ENOMEM;
|
||||
goto pmu_release_id;
|
||||
}
|
||||
|
||||
pmu_mmdc->mmdc_ipg_clk = mmdc_ipg_clk;
|
||||
pmu_mmdc->devtype_data = (struct fsl_mmdc_devtype_data *)of_id->data;
|
||||
|
|
@ -524,9 +528,10 @@ static int imx_mmdc_perf_init(struct platform_device *pdev, void __iomem *mmdc_b
|
|||
|
||||
pmu_register_err:
|
||||
pr_warn("MMDC Perf PMU failed (%d), disabled\n", ret);
|
||||
ida_simple_remove(&mmdc_ida, pmu_mmdc->id);
|
||||
cpuhp_state_remove_instance_nocalls(cpuhp_mmdc_state, &pmu_mmdc->node);
|
||||
hrtimer_cancel(&pmu_mmdc->hrtimer);
|
||||
pmu_release_id:
|
||||
ida_simple_remove(&mmdc_ida, pmu_mmdc->id);
|
||||
pmu_free:
|
||||
kfree(pmu_mmdc);
|
||||
return ret;
|
||||
|
|
|
|||
|
|
@ -362,7 +362,8 @@ static int __init xen_guest_init(void)
|
|||
* for secondary CPUs as they are brought up.
|
||||
* For uniformity we use VCPUOP_register_vcpu_info even on cpu0.
|
||||
*/
|
||||
xen_vcpu_info = alloc_percpu(struct vcpu_info);
|
||||
xen_vcpu_info = __alloc_percpu(sizeof(struct vcpu_info),
|
||||
1 << fls(sizeof(struct vcpu_info) - 1));
|
||||
if (xen_vcpu_info == NULL)
|
||||
return -ENOMEM;
|
||||
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@
|
|||
};
|
||||
};
|
||||
|
||||
memory {
|
||||
memory@40000000 {
|
||||
reg = <0 0x40000000 0 0x40000000>;
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@
|
|||
};
|
||||
};
|
||||
|
||||
memory {
|
||||
memory@40000000 {
|
||||
reg = <0 0x40000000 0 0x20000000>;
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@
|
|||
id-gpio = <&pio 16 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
usb_p1_vbus: regulator@0 {
|
||||
usb_p1_vbus: regulator-usb-p1 {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "usb_vbus";
|
||||
regulator-min-microvolt = <5000000>;
|
||||
|
|
@ -52,7 +52,7 @@
|
|||
enable-active-high;
|
||||
};
|
||||
|
||||
usb_p0_vbus: regulator@1 {
|
||||
usb_p0_vbus: regulator-usb-p0 {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "vbus";
|
||||
regulator-min-microvolt = <5000000>;
|
||||
|
|
|
|||
|
|
@ -468,6 +468,8 @@
|
|||
vdd-1.8-xo-supply = <&vreg_l7a_1p8>;
|
||||
vdd-1.3-rfa-supply = <&vreg_l17a_1p3>;
|
||||
vdd-3.3-ch0-supply = <&vreg_l25a_3p3>;
|
||||
|
||||
qcom,snoc-host-cap-8bit-quirk;
|
||||
};
|
||||
|
||||
/* PINCTRL - additions to nodes defined in sdm845.dtsi */
|
||||
|
|
|
|||
3
arch/arm64/configs/vendor/autogvm_GKI.config
vendored
3
arch/arm64/configs/vendor/autogvm_GKI.config
vendored
|
|
@ -3,9 +3,6 @@ CONFIG_COMMON_CLK_QCOM=m
|
|||
CONFIG_REGULATOR_FIXED_VOLTAGE=m
|
||||
CONFIG_REGULATOR_PROXY_CONSUMER=m
|
||||
CONFIG_REGULATOR_STUB=m
|
||||
CONFIG_TRIM_UNUSED_KSYMS=y
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST="android/abi_gki_aarch64_qcom android/abi_gki_aarch64_qcom_internal"
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST_ONLY=y
|
||||
CONFIG_PINCTRL_SM8150=m
|
||||
CONFIG_PINCTRL_SDMSHRIKE=m
|
||||
CONFIG_PINCTRL_SM6150=m
|
||||
|
|
|
|||
3
arch/arm64/configs/vendor/bengal_GKI.config
vendored
3
arch/arm64/configs/vendor/bengal_GKI.config
vendored
|
|
@ -1,9 +1,6 @@
|
|||
CONFIG_ARCH_QCOM=y
|
||||
CONFIG_ARCH_SCUBA=y
|
||||
CONFIG_ARCH_BENGAL=y
|
||||
CONFIG_TRIM_UNUSED_KSYMS=y
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST="android/abi_gki_aarch64_qcom android/abi_gki_aarch64_qcom_internal"
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST_ONLY=y
|
||||
CONFIG_PINCTRL_SCUBA=m
|
||||
CONFIG_QCOM_RPMH=m
|
||||
CONFIG_QCOM_COMMAND_DB=m
|
||||
|
|
|
|||
|
|
@ -9,9 +9,6 @@ CONFIG_REGULATOR_PROXY_CONSUMER=m
|
|||
CONFIG_REGULATOR_REFGEN=m
|
||||
CONFIG_REGULATOR_RPMH=m
|
||||
CONFIG_REGULATOR_STUB=m
|
||||
CONFIG_TRIM_UNUSED_KSYMS=y
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST="android/abi_gki_aarch64_qcom android/abi_gki_aarch64_qcom_internal"
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST_ONLY=y
|
||||
CONFIG_PINCTRL_SM8150=m
|
||||
CONFIG_PINCTRL_SDMSHRIKE=m
|
||||
CONFIG_PINCTRL_SLPI=m
|
||||
|
|
@ -140,3 +137,4 @@ CONFIG_CNSS_GENL=m
|
|||
CONFIG_QRTR_MHI=m
|
||||
CONFIG_UIO_MSM_SHAREDMEM=m
|
||||
CONFIG_INCREMENTAL_FS=m
|
||||
# CONFIG_TRIM_UNUSED_KSYMS is not set
|
||||
|
|
|
|||
4
arch/arm64/configs/vendor/holi_GKI.config
vendored
4
arch/arm64/configs/vendor/holi_GKI.config
vendored
|
|
@ -1,8 +1,5 @@
|
|||
CONFIG_ARCH_QCOM=y
|
||||
CONFIG_ARCH_HOLI=y
|
||||
CONFIG_TRIM_UNUSED_KSYMS=y
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST="android/abi_gki_aarch64_qcom android/abi_gki_aarch64_qcom_internal"
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST_ONLY=y
|
||||
CONFIG_QCOM_RPMH=m
|
||||
CONFIG_QCOM_RPMHPD=m
|
||||
CONFIG_QCOM_COMMAND_DB=m
|
||||
|
|
@ -234,3 +231,4 @@ CONFIG_SM_DISPCC_BLAIR=m
|
|||
CONFIG_SM_DEBUGCC_BLAIR=m
|
||||
CONFIG_QCOM_CX_IPEAK=m
|
||||
CONFIG_LEDS_AW2016=m
|
||||
# CONFIG_TRIM_UNUSED_KSYMS is not set
|
||||
|
|
|
|||
4
arch/arm64/configs/vendor/lahaina_GKI.config
vendored
4
arch/arm64/configs/vendor/lahaina_GKI.config
vendored
|
|
@ -1,9 +1,6 @@
|
|||
CONFIG_ARCH_QCOM=y
|
||||
CONFIG_ARCH_LAHAINA=y
|
||||
CONFIG_ARCH_SHIMA=y
|
||||
CONFIG_TRIM_UNUSED_KSYMS=y
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST="android/abi_gki_aarch64_qcom android/abi_gki_aarch64_qcom_internal"
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST_ONLY=y
|
||||
CONFIG_QCOM_RPMH=m
|
||||
CONFIG_QCOM_RPMHPD=m
|
||||
CONFIG_QCOM_COMMAND_DB=m
|
||||
|
|
@ -252,3 +249,4 @@ CONFIG_REGULATOR_QPNP_LCDB=m
|
|||
CONFIG_LEDS_QPNP_VIBRATOR_LDO=m
|
||||
CONFIG_BACKLIGHT_QCOM_SPMI_WLED=m
|
||||
# CONFIG_CFG80211_CRDA_SUPPORT is not set
|
||||
# CONFIG_TRIM_UNUSED_KSYMS is not set
|
||||
|
|
|
|||
|
|
@ -8,9 +8,6 @@ CONFIG_REGULATOR_PROXY_CONSUMER=m
|
|||
CONFIG_REGULATOR_REFGEN=m
|
||||
CONFIG_REGULATOR_RPMH=m
|
||||
CONFIG_REGULATOR_STUB=m
|
||||
CONFIG_TRIM_UNUSED_KSYMS=y
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST="android/abi_gki_aarch64_qcom android/abi_gki_aarch64_qcom_internal"
|
||||
CONFIG_UNUSED_KSYMS_WHITELIST_ONLY=y
|
||||
CONFIG_PINCTRL_SM6150=m
|
||||
CONFIG_PINCTRL_SDMSHRIKE=m
|
||||
CONFIG_HEADER_TEST=y
|
||||
|
|
|
|||
|
|
@ -449,6 +449,29 @@ cpuid_feature_extract_unsigned_field(u64 features, int field)
|
|||
return cpuid_feature_extract_unsigned_field_width(features, field, 4);
|
||||
}
|
||||
|
||||
/*
|
||||
* Fields that identify the version of the Performance Monitors Extension do
|
||||
* not follow the standard ID scheme. See ARM DDI 0487E.a page D13-2825,
|
||||
* "Alternative ID scheme used for the Performance Monitors Extension version".
|
||||
*/
|
||||
static inline u64 __attribute_const__
|
||||
cpuid_feature_cap_perfmon_field(u64 features, int field, u64 cap)
|
||||
{
|
||||
u64 val = cpuid_feature_extract_unsigned_field(features, field);
|
||||
u64 mask = GENMASK_ULL(field + 3, field);
|
||||
|
||||
/* Treat IMPLEMENTATION DEFINED functionality as unimplemented */
|
||||
if (val == 0xf)
|
||||
val = 0;
|
||||
|
||||
if (val > cap) {
|
||||
features &= ~mask;
|
||||
features |= (cap << field) & mask;
|
||||
}
|
||||
|
||||
return features;
|
||||
}
|
||||
|
||||
static inline u64 arm64_ftr_mask(const struct arm64_ftr_bits *ftrp)
|
||||
{
|
||||
return (u64)GENMASK(ftrp->shift + ftrp->width - 1, ftrp->shift);
|
||||
|
|
|
|||
|
|
@ -694,6 +694,12 @@ static inline pte_t pte_modify(pte_t pte, pgprot_t newprot)
|
|||
if (pte_hw_dirty(pte))
|
||||
pte = pte_mkdirty(pte);
|
||||
pte_val(pte) = (pte_val(pte) & ~mask) | (pgprot_val(newprot) & mask);
|
||||
/*
|
||||
* If we end up clearing hw dirtiness for a sw-dirty PTE, set hardware
|
||||
* dirtiness again.
|
||||
*/
|
||||
if (pte_sw_dirty(pte))
|
||||
pte = pte_mkdirty(pte);
|
||||
return pte;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -735,6 +735,12 @@
|
|||
#define ID_AA64DFR0_TRACEVER_SHIFT 4
|
||||
#define ID_AA64DFR0_DEBUGVER_SHIFT 0
|
||||
|
||||
#define ID_AA64DFR0_PMUVER_8_1 0x4
|
||||
|
||||
#define ID_DFR0_PERFMON_SHIFT 24
|
||||
|
||||
#define ID_DFR0_PERFMON_8_1 0x4
|
||||
|
||||
#define ID_ISAR5_RDM_SHIFT 24
|
||||
#define ID_ISAR5_CRC32_SHIFT 16
|
||||
#define ID_ISAR5_SHA2_SHIFT 12
|
||||
|
|
|
|||
|
|
@ -208,10 +208,12 @@ static int emulation_proc_handler(struct ctl_table *table, int write,
|
|||
loff_t *ppos)
|
||||
{
|
||||
int ret = 0;
|
||||
struct insn_emulation *insn = container_of(table->data, struct insn_emulation, current_mode);
|
||||
enum insn_emulation_mode prev_mode = insn->current_mode;
|
||||
struct insn_emulation *insn;
|
||||
enum insn_emulation_mode prev_mode;
|
||||
|
||||
mutex_lock(&insn_emulation_mutex);
|
||||
insn = container_of(table->data, struct insn_emulation, current_mode);
|
||||
prev_mode = insn->current_mode;
|
||||
ret = proc_dointvec_minmax(table, write, buffer, lenp, ppos);
|
||||
|
||||
if (ret || !write || prev_mode == insn->current_mode)
|
||||
|
|
|
|||
|
|
@ -1105,6 +1105,16 @@ static u64 read_id_reg(const struct kvm_vcpu *vcpu,
|
|||
(0xfUL << ID_AA64ISAR1_API_SHIFT) |
|
||||
(0xfUL << ID_AA64ISAR1_GPA_SHIFT) |
|
||||
(0xfUL << ID_AA64ISAR1_GPI_SHIFT));
|
||||
} else if (id == SYS_ID_AA64DFR0_EL1) {
|
||||
/* Limit guests to PMUv3 for ARMv8.1 */
|
||||
val = cpuid_feature_cap_perfmon_field(val,
|
||||
ID_AA64DFR0_PMUVER_SHIFT,
|
||||
ID_AA64DFR0_PMUVER_8_1);
|
||||
} else if (id == SYS_ID_DFR0_EL1) {
|
||||
/* Limit guests to PMUv3 for ARMv8.1 */
|
||||
val = cpuid_feature_cap_perfmon_field(val,
|
||||
ID_DFR0_PERFMON_SHIFT,
|
||||
ID_DFR0_PERFMON_8_1);
|
||||
}
|
||||
|
||||
return val;
|
||||
|
|
|
|||
|
|
@ -693,7 +693,7 @@ static int kvm_mips_map_page(struct kvm_vcpu *vcpu, unsigned long gpa,
|
|||
gfn_t gfn = gpa >> PAGE_SHIFT;
|
||||
int srcu_idx, err;
|
||||
kvm_pfn_t pfn;
|
||||
pte_t *ptep, entry, old_pte;
|
||||
pte_t *ptep, entry;
|
||||
bool writeable;
|
||||
unsigned long prot_bits;
|
||||
unsigned long mmu_seq;
|
||||
|
|
@ -766,7 +766,6 @@ retry:
|
|||
entry = pfn_pte(pfn, __pgprot(prot_bits));
|
||||
|
||||
/* Write the PTE */
|
||||
old_pte = *ptep;
|
||||
set_pte(ptep, entry);
|
||||
|
||||
err = 0;
|
||||
|
|
|
|||
|
|
@ -465,6 +465,7 @@ struct pdc_model { /* for PDC_MODEL */
|
|||
unsigned long arch_rev;
|
||||
unsigned long pot_key;
|
||||
unsigned long curr_key;
|
||||
unsigned long width; /* default of PSW_W bit (1=enabled) */
|
||||
};
|
||||
|
||||
struct pdc_cache_cf { /* for PDC_CACHE (I/D-caches) */
|
||||
|
|
|
|||
|
|
@ -511,13 +511,13 @@
|
|||
* to a CPU TLB 4k PFN (4k => 12 bits to shift) */
|
||||
#define PAGE_ADD_SHIFT (PAGE_SHIFT-12)
|
||||
#define PAGE_ADD_HUGE_SHIFT (REAL_HPAGE_SHIFT-12)
|
||||
#define PFN_START_BIT (63-ASM_PFN_PTE_SHIFT+(63-58)-PAGE_ADD_SHIFT)
|
||||
|
||||
/* Drop prot bits and convert to page addr for iitlbt and idtlbt */
|
||||
.macro convert_for_tlb_insert20 pte,tmp
|
||||
#ifdef CONFIG_HUGETLB_PAGE
|
||||
copy \pte,\tmp
|
||||
extrd,u \tmp,(63-ASM_PFN_PTE_SHIFT)+(63-58)+PAGE_ADD_SHIFT,\
|
||||
64-PAGE_SHIFT-PAGE_ADD_SHIFT,\pte
|
||||
extrd,u \tmp,PFN_START_BIT,PFN_START_BIT+1,\pte
|
||||
|
||||
depdi _PAGE_SIZE_ENCODING_DEFAULT,63,\
|
||||
(63-58)+PAGE_ADD_SHIFT,\pte
|
||||
|
|
@ -525,8 +525,7 @@
|
|||
depdi _HUGE_PAGE_SIZE_ENCODING_DEFAULT,63,\
|
||||
(63-58)+PAGE_ADD_HUGE_SHIFT,\pte
|
||||
#else /* Huge pages disabled */
|
||||
extrd,u \pte,(63-ASM_PFN_PTE_SHIFT)+(63-58)+PAGE_ADD_SHIFT,\
|
||||
64-PAGE_SHIFT-PAGE_ADD_SHIFT,\pte
|
||||
extrd,u \pte,PFN_START_BIT,PFN_START_BIT+1,\pte
|
||||
depdi _PAGE_SIZE_ENCODING_DEFAULT,63,\
|
||||
(63-58)+PAGE_ADD_SHIFT,\pte
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -69,9 +69,8 @@ $bss_loop:
|
|||
stw,ma %arg2,4(%r1)
|
||||
stw,ma %arg3,4(%r1)
|
||||
|
||||
#if !defined(CONFIG_64BIT) && defined(CONFIG_PA20)
|
||||
/* This 32-bit kernel was compiled for PA2.0 CPUs. Check current CPU
|
||||
* and halt kernel if we detect a PA1.x CPU. */
|
||||
#if defined(CONFIG_PA20)
|
||||
/* check for 64-bit capable CPU as required by current kernel */
|
||||
ldi 32,%r10
|
||||
mtctl %r10,%cr11
|
||||
.level 2.0
|
||||
|
|
|
|||
|
|
@ -24,6 +24,15 @@
|
|||
#include <asm/feature-fixups.h>
|
||||
|
||||
#ifdef CONFIG_VSX
|
||||
#define __REST_1FPVSR(n,c,base) \
|
||||
BEGIN_FTR_SECTION \
|
||||
b 2f; \
|
||||
END_FTR_SECTION_IFSET(CPU_FTR_VSX); \
|
||||
REST_FPR(n,base); \
|
||||
b 3f; \
|
||||
2: REST_VSR(n,c,base); \
|
||||
3:
|
||||
|
||||
#define __REST_32FPVSRS(n,c,base) \
|
||||
BEGIN_FTR_SECTION \
|
||||
b 2f; \
|
||||
|
|
@ -42,9 +51,11 @@ END_FTR_SECTION_IFSET(CPU_FTR_VSX); \
|
|||
2: SAVE_32VSRS(n,c,base); \
|
||||
3:
|
||||
#else
|
||||
#define __REST_1FPVSR(n,b,base) REST_FPR(n, base)
|
||||
#define __REST_32FPVSRS(n,b,base) REST_32FPRS(n, base)
|
||||
#define __SAVE_32FPVSRS(n,b,base) SAVE_32FPRS(n, base)
|
||||
#endif
|
||||
#define REST_1FPVSR(n,c,base) __REST_1FPVSR(n,__REG_##c,__REG_##base)
|
||||
#define REST_32FPVSRS(n,c,base) __REST_32FPVSRS(n,__REG_##c,__REG_##base)
|
||||
#define SAVE_32FPVSRS(n,c,base) __SAVE_32FPVSRS(n,__REG_##c,__REG_##base)
|
||||
|
||||
|
|
@ -68,6 +79,7 @@ _GLOBAL(store_fp_state)
|
|||
SAVE_32FPVSRS(0, R4, R3)
|
||||
mffs fr0
|
||||
stfd fr0,FPSTATE_FPSCR(r3)
|
||||
REST_1FPVSR(0, R4, R3)
|
||||
blr
|
||||
EXPORT_SYMBOL(store_fp_state)
|
||||
|
||||
|
|
@ -132,6 +144,7 @@ _GLOBAL(save_fpu)
|
|||
2: SAVE_32FPVSRS(0, R4, R6)
|
||||
mffs fr0
|
||||
stfd fr0,FPSTATE_FPSCR(r6)
|
||||
REST_1FPVSR(0, R4, R6)
|
||||
blr
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -36,6 +36,9 @@ _GLOBAL(ftrace_regs_caller)
|
|||
/* Save the original return address in A's stack frame */
|
||||
std r0,LRSAVE(r1)
|
||||
|
||||
/* Create a minimal stack frame for representing B */
|
||||
stdu r1, -STACK_FRAME_MIN_SIZE(r1)
|
||||
|
||||
/* Create our stack frame + pt_regs */
|
||||
stdu r1,-SWITCH_FRAME_SIZE(r1)
|
||||
|
||||
|
|
@ -52,7 +55,7 @@ _GLOBAL(ftrace_regs_caller)
|
|||
SAVE_10GPRS(22, r1)
|
||||
|
||||
/* Save previous stack pointer (r1) */
|
||||
addi r8, r1, SWITCH_FRAME_SIZE
|
||||
addi r8, r1, SWITCH_FRAME_SIZE+STACK_FRAME_MIN_SIZE
|
||||
std r8, GPR1(r1)
|
||||
|
||||
/* Load special regs for save below */
|
||||
|
|
@ -65,6 +68,8 @@ _GLOBAL(ftrace_regs_caller)
|
|||
mflr r7
|
||||
/* Save it as pt_regs->nip */
|
||||
std r7, _NIP(r1)
|
||||
/* Also save it in B's stackframe header for proper unwind */
|
||||
std r7, LRSAVE+SWITCH_FRAME_SIZE(r1)
|
||||
/* Save the read LR in pt_regs->link */
|
||||
std r0, _LINK(r1)
|
||||
|
||||
|
|
@ -121,7 +126,7 @@ ftrace_regs_call:
|
|||
ld r2, 24(r1)
|
||||
|
||||
/* Pop our stack frame */
|
||||
addi r1, r1, SWITCH_FRAME_SIZE
|
||||
addi r1, r1, SWITCH_FRAME_SIZE+STACK_FRAME_MIN_SIZE
|
||||
|
||||
#ifdef CONFIG_LIVEPATCH
|
||||
/* Based on the cmpd above, if the NIP was altered handle livepatch */
|
||||
|
|
@ -145,7 +150,7 @@ ftrace_no_trace:
|
|||
mflr r3
|
||||
mtctr r3
|
||||
REST_GPR(3, r1)
|
||||
addi r1, r1, SWITCH_FRAME_SIZE
|
||||
addi r1, r1, SWITCH_FRAME_SIZE+STACK_FRAME_MIN_SIZE
|
||||
mtlr r0
|
||||
bctr
|
||||
|
||||
|
|
@ -153,6 +158,9 @@ _GLOBAL(ftrace_caller)
|
|||
/* Save the original return address in A's stack frame */
|
||||
std r0, LRSAVE(r1)
|
||||
|
||||
/* Create a minimal stack frame for representing B */
|
||||
stdu r1, -STACK_FRAME_MIN_SIZE(r1)
|
||||
|
||||
/* Create our stack frame + pt_regs */
|
||||
stdu r1, -SWITCH_FRAME_SIZE(r1)
|
||||
|
||||
|
|
@ -166,6 +174,7 @@ _GLOBAL(ftrace_caller)
|
|||
/* Get the _mcount() call site out of LR */
|
||||
mflr r7
|
||||
std r7, _NIP(r1)
|
||||
std r7, LRSAVE+SWITCH_FRAME_SIZE(r1)
|
||||
|
||||
/* Save callee's TOC in the ABI compliant location */
|
||||
std r2, 24(r1)
|
||||
|
|
@ -200,7 +209,7 @@ ftrace_call:
|
|||
ld r2, 24(r1)
|
||||
|
||||
/* Pop our stack frame */
|
||||
addi r1, r1, SWITCH_FRAME_SIZE
|
||||
addi r1, r1, SWITCH_FRAME_SIZE+STACK_FRAME_MIN_SIZE
|
||||
|
||||
/* Reload original LR */
|
||||
ld r0, LRSAVE(r1)
|
||||
|
|
|
|||
|
|
@ -32,6 +32,7 @@ _GLOBAL(store_vr_state)
|
|||
mfvscr v0
|
||||
li r4, VRSTATE_VSCR
|
||||
stvx v0, r4, r3
|
||||
lvx v0, 0, r3
|
||||
blr
|
||||
EXPORT_SYMBOL(store_vr_state)
|
||||
|
||||
|
|
@ -102,6 +103,7 @@ _GLOBAL(save_altivec)
|
|||
mfvscr v0
|
||||
li r4,VRSTATE_VSCR
|
||||
stvx v0,r4,r7
|
||||
lvx v0,0,r7
|
||||
blr
|
||||
|
||||
#ifdef CONFIG_VSX
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ static int trace_imc_mem_size;
|
|||
* core and trace-imc
|
||||
*/
|
||||
static struct imc_pmu_ref imc_global_refc = {
|
||||
.lock = __SPIN_LOCK_INITIALIZER(imc_global_refc.lock),
|
||||
.lock = __SPIN_LOCK_UNLOCKED(imc_global_refc.lock),
|
||||
.id = 0,
|
||||
.refc = 0,
|
||||
};
|
||||
|
|
|
|||
|
|
@ -522,8 +522,10 @@ static ssize_t vcpudispatch_stats_write(struct file *file, const char __user *p,
|
|||
|
||||
if (cmd) {
|
||||
rc = init_cpu_associativity();
|
||||
if (rc)
|
||||
if (rc) {
|
||||
destroy_cpu_associativity();
|
||||
goto out;
|
||||
}
|
||||
|
||||
for_each_possible_cpu(cpu) {
|
||||
disp = per_cpu_ptr(&vcpu_disp_data, cpu);
|
||||
|
|
|
|||
|
|
@ -778,7 +778,7 @@ int xive_native_get_queue_info(u32 vp_id, u32 prio,
|
|||
if (out_qpage)
|
||||
*out_qpage = be64_to_cpu(qpage);
|
||||
if (out_qsize)
|
||||
*out_qsize = be32_to_cpu(qsize);
|
||||
*out_qsize = be64_to_cpu(qsize);
|
||||
if (out_qeoi_page)
|
||||
*out_qeoi_page = be64_to_cpu(qeoi_page);
|
||||
if (out_escalate_irq)
|
||||
|
|
|
|||
|
|
@ -112,7 +112,7 @@ static void mark_kernel_pmd(pud_t *pud, unsigned long addr, unsigned long end)
|
|||
next = pmd_addr_end(addr, end);
|
||||
if (pmd_none(*pmd) || pmd_large(*pmd))
|
||||
continue;
|
||||
page = virt_to_page(pmd_val(*pmd));
|
||||
page = phys_to_page(pmd_val(*pmd));
|
||||
set_bit(PG_arch_1, &page->flags);
|
||||
} while (pmd++, addr = next, addr != end);
|
||||
}
|
||||
|
|
@ -130,8 +130,8 @@ static void mark_kernel_pud(p4d_t *p4d, unsigned long addr, unsigned long end)
|
|||
if (pud_none(*pud) || pud_large(*pud))
|
||||
continue;
|
||||
if (!pud_folded(*pud)) {
|
||||
page = virt_to_page(pud_val(*pud));
|
||||
for (i = 0; i < 3; i++)
|
||||
page = phys_to_page(pud_val(*pud));
|
||||
for (i = 0; i < 4; i++)
|
||||
set_bit(PG_arch_1, &page[i].flags);
|
||||
}
|
||||
mark_kernel_pmd(pud, addr, next);
|
||||
|
|
@ -151,8 +151,8 @@ static void mark_kernel_p4d(pgd_t *pgd, unsigned long addr, unsigned long end)
|
|||
if (p4d_none(*p4d))
|
||||
continue;
|
||||
if (!p4d_folded(*p4d)) {
|
||||
page = virt_to_page(p4d_val(*p4d));
|
||||
for (i = 0; i < 3; i++)
|
||||
page = phys_to_page(p4d_val(*p4d));
|
||||
for (i = 0; i < 4; i++)
|
||||
set_bit(PG_arch_1, &page[i].flags);
|
||||
}
|
||||
mark_kernel_pud(p4d, addr, next);
|
||||
|
|
@ -173,8 +173,8 @@ static void mark_kernel_pgd(void)
|
|||
if (pgd_none(*pgd))
|
||||
continue;
|
||||
if (!pgd_folded(*pgd)) {
|
||||
page = virt_to_page(pgd_val(*pgd));
|
||||
for (i = 0; i < 3; i++)
|
||||
page = phys_to_page(pgd_val(*pgd));
|
||||
for (i = 0; i < 4; i++)
|
||||
set_bit(PG_arch_1, &page[i].flags);
|
||||
}
|
||||
mark_kernel_p4d(pgd, addr, next);
|
||||
|
|
|
|||
|
|
@ -699,7 +699,7 @@ void ptep_zap_unused(struct mm_struct *mm, unsigned long addr,
|
|||
pte_clear(mm, addr, ptep);
|
||||
}
|
||||
if (reset)
|
||||
pgste_val(pgste) &= ~_PGSTE_GPS_USAGE_MASK;
|
||||
pgste_val(pgste) &= ~(_PGSTE_GPS_USAGE_MASK | _PGSTE_GPS_NODAT);
|
||||
pgste_set_unlock(ptep, pgste);
|
||||
preempt_enable();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,6 +26,17 @@ config STACK_DEBUG
|
|||
every function call and will therefore incur a major
|
||||
performance hit. Most users should say N.
|
||||
|
||||
config EARLY_PRINTK
|
||||
bool "Early printk"
|
||||
depends on SH_STANDARD_BIOS
|
||||
help
|
||||
Say Y here to redirect kernel printk messages to the serial port
|
||||
used by the SH-IPL bootloader, starting very early in the boot
|
||||
process and ending when the kernel's serial console is initialised.
|
||||
This option is only useful while porting the kernel to a new machine,
|
||||
when the kernel may crash or hang before the serial console is
|
||||
initialised. If unsure, say N.
|
||||
|
||||
config 4KSTACKS
|
||||
bool "Use 4Kb for kernel stacks instead of 8Kb"
|
||||
depends on DEBUG_KERNEL && (MMU || BROKEN) && !PAGE_SIZE_64KB
|
||||
|
|
|
|||
|
|
@ -67,6 +67,8 @@ struct legacy_pic {
|
|||
void (*make_irq)(unsigned int irq);
|
||||
};
|
||||
|
||||
void legacy_pic_pcat_compat(void);
|
||||
|
||||
extern struct legacy_pic *legacy_pic;
|
||||
extern struct legacy_pic null_legacy_pic;
|
||||
|
||||
|
|
|
|||
|
|
@ -469,6 +469,7 @@
|
|||
#define MSR_AMD64_OSVW_STATUS 0xc0010141
|
||||
#define MSR_AMD64_LS_CFG 0xc0011020
|
||||
#define MSR_AMD64_DC_CFG 0xc0011022
|
||||
#define MSR_AMD64_TW_CFG 0xc0011023
|
||||
|
||||
#define MSR_AMD64_DE_CFG 0xc0011029
|
||||
#define MSR_AMD64_DE_CFG_LFENCE_SERIALIZE_BIT 1
|
||||
|
|
|
|||
|
|
@ -11,13 +11,6 @@
|
|||
|
||||
#define NR_NODE_MEMBLKS (MAX_NUMNODES*2)
|
||||
|
||||
/*
|
||||
* Too small node sizes may confuse the VM badly. Usually they
|
||||
* result from BIOS bugs. So dont recognize nodes as standalone
|
||||
* NUMA entities that have less than this amount of RAM listed:
|
||||
*/
|
||||
#define NODE_MIN_SIZE (4*1024*1024)
|
||||
|
||||
extern int numa_off;
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -94,27 +94,16 @@ extern unsigned long _brk_end;
|
|||
void *extend_brk(size_t size, size_t align);
|
||||
|
||||
/*
|
||||
* Reserve space in the brk section. The name must be unique within
|
||||
* the file, and somewhat descriptive. The size is in bytes. Must be
|
||||
* used at file scope.
|
||||
* Reserve space in the .brk section, which is a block of memory from which the
|
||||
* caller is allowed to allocate very early (before even memblock is available)
|
||||
* by calling extend_brk(). All allocated memory will be eventually converted
|
||||
* to memblock. Any leftover unallocated memory will be freed.
|
||||
*
|
||||
* (This uses a temp function to wrap the asm so we can pass it the
|
||||
* size parameter; otherwise we wouldn't be able to. We can't use a
|
||||
* "section" attribute on a normal variable because it always ends up
|
||||
* being @progbits, which ends up allocating space in the vmlinux
|
||||
* executable.)
|
||||
* The size is in bytes.
|
||||
*/
|
||||
#define RESERVE_BRK(name,sz) \
|
||||
static void __section(.discard.text) __used notrace \
|
||||
__brk_reservation_fn_##name##__(void) { \
|
||||
asm volatile ( \
|
||||
".pushsection .brk_reservation,\"aw\",@nobits;" \
|
||||
".brk." #name ":" \
|
||||
" 1:.skip %c0;" \
|
||||
" .size .brk." #name ", . - 1b;" \
|
||||
" .popsection" \
|
||||
: : "i" (sz)); \
|
||||
}
|
||||
#define RESERVE_BRK(name, size) \
|
||||
__section(.bss..brk) __aligned(1) __used \
|
||||
static char __brk_##name[size]
|
||||
|
||||
/* Helper for reserving space for arrays of things */
|
||||
#define RESERVE_BRK_ARRAY(type, name, entries) \
|
||||
|
|
@ -132,12 +121,19 @@ asmlinkage void __init x86_64_start_reservations(char *real_mode_data);
|
|||
|
||||
#endif /* __i386__ */
|
||||
#endif /* _SETUP */
|
||||
#else
|
||||
#define RESERVE_BRK(name,sz) \
|
||||
.pushsection .brk_reservation,"aw",@nobits; \
|
||||
.brk.name: \
|
||||
1: .skip sz; \
|
||||
.size .brk.name,.-1b; \
|
||||
|
||||
#else /* __ASSEMBLY */
|
||||
|
||||
.macro __RESERVE_BRK name, size
|
||||
.pushsection .bss..brk, "aw"
|
||||
SYM_DATA_START(__brk_\name)
|
||||
.skip \size
|
||||
SYM_DATA_END(__brk_\name)
|
||||
.popsection
|
||||
.endm
|
||||
|
||||
#define RESERVE_BRK(name, size) __RESERVE_BRK name, size
|
||||
|
||||
#endif /* __ASSEMBLY__ */
|
||||
|
||||
#endif /* _ASM_X86_SETUP_H */
|
||||
|
|
|
|||
|
|
@ -140,6 +140,9 @@ static int __init acpi_parse_madt(struct acpi_table_header *table)
|
|||
madt->address);
|
||||
}
|
||||
|
||||
if (madt->flags & ACPI_MADT_PCAT_COMPAT)
|
||||
legacy_pic_pcat_compat();
|
||||
|
||||
default_acpi_madt_oem_check(madt->header.oem_id,
|
||||
madt->header.oem_table_id);
|
||||
|
||||
|
|
|
|||
|
|
@ -1248,5 +1248,8 @@ static void zenbleed_check_cpu(void *unused)
|
|||
|
||||
void amd_check_microcode(void)
|
||||
{
|
||||
if (boot_cpu_data.x86_vendor != X86_VENDOR_AMD)
|
||||
return;
|
||||
|
||||
on_each_cpu(zenbleed_check_cpu, NULL, 1);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -88,8 +88,12 @@ static void hygon_get_topology(struct cpuinfo_x86 *c)
|
|||
if (!err)
|
||||
c->x86_coreid_bits = get_count_order(c->x86_max_cores);
|
||||
|
||||
/* Socket ID is ApicId[6] for these processors. */
|
||||
c->phys_proc_id = c->apicid >> APICID_SOCKET_ID_BIT;
|
||||
/*
|
||||
* Socket ID is ApicId[6] for the processors with model <= 0x3
|
||||
* when running on host.
|
||||
*/
|
||||
if (!boot_cpu_has(X86_FEATURE_HYPERVISOR) && c->x86_model <= 0x3)
|
||||
c->phys_proc_id = c->apicid >> APICID_SOCKET_ID_BIT;
|
||||
|
||||
cacheinfo_hygon_init_llc_id(c, cpu);
|
||||
} else if (cpu_has(c, X86_FEATURE_NODEID_MSR)) {
|
||||
|
|
|
|||
|
|
@ -32,6 +32,7 @@
|
|||
*/
|
||||
static void init_8259A(int auto_eoi);
|
||||
|
||||
static bool pcat_compat __ro_after_init;
|
||||
static int i8259A_auto_eoi;
|
||||
DEFINE_RAW_SPINLOCK(i8259A_lock);
|
||||
|
||||
|
|
@ -301,15 +302,32 @@ static void unmask_8259A(void)
|
|||
|
||||
static int probe_8259A(void)
|
||||
{
|
||||
unsigned char new_val, probe_val = ~(1 << PIC_CASCADE_IR);
|
||||
unsigned long flags;
|
||||
unsigned char probe_val = ~(1 << PIC_CASCADE_IR);
|
||||
unsigned char new_val;
|
||||
|
||||
/*
|
||||
* Check to see if we have a PIC.
|
||||
* Mask all except the cascade and read
|
||||
* back the value we just wrote. If we don't
|
||||
* have a PIC, we will read 0xff as opposed to the
|
||||
* value we wrote.
|
||||
* If MADT has the PCAT_COMPAT flag set, then do not bother probing
|
||||
* for the PIC. Some BIOSes leave the PIC uninitialized and probing
|
||||
* fails.
|
||||
*
|
||||
* Right now this causes problems as quite some code depends on
|
||||
* nr_legacy_irqs() > 0 or has_legacy_pic() == true. This is silly
|
||||
* when the system has an IO/APIC because then PIC is not required
|
||||
* at all, except for really old machines where the timer interrupt
|
||||
* must be routed through the PIC. So just pretend that the PIC is
|
||||
* there and let legacy_pic->init() initialize it for nothing.
|
||||
*
|
||||
* Alternatively this could just try to initialize the PIC and
|
||||
* repeat the probe, but for cases where there is no PIC that's
|
||||
* just pointless.
|
||||
*/
|
||||
if (pcat_compat)
|
||||
return nr_legacy_irqs();
|
||||
|
||||
/*
|
||||
* Check to see if we have a PIC. Mask all except the cascade and
|
||||
* read back the value we just wrote. If we don't have a PIC, we
|
||||
* will read 0xff as opposed to the value we wrote.
|
||||
*/
|
||||
raw_spin_lock_irqsave(&i8259A_lock, flags);
|
||||
|
||||
|
|
@ -431,5 +449,9 @@ static int __init i8259A_init_ops(void)
|
|||
|
||||
return 0;
|
||||
}
|
||||
|
||||
device_initcall(i8259A_init_ops);
|
||||
|
||||
void __init legacy_pic_pcat_compat(void)
|
||||
{
|
||||
pcat_compat = true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -389,7 +389,7 @@ SECTIONS
|
|||
.brk : AT(ADDR(.brk) - LOAD_OFFSET) {
|
||||
__brk_base = .;
|
||||
. += 64 * 1024; /* 64k alignment slop space */
|
||||
*(.brk_reservation) /* areas brk users have reserved */
|
||||
*(.bss..brk) /* areas brk users have reserved */
|
||||
__brk_limit = .;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -555,10 +555,12 @@ static int stimer_set_count(struct kvm_vcpu_hv_stimer *stimer, u64 count,
|
|||
|
||||
stimer_cleanup(stimer);
|
||||
stimer->count = count;
|
||||
if (stimer->count == 0)
|
||||
stimer->config.enable = 0;
|
||||
else if (stimer->config.auto_enable)
|
||||
stimer->config.enable = 1;
|
||||
if (!host) {
|
||||
if (stimer->count == 0)
|
||||
stimer->config.enable = 0;
|
||||
else if (stimer->config.auto_enable)
|
||||
stimer->config.enable = 1;
|
||||
}
|
||||
|
||||
if (stimer->config.enable)
|
||||
stimer_mark_pending(stimer, false);
|
||||
|
|
|
|||
|
|
@ -2720,6 +2720,7 @@ int kvm_set_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
|
|||
case MSR_AMD64_PATCH_LOADER:
|
||||
case MSR_AMD64_BU_CFG2:
|
||||
case MSR_AMD64_DC_CFG:
|
||||
case MSR_AMD64_TW_CFG:
|
||||
case MSR_F15H_EX_CFG:
|
||||
break;
|
||||
|
||||
|
|
@ -3029,6 +3030,7 @@ int kvm_get_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
|
|||
case MSR_AMD64_BU_CFG2:
|
||||
case MSR_IA32_PERF_CTL:
|
||||
case MSR_AMD64_DC_CFG:
|
||||
case MSR_AMD64_TW_CFG:
|
||||
case MSR_F15H_EX_CFG:
|
||||
msr_info->data = 0;
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -581,13 +581,6 @@ static int __init numa_register_memblks(struct numa_meminfo *mi)
|
|||
if (start >= end)
|
||||
continue;
|
||||
|
||||
/*
|
||||
* Don't confuse VM with a node that doesn't have the
|
||||
* minimum amount of memory:
|
||||
*/
|
||||
if (end && (end - start) < NODE_MIN_SIZE)
|
||||
continue;
|
||||
|
||||
alloc_node_data(nid);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1374,6 +1374,7 @@ static void tg_conf_updated(struct throtl_grp *tg, bool global)
|
|||
tg_bps_limit(tg, READ), tg_bps_limit(tg, WRITE),
|
||||
tg_iops_limit(tg, READ), tg_iops_limit(tg, WRITE));
|
||||
|
||||
rcu_read_lock();
|
||||
/*
|
||||
* Update has_rules[] flags for the updated tg's subtree. A tg is
|
||||
* considered to have rules if either the tg itself or any of its
|
||||
|
|
@ -1401,6 +1402,7 @@ static void tg_conf_updated(struct throtl_grp *tg, bool global)
|
|||
this_tg->latency_target = max(this_tg->latency_target,
|
||||
parent_tg->latency_target);
|
||||
}
|
||||
rcu_read_unlock();
|
||||
|
||||
/*
|
||||
* We're already holding queue_lock and know @tg is valid. Let's
|
||||
|
|
|
|||
|
|
@ -118,6 +118,8 @@ static int pcrypt_aead_encrypt(struct aead_request *req)
|
|||
err = padata_do_parallel(ictx->psenc, padata, &ctx->cb_cpu);
|
||||
if (!err)
|
||||
return -EINPROGRESS;
|
||||
if (err == -EBUSY)
|
||||
return -EAGAIN;
|
||||
|
||||
return err;
|
||||
}
|
||||
|
|
@ -165,6 +167,8 @@ static int pcrypt_aead_decrypt(struct aead_request *req)
|
|||
err = padata_do_parallel(ictx->psdec, padata, &ctx->cb_cpu);
|
||||
if (!err)
|
||||
return -EINPROGRESS;
|
||||
if (err == -EBUSY)
|
||||
return -EAGAIN;
|
||||
|
||||
return err;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -503,7 +503,6 @@ static struct acpi_iort_node *iort_find_dev_node(struct device *dev)
|
|||
node = iort_get_iort_node(dev->fwnode);
|
||||
if (node)
|
||||
return node;
|
||||
|
||||
/*
|
||||
* if not, then it should be a platform device defined in
|
||||
* DSDT/SSDT (with Named Component node in IORT)
|
||||
|
|
@ -522,22 +521,22 @@ static struct acpi_iort_node *iort_find_dev_node(struct device *dev)
|
|||
}
|
||||
|
||||
/**
|
||||
* iort_msi_map_rid() - Map a MSI requester ID for a device
|
||||
* iort_msi_map_id() - Map a MSI input ID for a device
|
||||
* @dev: The device for which the mapping is to be done.
|
||||
* @req_id: The device requester ID.
|
||||
* @input_id: The device input ID.
|
||||
*
|
||||
* Returns: mapped MSI RID on success, input requester ID otherwise
|
||||
* Returns: mapped MSI ID on success, input ID otherwise
|
||||
*/
|
||||
u32 iort_msi_map_rid(struct device *dev, u32 req_id)
|
||||
u32 iort_msi_map_id(struct device *dev, u32 input_id)
|
||||
{
|
||||
struct acpi_iort_node *node;
|
||||
u32 dev_id;
|
||||
|
||||
node = iort_find_dev_node(dev);
|
||||
if (!node)
|
||||
return req_id;
|
||||
return input_id;
|
||||
|
||||
iort_node_map_id(node, req_id, &dev_id, IORT_MSI_TYPE);
|
||||
iort_node_map_id(node, input_id, &dev_id, IORT_MSI_TYPE);
|
||||
return dev_id;
|
||||
}
|
||||
|
||||
|
|
@ -594,13 +593,13 @@ static int __maybe_unused iort_find_its_base(u32 its_id, phys_addr_t *base)
|
|||
/**
|
||||
* iort_dev_find_its_id() - Find the ITS identifier for a device
|
||||
* @dev: The device.
|
||||
* @req_id: Device's requester ID
|
||||
* @id: Device's ID
|
||||
* @idx: Index of the ITS identifier list.
|
||||
* @its_id: ITS identifier.
|
||||
*
|
||||
* Returns: 0 on success, appropriate error value otherwise
|
||||
*/
|
||||
static int iort_dev_find_its_id(struct device *dev, u32 req_id,
|
||||
static int iort_dev_find_its_id(struct device *dev, u32 id,
|
||||
unsigned int idx, int *its_id)
|
||||
{
|
||||
struct acpi_iort_its_group *its;
|
||||
|
|
@ -610,7 +609,7 @@ static int iort_dev_find_its_id(struct device *dev, u32 req_id,
|
|||
if (!node)
|
||||
return -ENXIO;
|
||||
|
||||
node = iort_node_map_id(node, req_id, NULL, IORT_MSI_TYPE);
|
||||
node = iort_node_map_id(node, id, NULL, IORT_MSI_TYPE);
|
||||
if (!node)
|
||||
return -ENXIO;
|
||||
|
||||
|
|
@ -633,19 +632,20 @@ static int iort_dev_find_its_id(struct device *dev, u32 req_id,
|
|||
*
|
||||
* Returns: the MSI domain for this device, NULL otherwise
|
||||
*/
|
||||
struct irq_domain *iort_get_device_domain(struct device *dev, u32 req_id)
|
||||
struct irq_domain *iort_get_device_domain(struct device *dev, u32 id,
|
||||
enum irq_domain_bus_token bus_token)
|
||||
{
|
||||
struct fwnode_handle *handle;
|
||||
int its_id;
|
||||
|
||||
if (iort_dev_find_its_id(dev, req_id, 0, &its_id))
|
||||
if (iort_dev_find_its_id(dev, id, 0, &its_id))
|
||||
return NULL;
|
||||
|
||||
handle = iort_find_domain_token(its_id);
|
||||
if (!handle)
|
||||
return NULL;
|
||||
|
||||
return irq_find_matching_fwnode(handle, DOMAIN_BUS_PCI_MSI);
|
||||
return irq_find_matching_fwnode(handle, bus_token);
|
||||
}
|
||||
|
||||
static void iort_set_device_domain(struct device *dev,
|
||||
|
|
|
|||
|
|
@ -156,8 +156,8 @@ static int create_pnp_modalias(struct acpi_device *acpi_dev, char *modalias,
|
|||
return 0;
|
||||
|
||||
len = snprintf(modalias, size, "acpi:");
|
||||
if (len <= 0)
|
||||
return len;
|
||||
if (len >= size)
|
||||
return -ENOMEM;
|
||||
|
||||
size -= len;
|
||||
|
||||
|
|
@ -210,8 +210,10 @@ static int create_of_modalias(struct acpi_device *acpi_dev, char *modalias,
|
|||
len = snprintf(modalias, size, "of:N%sT", (char *)buf.pointer);
|
||||
ACPI_FREE(buf.pointer);
|
||||
|
||||
if (len <= 0)
|
||||
return len;
|
||||
if (len >= size)
|
||||
return -ENOMEM;
|
||||
|
||||
size -= len;
|
||||
|
||||
of_compatible = acpi_dev->data.of_compatible;
|
||||
if (of_compatible->type == ACPI_TYPE_PACKAGE) {
|
||||
|
|
|
|||
|
|
@ -442,6 +442,25 @@ static const struct dmi_system_id asus_laptop[] = {
|
|||
DMI_MATCH(DMI_BOARD_NAME, "B2402CBA"),
|
||||
},
|
||||
},
|
||||
{
|
||||
/* TongFang GMxXGxx/TUXEDO Polaris 15 Gen5 AMD */
|
||||
.matches = {
|
||||
DMI_MATCH(DMI_BOARD_NAME, "GMxXGxx"),
|
||||
},
|
||||
},
|
||||
{
|
||||
/* Asus ExpertBook B1402CVA */
|
||||
.matches = {
|
||||
DMI_MATCH(DMI_SYS_VENDOR, "ASUSTeK COMPUTER INC."),
|
||||
DMI_MATCH(DMI_BOARD_NAME, "B1402CVA"),
|
||||
},
|
||||
},
|
||||
{
|
||||
/* TongFang GM6XGxX/TUXEDO Stellaris 16 Gen5 AMD */
|
||||
.matches = {
|
||||
DMI_MATCH(DMI_BOARD_NAME, "GM6XGxX"),
|
||||
},
|
||||
},
|
||||
{
|
||||
.ident = "Asus ExpertBook B2502",
|
||||
.matches = {
|
||||
|
|
|
|||
|
|
@ -24,6 +24,7 @@
|
|||
#include <linux/libata.h>
|
||||
#include <linux/phy/phy.h>
|
||||
#include <linux/regulator/consumer.h>
|
||||
#include <linux/bits.h>
|
||||
|
||||
/* Enclosure Management Control */
|
||||
#define EM_CTRL_MSG_TYPE 0x000f0000
|
||||
|
|
@ -54,12 +55,12 @@ enum {
|
|||
AHCI_PORT_PRIV_FBS_DMA_SZ = AHCI_CMD_SLOT_SZ +
|
||||
AHCI_CMD_TBL_AR_SZ +
|
||||
(AHCI_RX_FIS_SZ * 16),
|
||||
AHCI_IRQ_ON_SG = (1 << 31),
|
||||
AHCI_CMD_ATAPI = (1 << 5),
|
||||
AHCI_CMD_WRITE = (1 << 6),
|
||||
AHCI_CMD_PREFETCH = (1 << 7),
|
||||
AHCI_CMD_RESET = (1 << 8),
|
||||
AHCI_CMD_CLR_BUSY = (1 << 10),
|
||||
AHCI_IRQ_ON_SG = BIT(31),
|
||||
AHCI_CMD_ATAPI = BIT(5),
|
||||
AHCI_CMD_WRITE = BIT(6),
|
||||
AHCI_CMD_PREFETCH = BIT(7),
|
||||
AHCI_CMD_RESET = BIT(8),
|
||||
AHCI_CMD_CLR_BUSY = BIT(10),
|
||||
|
||||
RX_FIS_PIO_SETUP = 0x20, /* offset of PIO Setup FIS data */
|
||||
RX_FIS_D2H_REG = 0x40, /* offset of D2H Register FIS data */
|
||||
|
|
@ -77,37 +78,37 @@ enum {
|
|||
HOST_CAP2 = 0x24, /* host capabilities, extended */
|
||||
|
||||
/* HOST_CTL bits */
|
||||
HOST_RESET = (1 << 0), /* reset controller; self-clear */
|
||||
HOST_IRQ_EN = (1 << 1), /* global IRQ enable */
|
||||
HOST_MRSM = (1 << 2), /* MSI Revert to Single Message */
|
||||
HOST_AHCI_EN = (1 << 31), /* AHCI enabled */
|
||||
HOST_RESET = BIT(0), /* reset controller; self-clear */
|
||||
HOST_IRQ_EN = BIT(1), /* global IRQ enable */
|
||||
HOST_MRSM = BIT(2), /* MSI Revert to Single Message */
|
||||
HOST_AHCI_EN = BIT(31), /* AHCI enabled */
|
||||
|
||||
/* HOST_CAP bits */
|
||||
HOST_CAP_SXS = (1 << 5), /* Supports External SATA */
|
||||
HOST_CAP_EMS = (1 << 6), /* Enclosure Management support */
|
||||
HOST_CAP_CCC = (1 << 7), /* Command Completion Coalescing */
|
||||
HOST_CAP_PART = (1 << 13), /* Partial state capable */
|
||||
HOST_CAP_SSC = (1 << 14), /* Slumber state capable */
|
||||
HOST_CAP_PIO_MULTI = (1 << 15), /* PIO multiple DRQ support */
|
||||
HOST_CAP_FBS = (1 << 16), /* FIS-based switching support */
|
||||
HOST_CAP_PMP = (1 << 17), /* Port Multiplier support */
|
||||
HOST_CAP_ONLY = (1 << 18), /* Supports AHCI mode only */
|
||||
HOST_CAP_CLO = (1 << 24), /* Command List Override support */
|
||||
HOST_CAP_LED = (1 << 25), /* Supports activity LED */
|
||||
HOST_CAP_ALPM = (1 << 26), /* Aggressive Link PM support */
|
||||
HOST_CAP_SSS = (1 << 27), /* Staggered Spin-up */
|
||||
HOST_CAP_MPS = (1 << 28), /* Mechanical presence switch */
|
||||
HOST_CAP_SNTF = (1 << 29), /* SNotification register */
|
||||
HOST_CAP_NCQ = (1 << 30), /* Native Command Queueing */
|
||||
HOST_CAP_64 = (1 << 31), /* PCI DAC (64-bit DMA) support */
|
||||
HOST_CAP_SXS = BIT(5), /* Supports External SATA */
|
||||
HOST_CAP_EMS = BIT(6), /* Enclosure Management support */
|
||||
HOST_CAP_CCC = BIT(7), /* Command Completion Coalescing */
|
||||
HOST_CAP_PART = BIT(13), /* Partial state capable */
|
||||
HOST_CAP_SSC = BIT(14), /* Slumber state capable */
|
||||
HOST_CAP_PIO_MULTI = BIT(15), /* PIO multiple DRQ support */
|
||||
HOST_CAP_FBS = BIT(16), /* FIS-based switching support */
|
||||
HOST_CAP_PMP = BIT(17), /* Port Multiplier support */
|
||||
HOST_CAP_ONLY = BIT(18), /* Supports AHCI mode only */
|
||||
HOST_CAP_CLO = BIT(24), /* Command List Override support */
|
||||
HOST_CAP_LED = BIT(25), /* Supports activity LED */
|
||||
HOST_CAP_ALPM = BIT(26), /* Aggressive Link PM support */
|
||||
HOST_CAP_SSS = BIT(27), /* Staggered Spin-up */
|
||||
HOST_CAP_MPS = BIT(28), /* Mechanical presence switch */
|
||||
HOST_CAP_SNTF = BIT(29), /* SNotification register */
|
||||
HOST_CAP_NCQ = BIT(30), /* Native Command Queueing */
|
||||
HOST_CAP_64 = BIT(31), /* PCI DAC (64-bit DMA) support */
|
||||
|
||||
/* HOST_CAP2 bits */
|
||||
HOST_CAP2_BOH = (1 << 0), /* BIOS/OS handoff supported */
|
||||
HOST_CAP2_NVMHCI = (1 << 1), /* NVMHCI supported */
|
||||
HOST_CAP2_APST = (1 << 2), /* Automatic partial to slumber */
|
||||
HOST_CAP2_SDS = (1 << 3), /* Support device sleep */
|
||||
HOST_CAP2_SADM = (1 << 4), /* Support aggressive DevSlp */
|
||||
HOST_CAP2_DESO = (1 << 5), /* DevSlp from slumber only */
|
||||
HOST_CAP2_BOH = BIT(0), /* BIOS/OS handoff supported */
|
||||
HOST_CAP2_NVMHCI = BIT(1), /* NVMHCI supported */
|
||||
HOST_CAP2_APST = BIT(2), /* Automatic partial to slumber */
|
||||
HOST_CAP2_SDS = BIT(3), /* Support device sleep */
|
||||
HOST_CAP2_SADM = BIT(4), /* Support aggressive DevSlp */
|
||||
HOST_CAP2_DESO = BIT(5), /* DevSlp from slumber only */
|
||||
|
||||
/* registers for each SATA port */
|
||||
PORT_LST_ADDR = 0x00, /* command list DMA addr */
|
||||
|
|
@ -129,24 +130,24 @@ enum {
|
|||
PORT_DEVSLP = 0x44, /* device sleep */
|
||||
|
||||
/* PORT_IRQ_{STAT,MASK} bits */
|
||||
PORT_IRQ_COLD_PRES = (1 << 31), /* cold presence detect */
|
||||
PORT_IRQ_TF_ERR = (1 << 30), /* task file error */
|
||||
PORT_IRQ_HBUS_ERR = (1 << 29), /* host bus fatal error */
|
||||
PORT_IRQ_HBUS_DATA_ERR = (1 << 28), /* host bus data error */
|
||||
PORT_IRQ_IF_ERR = (1 << 27), /* interface fatal error */
|
||||
PORT_IRQ_IF_NONFATAL = (1 << 26), /* interface non-fatal error */
|
||||
PORT_IRQ_OVERFLOW = (1 << 24), /* xfer exhausted available S/G */
|
||||
PORT_IRQ_BAD_PMP = (1 << 23), /* incorrect port multiplier */
|
||||
PORT_IRQ_COLD_PRES = BIT(31), /* cold presence detect */
|
||||
PORT_IRQ_TF_ERR = BIT(30), /* task file error */
|
||||
PORT_IRQ_HBUS_ERR = BIT(29), /* host bus fatal error */
|
||||
PORT_IRQ_HBUS_DATA_ERR = BIT(28), /* host bus data error */
|
||||
PORT_IRQ_IF_ERR = BIT(27), /* interface fatal error */
|
||||
PORT_IRQ_IF_NONFATAL = BIT(26), /* interface non-fatal error */
|
||||
PORT_IRQ_OVERFLOW = BIT(24), /* xfer exhausted available S/G */
|
||||
PORT_IRQ_BAD_PMP = BIT(23), /* incorrect port multiplier */
|
||||
|
||||
PORT_IRQ_PHYRDY = (1 << 22), /* PhyRdy changed */
|
||||
PORT_IRQ_DEV_ILCK = (1 << 7), /* device interlock */
|
||||
PORT_IRQ_CONNECT = (1 << 6), /* port connect change status */
|
||||
PORT_IRQ_SG_DONE = (1 << 5), /* descriptor processed */
|
||||
PORT_IRQ_UNK_FIS = (1 << 4), /* unknown FIS rx'd */
|
||||
PORT_IRQ_SDB_FIS = (1 << 3), /* Set Device Bits FIS rx'd */
|
||||
PORT_IRQ_DMAS_FIS = (1 << 2), /* DMA Setup FIS rx'd */
|
||||
PORT_IRQ_PIOS_FIS = (1 << 1), /* PIO Setup FIS rx'd */
|
||||
PORT_IRQ_D2H_REG_FIS = (1 << 0), /* D2H Register FIS rx'd */
|
||||
PORT_IRQ_PHYRDY = BIT(22), /* PhyRdy changed */
|
||||
PORT_IRQ_DEV_ILCK = BIT(7), /* device interlock */
|
||||
PORT_IRQ_CONNECT = BIT(6), /* port connect change status */
|
||||
PORT_IRQ_SG_DONE = BIT(5), /* descriptor processed */
|
||||
PORT_IRQ_UNK_FIS = BIT(4), /* unknown FIS rx'd */
|
||||
PORT_IRQ_SDB_FIS = BIT(3), /* Set Device Bits FIS rx'd */
|
||||
PORT_IRQ_DMAS_FIS = BIT(2), /* DMA Setup FIS rx'd */
|
||||
PORT_IRQ_PIOS_FIS = BIT(1), /* PIO Setup FIS rx'd */
|
||||
PORT_IRQ_D2H_REG_FIS = BIT(0), /* D2H Register FIS rx'd */
|
||||
|
||||
PORT_IRQ_FREEZE = PORT_IRQ_HBUS_ERR |
|
||||
PORT_IRQ_IF_ERR |
|
||||
|
|
@ -162,34 +163,34 @@ enum {
|
|||
PORT_IRQ_PIOS_FIS | PORT_IRQ_D2H_REG_FIS,
|
||||
|
||||
/* PORT_CMD bits */
|
||||
PORT_CMD_ASP = (1 << 27), /* Aggressive Slumber/Partial */
|
||||
PORT_CMD_ALPE = (1 << 26), /* Aggressive Link PM enable */
|
||||
PORT_CMD_ATAPI = (1 << 24), /* Device is ATAPI */
|
||||
PORT_CMD_FBSCP = (1 << 22), /* FBS Capable Port */
|
||||
PORT_CMD_ESP = (1 << 21), /* External Sata Port */
|
||||
PORT_CMD_HPCP = (1 << 18), /* HotPlug Capable Port */
|
||||
PORT_CMD_PMP = (1 << 17), /* PMP attached */
|
||||
PORT_CMD_LIST_ON = (1 << 15), /* cmd list DMA engine running */
|
||||
PORT_CMD_FIS_ON = (1 << 14), /* FIS DMA engine running */
|
||||
PORT_CMD_FIS_RX = (1 << 4), /* Enable FIS receive DMA engine */
|
||||
PORT_CMD_CLO = (1 << 3), /* Command list override */
|
||||
PORT_CMD_POWER_ON = (1 << 2), /* Power up device */
|
||||
PORT_CMD_SPIN_UP = (1 << 1), /* Spin up device */
|
||||
PORT_CMD_START = (1 << 0), /* Enable port DMA engine */
|
||||
PORT_CMD_ASP = BIT(27), /* Aggressive Slumber/Partial */
|
||||
PORT_CMD_ALPE = BIT(26), /* Aggressive Link PM enable */
|
||||
PORT_CMD_ATAPI = BIT(24), /* Device is ATAPI */
|
||||
PORT_CMD_FBSCP = BIT(22), /* FBS Capable Port */
|
||||
PORT_CMD_ESP = BIT(21), /* External Sata Port */
|
||||
PORT_CMD_HPCP = BIT(18), /* HotPlug Capable Port */
|
||||
PORT_CMD_PMP = BIT(17), /* PMP attached */
|
||||
PORT_CMD_LIST_ON = BIT(15), /* cmd list DMA engine running */
|
||||
PORT_CMD_FIS_ON = BIT(14), /* FIS DMA engine running */
|
||||
PORT_CMD_FIS_RX = BIT(4), /* Enable FIS receive DMA engine */
|
||||
PORT_CMD_CLO = BIT(3), /* Command list override */
|
||||
PORT_CMD_POWER_ON = BIT(2), /* Power up device */
|
||||
PORT_CMD_SPIN_UP = BIT(1), /* Spin up device */
|
||||
PORT_CMD_START = BIT(0), /* Enable port DMA engine */
|
||||
|
||||
PORT_CMD_ICC_MASK = (0xf << 28), /* i/f ICC state mask */
|
||||
PORT_CMD_ICC_ACTIVE = (0x1 << 28), /* Put i/f in active state */
|
||||
PORT_CMD_ICC_PARTIAL = (0x2 << 28), /* Put i/f in partial state */
|
||||
PORT_CMD_ICC_SLUMBER = (0x6 << 28), /* Put i/f in slumber state */
|
||||
PORT_CMD_ICC_MASK = (0xfu << 28), /* i/f ICC state mask */
|
||||
PORT_CMD_ICC_ACTIVE = (0x1u << 28), /* Put i/f in active state */
|
||||
PORT_CMD_ICC_PARTIAL = (0x2u << 28), /* Put i/f in partial state */
|
||||
PORT_CMD_ICC_SLUMBER = (0x6u << 28), /* Put i/f in slumber state */
|
||||
|
||||
/* PORT_FBS bits */
|
||||
PORT_FBS_DWE_OFFSET = 16, /* FBS device with error offset */
|
||||
PORT_FBS_ADO_OFFSET = 12, /* FBS active dev optimization offset */
|
||||
PORT_FBS_DEV_OFFSET = 8, /* FBS device to issue offset */
|
||||
PORT_FBS_DEV_MASK = (0xf << PORT_FBS_DEV_OFFSET), /* FBS.DEV */
|
||||
PORT_FBS_SDE = (1 << 2), /* FBS single device error */
|
||||
PORT_FBS_DEC = (1 << 1), /* FBS device error clear */
|
||||
PORT_FBS_EN = (1 << 0), /* Enable FBS */
|
||||
PORT_FBS_SDE = BIT(2), /* FBS single device error */
|
||||
PORT_FBS_DEC = BIT(1), /* FBS device error clear */
|
||||
PORT_FBS_EN = BIT(0), /* Enable FBS */
|
||||
|
||||
/* PORT_DEVSLP bits */
|
||||
PORT_DEVSLP_DM_OFFSET = 25, /* DITO multiplier offset */
|
||||
|
|
@ -197,52 +198,52 @@ enum {
|
|||
PORT_DEVSLP_DITO_OFFSET = 15, /* DITO offset */
|
||||
PORT_DEVSLP_MDAT_OFFSET = 10, /* Minimum assertion time */
|
||||
PORT_DEVSLP_DETO_OFFSET = 2, /* DevSlp exit timeout */
|
||||
PORT_DEVSLP_DSP = (1 << 1), /* DevSlp present */
|
||||
PORT_DEVSLP_ADSE = (1 << 0), /* Aggressive DevSlp enable */
|
||||
PORT_DEVSLP_DSP = BIT(1), /* DevSlp present */
|
||||
PORT_DEVSLP_ADSE = BIT(0), /* Aggressive DevSlp enable */
|
||||
|
||||
/* hpriv->flags bits */
|
||||
|
||||
#define AHCI_HFLAGS(flags) .private_data = (void *)(flags)
|
||||
|
||||
AHCI_HFLAG_NO_NCQ = (1 << 0),
|
||||
AHCI_HFLAG_IGN_IRQ_IF_ERR = (1 << 1), /* ignore IRQ_IF_ERR */
|
||||
AHCI_HFLAG_IGN_SERR_INTERNAL = (1 << 2), /* ignore SERR_INTERNAL */
|
||||
AHCI_HFLAG_32BIT_ONLY = (1 << 3), /* force 32bit */
|
||||
AHCI_HFLAG_MV_PATA = (1 << 4), /* PATA port */
|
||||
AHCI_HFLAG_NO_MSI = (1 << 5), /* no PCI MSI */
|
||||
AHCI_HFLAG_NO_PMP = (1 << 6), /* no PMP */
|
||||
AHCI_HFLAG_SECT255 = (1 << 8), /* max 255 sectors */
|
||||
AHCI_HFLAG_YES_NCQ = (1 << 9), /* force NCQ cap on */
|
||||
AHCI_HFLAG_NO_SUSPEND = (1 << 10), /* don't suspend */
|
||||
AHCI_HFLAG_SRST_TOUT_IS_OFFLINE = (1 << 11), /* treat SRST timeout as
|
||||
link offline */
|
||||
AHCI_HFLAG_NO_SNTF = (1 << 12), /* no sntf */
|
||||
AHCI_HFLAG_NO_FPDMA_AA = (1 << 13), /* no FPDMA AA */
|
||||
AHCI_HFLAG_YES_FBS = (1 << 14), /* force FBS cap on */
|
||||
AHCI_HFLAG_DELAY_ENGINE = (1 << 15), /* do not start engine on
|
||||
port start (wait until
|
||||
error-handling stage) */
|
||||
AHCI_HFLAG_NO_DEVSLP = (1 << 17), /* no device sleep */
|
||||
AHCI_HFLAG_NO_FBS = (1 << 18), /* no FBS */
|
||||
AHCI_HFLAG_NO_NCQ = BIT(0),
|
||||
AHCI_HFLAG_IGN_IRQ_IF_ERR = BIT(1), /* ignore IRQ_IF_ERR */
|
||||
AHCI_HFLAG_IGN_SERR_INTERNAL = BIT(2), /* ignore SERR_INTERNAL */
|
||||
AHCI_HFLAG_32BIT_ONLY = BIT(3), /* force 32bit */
|
||||
AHCI_HFLAG_MV_PATA = BIT(4), /* PATA port */
|
||||
AHCI_HFLAG_NO_MSI = BIT(5), /* no PCI MSI */
|
||||
AHCI_HFLAG_NO_PMP = BIT(6), /* no PMP */
|
||||
AHCI_HFLAG_SECT255 = BIT(8), /* max 255 sectors */
|
||||
AHCI_HFLAG_YES_NCQ = BIT(9), /* force NCQ cap on */
|
||||
AHCI_HFLAG_NO_SUSPEND = BIT(10), /* don't suspend */
|
||||
AHCI_HFLAG_SRST_TOUT_IS_OFFLINE = BIT(11), /* treat SRST timeout as
|
||||
link offline */
|
||||
AHCI_HFLAG_NO_SNTF = BIT(12), /* no sntf */
|
||||
AHCI_HFLAG_NO_FPDMA_AA = BIT(13), /* no FPDMA AA */
|
||||
AHCI_HFLAG_YES_FBS = BIT(14), /* force FBS cap on */
|
||||
AHCI_HFLAG_DELAY_ENGINE = BIT(15), /* do not start engine on
|
||||
port start (wait until
|
||||
error-handling stage) */
|
||||
AHCI_HFLAG_NO_DEVSLP = BIT(17), /* no device sleep */
|
||||
AHCI_HFLAG_NO_FBS = BIT(18), /* no FBS */
|
||||
|
||||
#ifdef CONFIG_PCI_MSI
|
||||
AHCI_HFLAG_MULTI_MSI = (1 << 20), /* per-port MSI(-X) */
|
||||
AHCI_HFLAG_MULTI_MSI = BIT(20), /* per-port MSI(-X) */
|
||||
#else
|
||||
/* compile out MSI infrastructure */
|
||||
AHCI_HFLAG_MULTI_MSI = 0,
|
||||
#endif
|
||||
AHCI_HFLAG_WAKE_BEFORE_STOP = (1 << 22), /* wake before DMA stop */
|
||||
AHCI_HFLAG_YES_ALPM = (1 << 23), /* force ALPM cap on */
|
||||
AHCI_HFLAG_NO_WRITE_TO_RO = (1 << 24), /* don't write to read
|
||||
only registers */
|
||||
AHCI_HFLAG_IS_MOBILE = (1 << 25), /* mobile chipset, use
|
||||
SATA_MOBILE_LPM_POLICY
|
||||
as default lpm_policy */
|
||||
AHCI_HFLAG_SUSPEND_PHYS = (1 << 26), /* handle PHYs during
|
||||
suspend/resume */
|
||||
AHCI_HFLAG_IGN_NOTSUPP_POWER_ON = (1 << 27), /* ignore -EOPNOTSUPP
|
||||
from phy_power_on() */
|
||||
AHCI_HFLAG_NO_SXS = (1 << 28), /* SXS not supported */
|
||||
AHCI_HFLAG_WAKE_BEFORE_STOP = BIT(22), /* wake before DMA stop */
|
||||
AHCI_HFLAG_YES_ALPM = BIT(23), /* force ALPM cap on */
|
||||
AHCI_HFLAG_NO_WRITE_TO_RO = BIT(24), /* don't write to read
|
||||
only registers */
|
||||
AHCI_HFLAG_IS_MOBILE = BIT(25), /* mobile chipset, use
|
||||
SATA_MOBILE_LPM_POLICY
|
||||
as default lpm_policy */
|
||||
AHCI_HFLAG_SUSPEND_PHYS = BIT(26), /* handle PHYs during
|
||||
suspend/resume */
|
||||
AHCI_HFLAG_IGN_NOTSUPP_POWER_ON = BIT(27), /* ignore -EOPNOTSUPP
|
||||
from phy_power_on() */
|
||||
AHCI_HFLAG_NO_SXS = BIT(28), /* SXS not supported */
|
||||
|
||||
/* ap->flags bits */
|
||||
|
||||
|
|
@ -258,22 +259,22 @@ enum {
|
|||
EM_MAX_RETRY = 5,
|
||||
|
||||
/* em_ctl bits */
|
||||
EM_CTL_RST = (1 << 9), /* Reset */
|
||||
EM_CTL_TM = (1 << 8), /* Transmit Message */
|
||||
EM_CTL_MR = (1 << 0), /* Message Received */
|
||||
EM_CTL_ALHD = (1 << 26), /* Activity LED */
|
||||
EM_CTL_XMT = (1 << 25), /* Transmit Only */
|
||||
EM_CTL_SMB = (1 << 24), /* Single Message Buffer */
|
||||
EM_CTL_SGPIO = (1 << 19), /* SGPIO messages supported */
|
||||
EM_CTL_SES = (1 << 18), /* SES-2 messages supported */
|
||||
EM_CTL_SAFTE = (1 << 17), /* SAF-TE messages supported */
|
||||
EM_CTL_LED = (1 << 16), /* LED messages supported */
|
||||
EM_CTL_RST = BIT(9), /* Reset */
|
||||
EM_CTL_TM = BIT(8), /* Transmit Message */
|
||||
EM_CTL_MR = BIT(0), /* Message Received */
|
||||
EM_CTL_ALHD = BIT(26), /* Activity LED */
|
||||
EM_CTL_XMT = BIT(25), /* Transmit Only */
|
||||
EM_CTL_SMB = BIT(24), /* Single Message Buffer */
|
||||
EM_CTL_SGPIO = BIT(19), /* SGPIO messages supported */
|
||||
EM_CTL_SES = BIT(18), /* SES-2 messages supported */
|
||||
EM_CTL_SAFTE = BIT(17), /* SAF-TE messages supported */
|
||||
EM_CTL_LED = BIT(16), /* LED messages supported */
|
||||
|
||||
/* em message type */
|
||||
EM_MSG_TYPE_LED = (1 << 0), /* LED */
|
||||
EM_MSG_TYPE_SAFTE = (1 << 1), /* SAF-TE */
|
||||
EM_MSG_TYPE_SES2 = (1 << 2), /* SES-2 */
|
||||
EM_MSG_TYPE_SGPIO = (1 << 3), /* SGPIO */
|
||||
EM_MSG_TYPE_LED = BIT(0), /* LED */
|
||||
EM_MSG_TYPE_SAFTE = BIT(1), /* SAF-TE */
|
||||
EM_MSG_TYPE_SES2 = BIT(2), /* SES-2 */
|
||||
EM_MSG_TYPE_SGPIO = BIT(3), /* SGPIO */
|
||||
};
|
||||
|
||||
struct ahci_cmd_hdr {
|
||||
|
|
|
|||
|
|
@ -82,6 +82,9 @@ static int isapnp_init_one(struct pnp_dev *idev, const struct pnp_device_id *dev
|
|||
if (pnp_port_valid(idev, 1)) {
|
||||
ctl_addr = devm_ioport_map(&idev->dev,
|
||||
pnp_port_start(idev, 1), 1);
|
||||
if (!ctl_addr)
|
||||
return -ENOMEM;
|
||||
|
||||
ap->ioaddr.altstatus_addr = ctl_addr;
|
||||
ap->ioaddr.ctl_addr = ctl_addr;
|
||||
ap->ops = &isapnp_port_ops;
|
||||
|
|
|
|||
|
|
@ -2290,19 +2290,21 @@ static int get_esi(struct atm_dev *dev)
|
|||
static int reset_sar(struct atm_dev *dev)
|
||||
{
|
||||
IADEV *iadev;
|
||||
int i, error = 1;
|
||||
int i, error;
|
||||
unsigned int pci[64];
|
||||
|
||||
iadev = INPH_IA_DEV(dev);
|
||||
for(i=0; i<64; i++)
|
||||
if ((error = pci_read_config_dword(iadev->pci,
|
||||
i*4, &pci[i])) != PCIBIOS_SUCCESSFUL)
|
||||
return error;
|
||||
for (i = 0; i < 64; i++) {
|
||||
error = pci_read_config_dword(iadev->pci, i * 4, &pci[i]);
|
||||
if (error != PCIBIOS_SUCCESSFUL)
|
||||
return error;
|
||||
}
|
||||
writel(0, iadev->reg+IPHASE5575_EXT_RESET);
|
||||
for(i=0; i<64; i++)
|
||||
if ((error = pci_write_config_dword(iadev->pci,
|
||||
i*4, pci[i])) != PCIBIOS_SUCCESSFUL)
|
||||
return error;
|
||||
for (i = 0; i < 64; i++) {
|
||||
error = pci_write_config_dword(iadev->pci, i * 4, pci[i]);
|
||||
if (error != PCIBIOS_SUCCESSFUL)
|
||||
return error;
|
||||
}
|
||||
udelay(5);
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -449,9 +449,9 @@ static ssize_t console_show(struct device *dev, struct device_attribute *attr,
|
|||
struct sk_buff *skb;
|
||||
unsigned int len;
|
||||
|
||||
spin_lock(&card->cli_queue_lock);
|
||||
spin_lock_bh(&card->cli_queue_lock);
|
||||
skb = skb_dequeue(&card->cli_queue[SOLOS_CHAN(atmdev)]);
|
||||
spin_unlock(&card->cli_queue_lock);
|
||||
spin_unlock_bh(&card->cli_queue_lock);
|
||||
if(skb == NULL)
|
||||
return sprintf(buf, "No data.\n");
|
||||
|
||||
|
|
@ -956,14 +956,14 @@ static void pclose(struct atm_vcc *vcc)
|
|||
struct pkt_hdr *header;
|
||||
|
||||
/* Remove any yet-to-be-transmitted packets from the pending queue */
|
||||
spin_lock(&card->tx_queue_lock);
|
||||
spin_lock_bh(&card->tx_queue_lock);
|
||||
skb_queue_walk_safe(&card->tx_queue[port], skb, tmpskb) {
|
||||
if (SKB_CB(skb)->vcc == vcc) {
|
||||
skb_unlink(skb, &card->tx_queue[port]);
|
||||
solos_pop(vcc, skb);
|
||||
}
|
||||
}
|
||||
spin_unlock(&card->tx_queue_lock);
|
||||
spin_unlock_bh(&card->tx_queue_lock);
|
||||
|
||||
skb = alloc_skb(sizeof(*header), GFP_KERNEL);
|
||||
if (!skb) {
|
||||
|
|
|
|||
|
|
@ -1188,8 +1188,6 @@ static void __device_release_driver(struct device *dev, struct device *parent)
|
|||
else if (drv->remove)
|
||||
drv->remove(dev);
|
||||
|
||||
device_links_driver_cleanup(dev);
|
||||
|
||||
devres_release_all(dev);
|
||||
arch_teardown_dma_ops(dev);
|
||||
dev->driver = NULL;
|
||||
|
|
@ -1199,6 +1197,8 @@ static void __device_release_driver(struct device *dev, struct device *parent)
|
|||
pm_runtime_reinit(dev);
|
||||
dev_pm_set_driver_flags(dev, 0);
|
||||
|
||||
device_links_driver_cleanup(dev);
|
||||
|
||||
klist_remove(&dev->p->knode_driver);
|
||||
device_pm_check_callbacks(dev);
|
||||
if (dev->bus)
|
||||
|
|
|
|||
|
|
@ -29,6 +29,47 @@ struct devcd_entry {
|
|||
struct device devcd_dev;
|
||||
void *data;
|
||||
size_t datalen;
|
||||
/*
|
||||
* Here, mutex is required to serialize the calls to del_wk work between
|
||||
* user/kernel space which happens when devcd is added with device_add()
|
||||
* and that sends uevent to user space. User space reads the uevents,
|
||||
* and calls to devcd_data_write() which try to modify the work which is
|
||||
* not even initialized/queued from devcoredump.
|
||||
*
|
||||
*
|
||||
*
|
||||
* cpu0(X) cpu1(Y)
|
||||
*
|
||||
* dev_coredump() uevent sent to user space
|
||||
* device_add() ======================> user space process Y reads the
|
||||
* uevents writes to devcd fd
|
||||
* which results into writes to
|
||||
*
|
||||
* devcd_data_write()
|
||||
* mod_delayed_work()
|
||||
* try_to_grab_pending()
|
||||
* del_timer()
|
||||
* debug_assert_init()
|
||||
* INIT_DELAYED_WORK()
|
||||
* schedule_delayed_work()
|
||||
*
|
||||
*
|
||||
* Also, mutex alone would not be enough to avoid scheduling of
|
||||
* del_wk work after it get flush from a call to devcd_free()
|
||||
* mentioned as below.
|
||||
*
|
||||
* disabled_store()
|
||||
* devcd_free()
|
||||
* mutex_lock() devcd_data_write()
|
||||
* flush_delayed_work()
|
||||
* mutex_unlock()
|
||||
* mutex_lock()
|
||||
* mod_delayed_work()
|
||||
* mutex_unlock()
|
||||
* So, delete_work flag is required.
|
||||
*/
|
||||
struct mutex mutex;
|
||||
bool delete_work;
|
||||
struct module *owner;
|
||||
ssize_t (*read)(char *buffer, loff_t offset, size_t count,
|
||||
void *data, size_t datalen);
|
||||
|
|
@ -88,7 +129,12 @@ static ssize_t devcd_data_write(struct file *filp, struct kobject *kobj,
|
|||
struct device *dev = kobj_to_dev(kobj);
|
||||
struct devcd_entry *devcd = dev_to_devcd(dev);
|
||||
|
||||
mod_delayed_work(system_wq, &devcd->del_wk, 0);
|
||||
mutex_lock(&devcd->mutex);
|
||||
if (!devcd->delete_work) {
|
||||
devcd->delete_work = true;
|
||||
mod_delayed_work(system_wq, &devcd->del_wk, 0);
|
||||
}
|
||||
mutex_unlock(&devcd->mutex);
|
||||
|
||||
return count;
|
||||
}
|
||||
|
|
@ -116,7 +162,12 @@ static int devcd_free(struct device *dev, void *data)
|
|||
{
|
||||
struct devcd_entry *devcd = dev_to_devcd(dev);
|
||||
|
||||
mutex_lock(&devcd->mutex);
|
||||
if (!devcd->delete_work)
|
||||
devcd->delete_work = true;
|
||||
|
||||
flush_delayed_work(&devcd->del_wk);
|
||||
mutex_unlock(&devcd->mutex);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -126,6 +177,30 @@ static ssize_t disabled_show(struct class *class, struct class_attribute *attr,
|
|||
return sprintf(buf, "%d\n", devcd_disabled);
|
||||
}
|
||||
|
||||
/*
|
||||
*
|
||||
* disabled_store() worker()
|
||||
* class_for_each_device(&devcd_class,
|
||||
* NULL, NULL, devcd_free)
|
||||
* ...
|
||||
* ...
|
||||
* while ((dev = class_dev_iter_next(&iter))
|
||||
* devcd_del()
|
||||
* device_del()
|
||||
* put_device() <- last reference
|
||||
* error = fn(dev, data) devcd_dev_release()
|
||||
* devcd_free(dev, data) kfree(devcd)
|
||||
* mutex_lock(&devcd->mutex);
|
||||
*
|
||||
*
|
||||
* In the above diagram, It looks like disabled_store() would be racing with parallely
|
||||
* running devcd_del() and result in memory abort while acquiring devcd->mutex which
|
||||
* is called after kfree of devcd memory after dropping its last reference with
|
||||
* put_device(). However, this will not happens as fn(dev, data) runs
|
||||
* with its own reference to device via klist_node so it is not its last reference.
|
||||
* so, above situation would not occur.
|
||||
*/
|
||||
|
||||
static ssize_t disabled_store(struct class *class, struct class_attribute *attr,
|
||||
const char *buf, size_t count)
|
||||
{
|
||||
|
|
@ -282,13 +357,17 @@ void dev_coredumpm(struct device *dev, struct module *owner,
|
|||
devcd->read = read;
|
||||
devcd->free = free;
|
||||
devcd->failing_dev = get_device(dev);
|
||||
devcd->delete_work = false;
|
||||
|
||||
mutex_init(&devcd->mutex);
|
||||
device_initialize(&devcd->devcd_dev);
|
||||
|
||||
dev_set_name(&devcd->devcd_dev, "devcd%d",
|
||||
atomic_inc_return(&devcd_count));
|
||||
devcd->devcd_dev.class = &devcd_class;
|
||||
|
||||
mutex_lock(&devcd->mutex);
|
||||
dev_set_uevent_suppress(&devcd->devcd_dev, true);
|
||||
if (device_add(&devcd->devcd_dev))
|
||||
goto put_device;
|
||||
|
||||
|
|
@ -300,12 +379,15 @@ void dev_coredumpm(struct device *dev, struct module *owner,
|
|||
"devcoredump"))
|
||||
/* nothing - symlink will be missing */;
|
||||
|
||||
dev_set_uevent_suppress(&devcd->devcd_dev, false);
|
||||
kobject_uevent(&devcd->devcd_dev.kobj, KOBJ_ADD);
|
||||
INIT_DELAYED_WORK(&devcd->del_wk, devcd_del);
|
||||
schedule_delayed_work(&devcd->del_wk, DEVCD_TIMEOUT);
|
||||
|
||||
mutex_unlock(&devcd->mutex);
|
||||
return;
|
||||
put_device:
|
||||
put_device(&devcd->devcd_dev);
|
||||
mutex_unlock(&devcd->mutex);
|
||||
put_module:
|
||||
module_put(owner);
|
||||
free:
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ static ssize_t regmap_name_read_file(struct file *file,
|
|||
name = map->dev->driver->name;
|
||||
|
||||
ret = snprintf(buf, PAGE_SIZE, "%s\n", name);
|
||||
if (ret < 0) {
|
||||
if (ret >= PAGE_SIZE) {
|
||||
kfree(buf);
|
||||
return ret;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1495,17 +1495,19 @@ static int _regmap_raw_write_impl(struct regmap *map, unsigned int reg,
|
|||
}
|
||||
|
||||
if (!map->cache_bypass && map->format.parse_val) {
|
||||
unsigned int ival;
|
||||
unsigned int ival, offset;
|
||||
int val_bytes = map->format.val_bytes;
|
||||
for (i = 0; i < val_len / val_bytes; i++) {
|
||||
ival = map->format.parse_val(val + (i * val_bytes));
|
||||
ret = regcache_write(map,
|
||||
reg + regmap_get_offset(map, i),
|
||||
ival);
|
||||
|
||||
/* Cache the last written value for noinc writes */
|
||||
i = noinc ? val_len - val_bytes : 0;
|
||||
for (; i < val_len; i += val_bytes) {
|
||||
ival = map->format.parse_val(val + i);
|
||||
offset = noinc ? 0 : regmap_get_offset(map, i / val_bytes);
|
||||
ret = regcache_write(map, reg + offset, ival);
|
||||
if (ret) {
|
||||
dev_err(map->dev,
|
||||
"Error in caching of register: %x ret: %d\n",
|
||||
reg + regmap_get_offset(map, i), ret);
|
||||
reg + offset, ret);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -299,15 +299,6 @@ config BLK_DEV_SKD
|
|||
|
||||
Use device /dev/skd$N amd /dev/skd$Np$M.
|
||||
|
||||
config BLK_DEV_SX8
|
||||
tristate "Promise SATA SX8 support"
|
||||
depends on PCI
|
||||
---help---
|
||||
Saying Y or M here will enable support for the
|
||||
Promise SATA SX8 controllers.
|
||||
|
||||
Use devices /dev/sx8/$N and /dev/sx8/$Np$M.
|
||||
|
||||
config BLK_DEV_RAM
|
||||
tristate "RAM block device support"
|
||||
---help---
|
||||
|
|
|
|||
|
|
@ -27,8 +27,6 @@ obj-$(CONFIG_BLK_DEV_CRYPTOLOOP) += cryptoloop.o
|
|||
obj-$(CONFIG_VIRTIO_BLK_QTI_CRYPTO) += virtio_blk_qti_crypto.o
|
||||
obj-$(CONFIG_VIRTIO_BLK) += virtio_blk.o
|
||||
|
||||
obj-$(CONFIG_BLK_DEV_SX8) += sx8.o
|
||||
|
||||
obj-$(CONFIG_XEN_BLKDEV_FRONTEND) += xen-blkfront.o
|
||||
obj-$(CONFIG_XEN_BLKDEV_BACKEND) += xen-blkback/
|
||||
obj-$(CONFIG_BLK_DEV_DRBD) += drbd/
|
||||
|
|
|
|||
1586
drivers/block/sx8.c
1586
drivers/block/sx8.c
File diff suppressed because it is too large
Load diff
|
|
@ -57,6 +57,7 @@ static struct usb_driver btusb_driver;
|
|||
#define BTUSB_IFNUM_2 0x80000
|
||||
#define BTUSB_CW6622 0x100000
|
||||
#define BTUSB_MEDIATEK 0x200000
|
||||
#define BTUSB_WIDEBAND_SPEECH 0x400000
|
||||
|
||||
static const struct usb_device_id btusb_table[] = {
|
||||
/* Generic Bluetooth USB device */
|
||||
|
|
@ -332,20 +333,42 @@ static const struct usb_device_id blacklist_table[] = {
|
|||
{ USB_DEVICE(0x1286, 0x204e), .driver_info = BTUSB_MARVELL },
|
||||
|
||||
/* Intel Bluetooth devices */
|
||||
{ USB_DEVICE(0x8087, 0x0025), .driver_info = BTUSB_INTEL_NEW },
|
||||
{ USB_DEVICE(0x8087, 0x0026), .driver_info = BTUSB_INTEL_NEW },
|
||||
{ USB_DEVICE(0x8087, 0x0029), .driver_info = BTUSB_INTEL_NEW },
|
||||
{ USB_DEVICE(0x8087, 0x0025), .driver_info = BTUSB_INTEL_NEW |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
{ USB_DEVICE(0x8087, 0x0026), .driver_info = BTUSB_INTEL_NEW |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
{ USB_DEVICE(0x8087, 0x0029), .driver_info = BTUSB_INTEL_NEW |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
{ USB_DEVICE(0x8087, 0x07da), .driver_info = BTUSB_CSR },
|
||||
{ USB_DEVICE(0x8087, 0x07dc), .driver_info = BTUSB_INTEL },
|
||||
{ USB_DEVICE(0x8087, 0x0a2a), .driver_info = BTUSB_INTEL },
|
||||
{ USB_DEVICE(0x8087, 0x0a2b), .driver_info = BTUSB_INTEL_NEW },
|
||||
{ USB_DEVICE(0x8087, 0x0aa7), .driver_info = BTUSB_INTEL },
|
||||
{ USB_DEVICE(0x8087, 0x0aaa), .driver_info = BTUSB_INTEL_NEW },
|
||||
{ USB_DEVICE(0x8087, 0x0a2b), .driver_info = BTUSB_INTEL_NEW |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
{ USB_DEVICE(0x8087, 0x0aa7), .driver_info = BTUSB_INTEL |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
{ USB_DEVICE(0x8087, 0x0aaa), .driver_info = BTUSB_INTEL_NEW |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
|
||||
/* Other Intel Bluetooth devices */
|
||||
{ USB_VENDOR_AND_INTERFACE_INFO(0x8087, 0xe0, 0x01, 0x01),
|
||||
.driver_info = BTUSB_IGNORE },
|
||||
|
||||
/* Realtek 8822CE Bluetooth devices */
|
||||
{ USB_DEVICE(0x0bda, 0xb00c), .driver_info = BTUSB_REALTEK |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
|
||||
/* Realtek 8852BE Bluetooth devices */
|
||||
{ USB_DEVICE(0x0cb8, 0xc559), .driver_info = BTUSB_REALTEK |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
{ USB_DEVICE(0x0bda, 0x887b), .driver_info = BTUSB_REALTEK |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
{ USB_DEVICE(0x0bda, 0xb85b), .driver_info = BTUSB_REALTEK |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
{ USB_DEVICE(0x13d3, 0x3570), .driver_info = BTUSB_REALTEK |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
{ USB_DEVICE(0x13d3, 0x3571), .driver_info = BTUSB_REALTEK |
|
||||
BTUSB_WIDEBAND_SPEECH },
|
||||
|
||||
/* Realtek Bluetooth devices */
|
||||
{ USB_VENDOR_AND_INTERFACE_INFO(0x0bda, 0xe0, 0x01, 0x01),
|
||||
.driver_info = BTUSB_REALTEK },
|
||||
|
|
|
|||
|
|
@ -58,7 +58,8 @@ struct amd_geode_priv {
|
|||
|
||||
static int geode_rng_data_read(struct hwrng *rng, u32 *data)
|
||||
{
|
||||
void __iomem *mem = (void __iomem *)rng->priv;
|
||||
struct amd_geode_priv *priv = (struct amd_geode_priv *)rng->priv;
|
||||
void __iomem *mem = priv->membase;
|
||||
|
||||
*data = readl(mem + GEODE_RNG_DATA_REG);
|
||||
|
||||
|
|
@ -67,7 +68,8 @@ static int geode_rng_data_read(struct hwrng *rng, u32 *data)
|
|||
|
||||
static int geode_rng_data_present(struct hwrng *rng, int wait)
|
||||
{
|
||||
void __iomem *mem = (void __iomem *)rng->priv;
|
||||
struct amd_geode_priv *priv = (struct amd_geode_priv *)rng->priv;
|
||||
void __iomem *mem = priv->membase;
|
||||
int data, i;
|
||||
|
||||
for (i = 0; i < 20; i++) {
|
||||
|
|
|
|||
|
|
@ -647,7 +647,7 @@ static void __init npcm7xx_clk_init(struct device_node *clk_np)
|
|||
return;
|
||||
|
||||
npcm7xx_init_fail:
|
||||
kfree(npcm7xx_clk_data->hws);
|
||||
kfree(npcm7xx_clk_data);
|
||||
npcm7xx_init_np_err:
|
||||
iounmap(clk_base);
|
||||
npcm7xx_init_error:
|
||||
|
|
|
|||
|
|
@ -170,6 +170,7 @@ static int scmi_clocks_probe(struct scmi_device *sdev)
|
|||
sclk->info = handle->clk_ops->info_get(handle, idx);
|
||||
if (!sclk->info) {
|
||||
dev_dbg(dev, "invalid clock info for idx %d\n", idx);
|
||||
devm_kfree(dev, sclk);
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -3159,6 +3159,7 @@ static void possible_parent_show(struct seq_file *s, struct clk_core *core,
|
|||
unsigned int i, char terminator)
|
||||
{
|
||||
struct clk_core *parent;
|
||||
const char *name = NULL;
|
||||
|
||||
/*
|
||||
* Go through the following options to fetch a parent's name.
|
||||
|
|
@ -3173,18 +3174,20 @@ static void possible_parent_show(struct seq_file *s, struct clk_core *core,
|
|||
* registered (yet).
|
||||
*/
|
||||
parent = clk_core_get_parent_by_index(core, i);
|
||||
if (parent)
|
||||
if (parent) {
|
||||
seq_puts(s, parent->name);
|
||||
else if (core->parents[i].name)
|
||||
} else if (core->parents[i].name) {
|
||||
seq_puts(s, core->parents[i].name);
|
||||
else if (core->parents[i].fw_name)
|
||||
} else if (core->parents[i].fw_name) {
|
||||
seq_printf(s, "<%s>(fw)", core->parents[i].fw_name);
|
||||
else if (core->parents[i].index >= 0)
|
||||
seq_puts(s,
|
||||
of_clk_get_parent_name(core->of_node,
|
||||
core->parents[i].index));
|
||||
else
|
||||
seq_puts(s, "(missing)");
|
||||
} else {
|
||||
if (core->parents[i].index >= 0)
|
||||
name = of_clk_get_parent_name(core->of_node, core->parents[i].index);
|
||||
if (!name)
|
||||
name = "(missing)";
|
||||
|
||||
seq_puts(s, name);
|
||||
}
|
||||
|
||||
seq_putc(s, terminator);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,5 +30,6 @@ config CLK_IMX8QXP
|
|||
bool "IMX8QXP SCU Clock"
|
||||
depends on ARCH_MXC && IMX_SCU && ARM64
|
||||
select MXC_CLK_SCU
|
||||
select MXC_CLK
|
||||
help
|
||||
Build the driver for IMX8QXP SCU based clocks.
|
||||
|
|
|
|||
|
|
@ -281,12 +281,13 @@ static void __init of_pll_div_clk_init(struct device_node *node)
|
|||
|
||||
clk = clk_register_divider(NULL, clk_name, parent_name, 0, reg, shift,
|
||||
mask, 0, NULL);
|
||||
if (clk) {
|
||||
of_clk_add_provider(node, of_clk_src_simple_get, clk);
|
||||
} else {
|
||||
if (IS_ERR(clk)) {
|
||||
pr_err("%s: error registering divider %s\n", __func__, clk_name);
|
||||
iounmap(reg);
|
||||
return;
|
||||
}
|
||||
|
||||
of_clk_add_provider(node, of_clk_src_simple_get, clk);
|
||||
}
|
||||
CLK_OF_DECLARE(pll_divider_clock, "ti,keystone,pll-divider-clock", of_pll_div_clk_init);
|
||||
|
||||
|
|
@ -328,10 +329,12 @@ static void __init of_pll_mux_clk_init(struct device_node *node)
|
|||
clk = clk_register_mux(NULL, clk_name, (const char **)&parents,
|
||||
ARRAY_SIZE(parents) , 0, reg, shift, mask,
|
||||
0, NULL);
|
||||
if (clk)
|
||||
of_clk_add_provider(node, of_clk_src_simple_get, clk);
|
||||
else
|
||||
if (IS_ERR(clk)) {
|
||||
pr_err("%s: error registering mux %s\n", __func__, clk_name);
|
||||
return;
|
||||
}
|
||||
|
||||
of_clk_add_provider(node, of_clk_src_simple_get, clk);
|
||||
}
|
||||
CLK_OF_DECLARE(pll_mux_clock, "ti,keystone,pll-mux-clock", of_pll_mux_clk_init);
|
||||
|
||||
|
|
|
|||
|
|
@ -675,6 +675,8 @@ static int mtk_topckgen_init(struct platform_device *pdev)
|
|||
return PTR_ERR(base);
|
||||
|
||||
clk_data = mtk_alloc_clk_data(CLK_TOP_NR);
|
||||
if (!clk_data)
|
||||
return -ENOMEM;
|
||||
|
||||
mtk_clk_register_fixed_clks(top_fixed_clks, ARRAY_SIZE(top_fixed_clks),
|
||||
clk_data);
|
||||
|
|
@ -742,6 +744,8 @@ static void __init mtk_infrasys_init_early(struct device_node *node)
|
|||
|
||||
if (!infra_clk_data) {
|
||||
infra_clk_data = mtk_alloc_clk_data(CLK_INFRA_NR);
|
||||
if (!infra_clk_data)
|
||||
return;
|
||||
|
||||
for (i = 0; i < CLK_INFRA_NR; i++)
|
||||
infra_clk_data->clks[i] = ERR_PTR(-EPROBE_DEFER);
|
||||
|
|
@ -768,6 +772,8 @@ static int mtk_infrasys_init(struct platform_device *pdev)
|
|||
|
||||
if (!infra_clk_data) {
|
||||
infra_clk_data = mtk_alloc_clk_data(CLK_INFRA_NR);
|
||||
if (!infra_clk_data)
|
||||
return -ENOMEM;
|
||||
} else {
|
||||
for (i = 0; i < CLK_INFRA_NR; i++) {
|
||||
if (infra_clk_data->clks[i] == ERR_PTR(-EPROBE_DEFER))
|
||||
|
|
@ -896,6 +902,8 @@ static int mtk_pericfg_init(struct platform_device *pdev)
|
|||
return PTR_ERR(base);
|
||||
|
||||
clk_data = mtk_alloc_clk_data(CLK_PERI_NR);
|
||||
if (!clk_data)
|
||||
return -ENOMEM;
|
||||
|
||||
mtk_clk_register_gates(node, peri_clks, ARRAY_SIZE(peri_clks),
|
||||
clk_data);
|
||||
|
|
|
|||
|
|
@ -1216,6 +1216,8 @@ static int clk_mt6779_apmixed_probe(struct platform_device *pdev)
|
|||
struct device_node *node = pdev->dev.of_node;
|
||||
|
||||
clk_data = mtk_alloc_clk_data(CLK_APMIXED_NR_CLK);
|
||||
if (!clk_data)
|
||||
return -ENOMEM;
|
||||
|
||||
mtk_clk_register_plls(node, plls, ARRAY_SIZE(plls), clk_data);
|
||||
|
||||
|
|
@ -1237,6 +1239,8 @@ static int clk_mt6779_top_probe(struct platform_device *pdev)
|
|||
return PTR_ERR(base);
|
||||
|
||||
clk_data = mtk_alloc_clk_data(CLK_TOP_NR_CLK);
|
||||
if (!clk_data)
|
||||
return -ENOMEM;
|
||||
|
||||
mtk_clk_register_fixed_clks(top_fixed_clks, ARRAY_SIZE(top_fixed_clks),
|
||||
clk_data);
|
||||
|
|
|
|||
|
|
@ -392,6 +392,8 @@ static int mtk_topckgen_init(struct platform_device *pdev)
|
|||
return PTR_ERR(base);
|
||||
|
||||
clk_data = mtk_alloc_clk_data(CLK_TOP_NR);
|
||||
if (!clk_data)
|
||||
return -ENOMEM;
|
||||
|
||||
mtk_clk_register_factors(top_fixed_divs, ARRAY_SIZE(top_fixed_divs),
|
||||
clk_data);
|
||||
|
|
@ -564,6 +566,8 @@ static void mtk_infrasys_init_early(struct device_node *node)
|
|||
|
||||
if (!infra_clk_data) {
|
||||
infra_clk_data = mtk_alloc_clk_data(CLK_INFRA_NR);
|
||||
if (!infra_clk_data)
|
||||
return;
|
||||
|
||||
for (i = 0; i < CLK_INFRA_NR; i++)
|
||||
infra_clk_data->clks[i] = ERR_PTR(-EPROBE_DEFER);
|
||||
|
|
@ -588,6 +592,8 @@ static int mtk_infrasys_init(struct platform_device *pdev)
|
|||
|
||||
if (!infra_clk_data) {
|
||||
infra_clk_data = mtk_alloc_clk_data(CLK_INFRA_NR);
|
||||
if (!infra_clk_data)
|
||||
return -ENOMEM;
|
||||
} else {
|
||||
for (i = 0; i < CLK_INFRA_NR; i++) {
|
||||
if (infra_clk_data->clks[i] == ERR_PTR(-EPROBE_DEFER))
|
||||
|
|
|
|||
|
|
@ -83,6 +83,8 @@ static int clk_mt7629_ethsys_init(struct platform_device *pdev)
|
|||
int r;
|
||||
|
||||
clk_data = mtk_alloc_clk_data(CLK_ETH_NR_CLK);
|
||||
if (!clk_data)
|
||||
return -ENOMEM;
|
||||
|
||||
mtk_clk_register_gates(node, eth_clks, CLK_ETH_NR_CLK, clk_data);
|
||||
|
||||
|
|
@ -105,6 +107,8 @@ static int clk_mt7629_sgmiisys_init(struct platform_device *pdev)
|
|||
int r;
|
||||
|
||||
clk_data = mtk_alloc_clk_data(CLK_SGMII_NR_CLK);
|
||||
if (!clk_data)
|
||||
return -ENOMEM;
|
||||
|
||||
mtk_clk_register_gates(node, sgmii_clks[id++], CLK_SGMII_NR_CLK,
|
||||
clk_data);
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue