diff options
author | Peter Robinson <pbrobinson@gmail.com> | 2017-07-03 13:02:38 +0100 |
---|---|---|
committer | Peter Robinson <pbrobinson@gmail.com> | 2017-07-03 13:02:38 +0100 |
commit | aa180629b5ac7ec926fa10852ed7f7c657d72e9c (patch) | |
tree | b85aa977983a28b250873a12e1ee4135ff59269d | |
parent | 8ceef37654995ede538b56e7999ddb799e34f8c6 (diff) | |
download | kernel-aa180629b5ac7ec926fa10852ed7f7c657d72e9c.tar.gz kernel-aa180629b5ac7ec926fa10852ed7f7c657d72e9c.tar.xz kernel-aa180629b5ac7ec926fa10852ed7f7c657d72e9c.zip |
Sync sun8i emac options, QCom fixes and config tweaks, Minor cleanups
-rw-r--r-- | AllWinner-net-emac.patch | 287 | ||||
-rw-r--r-- | baseconfig/CONFIG_BT_HCIUART_SERDEV | 1 | ||||
-rw-r--r-- | filter-armv7hl.sh | 2 | ||||
-rw-r--r-- | kernel-aarch64-debug.config | 1 | ||||
-rw-r--r-- | kernel-aarch64.config | 1 | ||||
-rw-r--r-- | kernel-armv7hl-debug.config | 1 | ||||
-rw-r--r-- | kernel-armv7hl-lpae-debug.config | 1 | ||||
-rw-r--r-- | kernel-armv7hl-lpae.config | 1 | ||||
-rw-r--r-- | kernel-armv7hl.config | 1 | ||||
-rw-r--r-- | kernel-i686-PAE.config | 1 | ||||
-rw-r--r-- | kernel-i686-PAEdebug.config | 1 | ||||
-rw-r--r-- | kernel-i686-debug.config | 1 | ||||
-rw-r--r-- | kernel-i686.config | 1 | ||||
-rw-r--r-- | kernel-ppc64-debug.config | 1 | ||||
-rw-r--r-- | kernel-ppc64.config | 1 | ||||
-rw-r--r-- | kernel-ppc64le-debug.config | 1 | ||||
-rw-r--r-- | kernel-ppc64le.config | 1 | ||||
-rw-r--r-- | kernel-ppc64p7-debug.config | 1 | ||||
-rw-r--r-- | kernel-ppc64p7.config | 1 | ||||
-rw-r--r-- | kernel-s390x-debug.config | 1 | ||||
-rw-r--r-- | kernel-s390x.config | 1 | ||||
-rw-r--r-- | kernel-x86_64-debug.config | 1 | ||||
-rw-r--r-- | kernel-x86_64.config | 1 | ||||
-rw-r--r-- | kernel.spec | 11 | ||||
-rw-r--r-- | qcom-msm89xx-fixes.patch | 285 | ||||
-rw-r--r-- | qcom-rmsg-spmi-fixes.patch | 85 |
26 files changed, 604 insertions, 87 deletions
diff --git a/AllWinner-net-emac.patch b/AllWinner-net-emac.patch index a26b3ae9e..0e0a319d0 100644 --- a/AllWinner-net-emac.patch +++ b/AllWinner-net-emac.patch @@ -2228,3 +2228,290 @@ index ce07285..4575fbb 100644 CONFIG_MDIO_BUS_MUX_MMIOREG=y CONFIG_MESON_GXL_PHY=m CONFIG_MICREL_PHY=y +From patchwork Mon Jun 5 19:21:26 2017 +Content-Type: text/plain; charset="utf-8" +MIME-Version: 1.0 +Content-Transfer-Encoding: 7bit +Subject: [1/5] ARM: sun8i: orangepi-plus: Enable dwmac-sun8i +From: Corentin LABBE <clabbe.montjoie@gmail.com> +X-Patchwork-Id: 9767313 +Message-Id: <20170605192130.25320-2-clabbe.montjoie@gmail.com> +To: robh+dt@kernel.org, mark.rutland@arm.com, linux@armlinux.org.uk, + maxime.ripard@free-electrons.com, wens@csie.org, + catalin.marinas@arm.com, will.deacon@arm.com +Cc: devicetree@vger.kernel.org, linux-sunxi@googlegroups.com, + Corentin Labbe <clabbe.montjoie@gmail.com>, + linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org +Date: Mon, 5 Jun 2017 21:21:26 +0200 + +The dwmac-sun8i hardware is present on the Orange PI plus. +It uses an external PHY rtl8211e via RGMII. + +This patch create the needed regulator, emac and phy nodes. + +Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com> +--- + arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts | 32 ++++++++++++++++++++++++++++ + 1 file changed, 32 insertions(+) + +diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts +index 8c40ab7bfa72..331ed683ac62 100644 +--- a/arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts ++++ b/arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts +@@ -47,6 +47,20 @@ + model = "Xunlong Orange Pi Plus / Plus 2"; + compatible = "xunlong,orangepi-plus", "allwinner,sun8i-h3"; + ++ aliases { ++ ethernet0 = &emac; ++ }; ++ ++ reg_gmac_3v3: gmac-3v3 { ++ compatible = "regulator-fixed"; ++ regulator-name = "gmac-3v3"; ++ regulator-min-microvolt = <3300000>; ++ regulator-max-microvolt = <3300000>; ++ startup-delay-us = <100000>; ++ enable-active-high; ++ gpio = <&pio 3 6 GPIO_ACTIVE_HIGH>; ++ }; ++ + reg_usb3_vbus: usb3-vbus { + compatible = "regulator-fixed"; + pinctrl-names = "default"; +@@ -64,6 +78,24 @@ + status = "okay"; + }; + ++&emac { ++ pinctrl-names = "default"; ++ pinctrl-0 = <&emac_rgmii_pins>; ++ phy-supply = <®_gmac_3v3>; ++ phy-handle = <&ext_rgmii_phy>; ++ phy-mode = "rgmii"; ++ ++ allwinner,leds-active-low; ++ status = "okay"; ++}; ++ ++&mdio { ++ ext_rgmii_phy: ethernet-phy@1 { ++ compatible = "ethernet-phy-ieee802.3-c22"; ++ reg = <0>; ++ }; ++}; ++ + &mmc2 { + pinctrl-names = "default"; + pinctrl-0 = <&mmc2_8bit_pins>; +From patchwork Mon Jun 5 19:21:27 2017 +Content-Type: text/plain; charset="utf-8" +MIME-Version: 1.0 +Content-Transfer-Encoding: 7bit +Subject: [2/5] ARM: sun8i: bananapi-m2-plus: Enable dwmac-sun8i +From: Corentin LABBE <clabbe.montjoie@gmail.com> +X-Patchwork-Id: 9767321 +Message-Id: <20170605192130.25320-3-clabbe.montjoie@gmail.com> +To: robh+dt@kernel.org, mark.rutland@arm.com, linux@armlinux.org.uk, + maxime.ripard@free-electrons.com, wens@csie.org, + catalin.marinas@arm.com, will.deacon@arm.com +Cc: devicetree@vger.kernel.org, linux-sunxi@googlegroups.com, + Corentin Labbe <clabbe.montjoie@gmail.com>, + linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org +Date: Mon, 5 Jun 2017 21:21:27 +0200 + +The dwmac-sun8i hardware is present on the Banana Pi M2+ +It uses an external PHY rtl8211e via RGMII. + +This patch create the needed regulator, emac and phy nodes. + +Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com> +--- + arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts | 29 +++++++++++++++++++++++++ + 1 file changed, 29 insertions(+) + +diff --git a/arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts b/arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts +index 883072b611fa..d756ff825116 100644 +--- a/arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts ++++ b/arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts +@@ -52,6 +52,7 @@ + compatible = "sinovoip,bpi-m2-plus", "allwinner,sun8i-h3"; + + aliases { ++ ethernet0 = &emac; + serial0 = &uart0; + serial1 = &uart1; + }; +@@ -84,6 +85,16 @@ + }; + }; + ++ reg_gmac_3v3: gmac-3v3 { ++ compatible = "regulator-fixed"; ++ regulator-name = "gmac-3v3"; ++ regulator-min-microvolt = <3300000>; ++ regulator-max-microvolt = <3300000>; ++ startup-delay-us = <100000>; ++ enable-active-high; ++ gpio = <&pio 3 6 GPIO_ACTIVE_HIGH>; ++ }; ++ + wifi_pwrseq: wifi_pwrseq { + compatible = "mmc-pwrseq-simple"; + pinctrl-names = "default"; +@@ -104,12 +115,30 @@ + status = "okay"; + }; + ++&emac { ++ pinctrl-names = "default"; ++ pinctrl-0 = <&emac_rgmii_pins>; ++ phy-supply = <®_gmac_3v3>; ++ phy-handle = <&ext_rgmii_phy>; ++ phy-mode = "rgmii"; ++ ++ allwinner,leds-active-low; ++ status = "okay"; ++}; ++ + &ir { + pinctrl-names = "default"; + pinctrl-0 = <&ir_pins_a>; + status = "okay"; + }; + ++&mdio { ++ ext_rgmii_phy: ethernet-phy@1 { ++ compatible = "ethernet-phy-ieee802.3-c22"; ++ reg = <0>; ++ }; ++}; ++ + &mmc0 { + pinctrl-names = "default"; + pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin>; +From patchwork Mon Jun 5 19:21:28 2017 +Content-Type: text/plain; charset="utf-8" +MIME-Version: 1.0 +Content-Transfer-Encoding: 7bit +Subject: [3/5] ARM: sun50i: orangepi-pc2: Enable dwmac-sun8i +From: Corentin LABBE <clabbe.montjoie@gmail.com> +X-Patchwork-Id: 9767347 +Message-Id: <20170605192130.25320-4-clabbe.montjoie@gmail.com> +To: robh+dt@kernel.org, mark.rutland@arm.com, linux@armlinux.org.uk, + maxime.ripard@free-electrons.com, wens@csie.org, + catalin.marinas@arm.com, will.deacon@arm.com +Cc: devicetree@vger.kernel.org, linux-sunxi@googlegroups.com, + Corentin Labbe <clabbe.montjoie@gmail.com>, + linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org +Date: Mon, 5 Jun 2017 21:21:28 +0200 + +The dwmac-sun8i hardware is present on the Orange PI PC2. +It uses an external PHY rtl8211e via RGMII. + +This patch create the needed regulator, emac and phy nodes. +Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com> +--- + .../boot/dts/allwinner/sun50i-h5-orangepi-pc2.dts | 27 ++++++++++++++++++++++ + 1 file changed, 27 insertions(+) + +diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-pc2.dts b/arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-pc2.dts +index dfecc17dcc92..a8296feee884 100644 +--- a/arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-pc2.dts ++++ b/arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-pc2.dts +@@ -59,6 +59,7 @@ + }; + + aliases { ++ ethernet0 = &emac; + serial0 = &uart0; + }; + +@@ -91,6 +92,16 @@ + }; + }; + ++ reg_gmac_3v3: gmac-3v3 { ++ compatible = "regulator-fixed"; ++ regulator-name = "gmac-3v3"; ++ regulator-min-microvolt = <3300000>; ++ regulator-max-microvolt = <3300000>; ++ startup-delay-us = <100000>; ++ enable-active-high; ++ gpio = <&pio 3 6 GPIO_ACTIVE_HIGH>; ++ }; ++ + reg_usb0_vbus: usb0-vbus { + compatible = "regulator-fixed"; + regulator-name = "usb0-vbus"; +@@ -126,12 +137,28 @@ + status = "okay"; + }; + ++&emac { ++ pinctrl-names = "default"; ++ pinctrl-0 = <&emac_rgmii_pins>; ++ phy-supply = <®_gmac_3v3>; ++ phy-handle = <&ext_rgmii_phy>; ++ phy-mode = "rgmii"; ++ status = "okay"; ++}; ++ + &ir { + pinctrl-names = "default"; + pinctrl-0 = <&ir_pins_a>; + status = "okay"; + }; + ++&mdio { ++ ext_rgmii_phy: ethernet-phy@1 { ++ compatible = "ethernet-phy-ieee802.3-c22"; ++ reg = <1>; ++ }; ++}; ++ + &mmc0 { + pinctrl-names = "default"; + pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin>; +From patchwork Wed May 31 07:18:44 2017 +Content-Type: text/plain; charset="utf-8" +MIME-Version: 1.0 +Content-Transfer-Encoding: 7bit +Subject: [v6,13/21] arm: sun8i: nanopi-neo: Enable dwmac-sun8i +From: Corentin LABBE <clabbe.montjoie@gmail.com> +X-Patchwork-Id: 9756089 +Message-Id: <20170531071852.12422-14-clabbe.montjoie@gmail.com> +To: robh+dt@kernel.org, mark.rutland@arm.com, + maxime.ripard@free-electrons.com, + wens@csie.org, linux@armlinux.org.uk, catalin.marinas@arm.com, + will.deacon@arm.com, peppe.cavallaro@st.com, alexandre.torgue@st.com +Cc: devicetree@vger.kernel.org, netdev@vger.kernel.org, + linux-kernel@vger.kernel.org, linux-sunxi@googlegroups.com, + Corentin Labbe <clabbe.montjoie@gmail.com>, + linux-arm-kernel@lists.infradead.org +Date: Wed, 31 May 2017 09:18:44 +0200 + +The dwmac-sun8i hardware is present on the NanoPi Neo. +It uses the internal PHY. +This patch create the needed emac node. + +Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com> +--- + arch/arm/boot/dts/sun8i-h3-nanopi-neo.dts | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/arch/arm/boot/dts/sun8i-h3-nanopi-neo.dts b/arch/arm/boot/dts/sun8i-h3-nanopi-neo.dts +index 8d2cc6e9a03f..78f6c24952dd 100644 +--- a/arch/arm/boot/dts/sun8i-h3-nanopi-neo.dts ++++ b/arch/arm/boot/dts/sun8i-h3-nanopi-neo.dts +@@ -46,3 +46,10 @@ + model = "FriendlyARM NanoPi NEO"; + compatible = "friendlyarm,nanopi-neo", "allwinner,sun8i-h3"; + }; ++ ++&emac { ++ phy-handle = <&int_mii_phy>; ++ phy-mode = "mii"; ++ allwinner,leds-active-low; ++ status = "okay"; ++}; diff --git a/baseconfig/CONFIG_BT_HCIUART_SERDEV b/baseconfig/CONFIG_BT_HCIUART_SERDEV new file mode 100644 index 000000000..0b0ef5abd --- /dev/null +++ b/baseconfig/CONFIG_BT_HCIUART_SERDEV @@ -0,0 +1 @@ +CONFIG_BT_HCIUART_SERDEV=y diff --git a/filter-armv7hl.sh b/filter-armv7hl.sh index d02f6ad1e..db80ef62f 100644 --- a/filter-armv7hl.sh +++ b/filter-armv7hl.sh @@ -13,6 +13,6 @@ driverdirs="atm auxdisplay bcma bluetooth firewire fmc infiniband isdn media mem ethdrvs="3com adaptec alteon altera amd atheros broadcom cadence chelsio cisco dec dlink emulex icplus mellanox micrel myricom natsemi neterion nvidia oki-semi packetengines qlogic rdc renesas sfc silan sis sun tehuti via wiznet xircom" -drmdrvs="amd armada bridge ast exynos etnaviv hisilicon i2c imx mgag200 msm omapdrm panel nouveau radeon rockchip sti tegra tilcdc tinydrm via vc4" +drmdrvs="amd armada bridge ast exynos etnaviv hisilicon i2c imx meson mgag200 msm omapdrm panel nouveau radeon rockchip sti tegra tilcdc tinydrm via vc4" singlemods="ntb_netdev iscsi_ibft iscsi_boot_sysfs megaraid pmcraid qedi qla1280 9pnet_rdma rpcrdma nvmet-rdma nvme-rdma hid-picolcd hid-prodikeys hwa-hc hwpoison-inject target_core_user sbp_target cxgbit iw_cxgb3 iw_cxgb4 cxgb3i cxgb3i cxgb3i_ddp cxgb4i chcr" diff --git a/kernel-aarch64-debug.config b/kernel-aarch64-debug.config index b02ce0f39..1bfbee43e 100644 --- a/kernel-aarch64-debug.config +++ b/kernel-aarch64-debug.config @@ -653,6 +653,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-aarch64.config b/kernel-aarch64.config index f20c086a0..1bcbcd5f1 100644 --- a/kernel-aarch64.config +++ b/kernel-aarch64.config @@ -653,6 +653,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-armv7hl-debug.config b/kernel-armv7hl-debug.config index cc6ceb7cf..c43833ea8 100644 --- a/kernel-armv7hl-debug.config +++ b/kernel-armv7hl-debug.config @@ -697,6 +697,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-armv7hl-lpae-debug.config b/kernel-armv7hl-lpae-debug.config index 448ecc388..dfe2e6df1 100644 --- a/kernel-armv7hl-lpae-debug.config +++ b/kernel-armv7hl-lpae-debug.config @@ -675,6 +675,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-armv7hl-lpae.config b/kernel-armv7hl-lpae.config index 29d2c5e2a..545ff0d20 100644 --- a/kernel-armv7hl-lpae.config +++ b/kernel-armv7hl-lpae.config @@ -674,6 +674,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-armv7hl.config b/kernel-armv7hl.config index 7bbc93575..3fc5f1d5d 100644 --- a/kernel-armv7hl.config +++ b/kernel-armv7hl.config @@ -696,6 +696,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-i686-PAE.config b/kernel-i686-PAE.config index d6f456a6d..7dbc987f4 100644 --- a/kernel-i686-PAE.config +++ b/kernel-i686-PAE.config @@ -568,6 +568,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-i686-PAEdebug.config b/kernel-i686-PAEdebug.config index b9bcdf0ab..f4dd95edd 100644 --- a/kernel-i686-PAEdebug.config +++ b/kernel-i686-PAEdebug.config @@ -569,6 +569,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-i686-debug.config b/kernel-i686-debug.config index 1ac4c227e..824cc8629 100644 --- a/kernel-i686-debug.config +++ b/kernel-i686-debug.config @@ -569,6 +569,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-i686.config b/kernel-i686.config index fbc1de15a..5d49673c9 100644 --- a/kernel-i686.config +++ b/kernel-i686.config @@ -568,6 +568,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-ppc64-debug.config b/kernel-ppc64-debug.config index c1fc50524..6bf1e6798 100644 --- a/kernel-ppc64-debug.config +++ b/kernel-ppc64-debug.config @@ -555,6 +555,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-ppc64.config b/kernel-ppc64.config index 6e5ffaa38..33041022f 100644 --- a/kernel-ppc64.config +++ b/kernel-ppc64.config @@ -554,6 +554,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-ppc64le-debug.config b/kernel-ppc64le-debug.config index 6d0d43144..732bd00c6 100644 --- a/kernel-ppc64le-debug.config +++ b/kernel-ppc64le-debug.config @@ -512,6 +512,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-ppc64le.config b/kernel-ppc64le.config index e45c701c2..37f051f05 100644 --- a/kernel-ppc64le.config +++ b/kernel-ppc64le.config @@ -511,6 +511,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-ppc64p7-debug.config b/kernel-ppc64p7-debug.config index 170a1dcf7..19b4634ba 100644 --- a/kernel-ppc64p7-debug.config +++ b/kernel-ppc64p7-debug.config @@ -512,6 +512,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-ppc64p7.config b/kernel-ppc64p7.config index 11d36ce54..b1058a8b1 100644 --- a/kernel-ppc64p7.config +++ b/kernel-ppc64p7.config @@ -511,6 +511,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-s390x-debug.config b/kernel-s390x-debug.config index 46f9cc490..d3107b82b 100644 --- a/kernel-s390x-debug.config +++ b/kernel-s390x-debug.config @@ -511,6 +511,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-s390x.config b/kernel-s390x.config index c54282995..91c7df7ce 100644 --- a/kernel-s390x.config +++ b/kernel-s390x.config @@ -510,6 +510,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-x86_64-debug.config b/kernel-x86_64-debug.config index ff82ac3f8..34cb7bef2 100644 --- a/kernel-x86_64-debug.config +++ b/kernel-x86_64-debug.config @@ -577,6 +577,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel-x86_64.config b/kernel-x86_64.config index a2cf99883..c9b2d05a0 100644 --- a/kernel-x86_64.config +++ b/kernel-x86_64.config @@ -576,6 +576,7 @@ CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_MRVL=y CONFIG_BT_HCIUART_NOKIA=m CONFIG_BT_HCIUART_QCA=y +CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIVHCI=m CONFIG_BT_HIDP=m CONFIG_BT_HS=y diff --git a/kernel.spec b/kernel.spec index f0593a5dd..8000b6246 100644 --- a/kernel.spec +++ b/kernel.spec @@ -611,7 +611,11 @@ Patch315: bcm283x-vc4-fix-vblank.patch # https://patchwork.kernel.org/patch/9815555/ # https://patchwork.kernel.org/patch/9815651/ -Patch316: qcom-rmsg-spmi-fixes.patch +# https://patchwork.kernel.org/patch/9819885/ +# https://patchwork.kernel.org/patch/9820417/ +# https://patchwork.kernel.org/patch/9821151/ +# https://patchwork.kernel.org/patch/9821157/ +Patch316: qcom-msm89xx-fixes.patch # 400 - IBM (ppc/s390x) patches @@ -2197,6 +2201,11 @@ fi # # %changelog +* Mon Jul 3 2017 Peter Robinson <pbrobinson@fedoraproject.org> +- Sync sun8i emac options +- QCom fixes and config tweaks +- Minor cleanups + * Thu Jun 29 2017 Peter Robinson <pbrobinson@fedoraproject.org> - Enable HDMI on Amlogic Meson SoCs diff --git a/qcom-msm89xx-fixes.patch b/qcom-msm89xx-fixes.patch new file mode 100644 index 000000000..fc2f16dc3 --- /dev/null +++ b/qcom-msm89xx-fixes.patch @@ -0,0 +1,285 @@ +From 83b8b93188114e1a39b3475d9429a2ee8977a398 Mon Sep 17 00:00:00 2001 +From: Bjorn Andersson <bjorn.andersson@linaro.org> +Date: Wed, 28 Jun 2017 14:53:23 -0700 +Subject: [PATCH 1/6] rpmsg: Make modalias work for DeviceTree based devices + +When rpmsg devices are expected to be matched based on their compatible +the modalias should reflect this, so that module autoloading has a +chance to match and load the appropriate module. + +Tested-by: Rob Clark <robdclark@gmail.com> +Reported-by: Rob Clark <robdclark@gmail.com> +Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> +--- + drivers/rpmsg/rpmsg_core.c | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +diff --git a/drivers/rpmsg/rpmsg_core.c b/drivers/rpmsg/rpmsg_core.c +index 600f5f9f7431..62580ad1b1f1 100644 +--- a/drivers/rpmsg/rpmsg_core.c ++++ b/drivers/rpmsg/rpmsg_core.c +@@ -342,6 +342,11 @@ static ssize_t modalias_show(struct device *dev, + struct device_attribute *attr, char *buf) + { + struct rpmsg_device *rpdev = to_rpmsg_device(dev); ++ ssize_t len; ++ ++ len = of_device_modalias(dev, buf, PAGE_SIZE); ++ if (len != -ENODEV) ++ return len; + + return sprintf(buf, RPMSG_DEVICE_MODALIAS_FMT "\n", rpdev->id.name); + } +@@ -384,6 +389,11 @@ static int rpmsg_dev_match(struct device *dev, struct device_driver *drv) + static int rpmsg_uevent(struct device *dev, struct kobj_uevent_env *env) + { + struct rpmsg_device *rpdev = to_rpmsg_device(dev); ++ int ret; ++ ++ ret = of_device_uevent_modalias(dev, env); ++ if (ret != -ENODEV) ++ return ret; + + return add_uevent_var(env, "MODALIAS=" RPMSG_DEVICE_MODALIAS_FMT, + rpdev->id.name); +-- +2.13.0 + +From ccdf75f90484a87ddb29649304156a503bf5a829 Mon Sep 17 00:00:00 2001 +From: Bjorn Andersson <bjorn.andersson@linaro.org> +Date: Wed, 28 Jun 2017 16:44:58 -0700 +Subject: [PATCH 2/6] spmi: Include OF based modalias in device uevent + +Include the OF-based modalias in the uevent sent when registering SPMI +devices, so that user space has a chance to autoload the kernel module +for the device. + +Reported-by: Rob Clark <robdclark@gmail.com> +Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> +Tested-by: Rob Clark <robdclark@gmail.com> +Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> +--- + drivers/spmi/spmi.c | 12 ++++++++++++ + 1 file changed, 12 insertions(+) + +diff --git a/drivers/spmi/spmi.c b/drivers/spmi/spmi.c +index 2b9b0941d9eb..6d23226e5f69 100644 +--- a/drivers/spmi/spmi.c ++++ b/drivers/spmi/spmi.c +@@ -365,11 +365,23 @@ static int spmi_drv_remove(struct device *dev) + return 0; + } + ++static int spmi_drv_uevent(struct device *dev, struct kobj_uevent_env *env) ++{ ++ int ret; ++ ++ ret = of_device_uevent_modalias(dev, env); ++ if (ret != -ENODEV) ++ return ret; ++ ++ return 0; ++} ++ + static struct bus_type spmi_bus_type = { + .name = "spmi", + .match = spmi_device_match, + .probe = spmi_drv_probe, + .remove = spmi_drv_remove, ++ .uevent = spmi_drv_uevent, + }; + + /** +-- +2.13.0 + +From 283d0e00a18b294ec56f1fb904896a546704faaf Mon Sep 17 00:00:00 2001 +From: Rob Clark <robdclark@gmail.com> +Date: Fri, 30 Jun 2017 11:47:21 -0400 +Subject: [PATCH 3/6] soc: qcom: smsm: fix of_node refcnting problem + +of_find_node_with_property() drops the reference to the 'from' node, +which eventually (after enough -EPROBE_DEFERs) drops the last reference +to the node causing all sorts of fun problems, and this nice splat. + + BUG: sleeping function called from invalid context at ../kernel/locking/mutex.c:747 + in_atomic(): 1, irqs_disabled(): 128, pid: 33, name: kworker/0:1 + 4 locks held by kworker/0:1/33: + #0: ("events"){.+.+.+}, at: [<ffff0000080fa91c>] process_one_work+0x1a4/0x728 + #1: (deferred_probe_work){+.+.+.}, at: [<ffff0000080fa91c>] process_one_work+0x1a4/0x728 + #2: (&dev->mutex){......}, at: [<ffff000008676078>] __device_attach+0x30/0x168 + #3: (devtree_lock){......}, at: [<ffff000008828fd0>] of_find_node_with_property+0x30/0xe0 + irq event stamp: 18976 + hardirqs last enabled at (18975): [<ffff00000815794c>] __down_trylock_console_sem+0x74/0xb8 + hardirqs last disabled at (18976): [<ffff0000089e26d4>] _raw_spin_lock_irqsave+0x2c/0x78 + softirqs last enabled at (16880): [<ffff0000080e0f00>] __do_softirq+0x580/0x640 + softirqs last disabled at (16871): [<ffff0000080e13a4>] irq_exit+0xe4/0x138 + CPU: 0 PID: 33 Comm: kworker/0:1 Tainted: G E 4.12.0-rc5+ #1455 + Hardware name: qualcomm dragonboard410c/dragonboard410c, BIOS 2017.07-rc1-00234-g22fa70a-dirty 06/26/2017 + Workqueue: events deferred_probe_work_func + Call trace: + [<ffff000008089ee0>] dump_backtrace+0x0/0x230 + [<ffff00000808a134>] show_stack+0x24/0x30 + [<ffff0000084e1944>] dump_stack+0xac/0xe8 + [<ffff00000810d7e0>] ___might_sleep+0x150/0x230 + [<ffff00000810d918>] __might_sleep+0x58/0x90 + [<ffff0000089dde18>] __mutex_lock+0x50/0x870 + [<ffff0000089de674>] mutex_lock_nested+0x3c/0x50 + [<ffff000008388ae0>] kernfs_remove+0x30/0x50 + [<ffff00000838b720>] sysfs_remove_dir+0x58/0x70 + [<ffff0000084e393c>] kobject_del+0x1c/0x58 + [<ffff0000084e374c>] kobject_put+0xb4/0x208 + [<ffff00000882c364>] of_node_put+0x24/0x30 + [<ffff000008829018>] of_find_node_with_property+0x78/0xe0 + [<ffff000000aff5f4>] qcom_smsm_probe+0x194/0x720 [smsm] + [<ffff0000086793b4>] platform_drv_probe+0x74/0x110 + [<ffff0000086765bc>] driver_probe_device+0x2b4/0x420 + [<ffff000008676920>] __device_attach_driver+0xd0/0x150 + [<ffff000008673e78>] bus_for_each_drv+0x68/0xa8 + [<ffff00000867611c>] __device_attach+0xd4/0x168 + [<ffff000008676a1c>] device_initial_probe+0x24/0x30 + [<ffff000008675380>] bus_probe_device+0xa0/0xa8 + [<ffff000008675948>] deferred_probe_work_func+0xb8/0xf8 + [<ffff0000080fa9d4>] process_one_work+0x25c/0x728 + [<ffff0000080faef4>] worker_thread+0x54/0x3d8 + [<ffff0000081031d8>] kthread+0x110/0x140 + [<ffff000008082d90>] ret_from_fork+0x10/0x40 + OF: ERROR: Bad of_node_put() on /smsm + CPU: 0 PID: 33 Comm: kworker/0:1 Tainted: G W E 4.12.0-rc5+ #1455 + Hardware name: qualcomm dragonboard410c/dragonboard410c, BIOS 2017.07-rc1-00234-g22fa70a-dirty 06/26/2017 + Workqueue: events deferred_probe_work_func + +Signed-off-by: Rob Clark <robdclark@gmail.com> +--- + drivers/soc/qcom/smsm.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/drivers/soc/qcom/smsm.c b/drivers/soc/qcom/smsm.c +index d0337b2a71c8..a64ecd597a22 100644 +--- a/drivers/soc/qcom/smsm.c ++++ b/drivers/soc/qcom/smsm.c +@@ -495,7 +495,8 @@ static int qcom_smsm_probe(struct platform_device *pdev) + if (!smsm->hosts) + return -ENOMEM; + +- local_node = of_find_node_with_property(pdev->dev.of_node, "#qcom,smem-state-cells"); ++ local_node = of_find_node_with_property(of_node_get(pdev->dev.of_node), ++ "#qcom,smem-state-cells"); + if (!local_node) { + dev_err(&pdev->dev, "no state entry\n"); + return -EINVAL; +-- +2.13.0 + +From 40cb129048e5d2456da8d9d6468f292da3071b91 Mon Sep 17 00:00:00 2001 +From: Rob Clark <robdclark@gmail.com> +Date: Fri, 30 Jun 2017 16:40:23 -0400 +Subject: [PATCH 4/6] thermal: qcom: tsens: fix crash due to incorrect __init + +init_common() is called from probe, which can happen after the __init +section is already unloaded in the case of -EPROBE_DEFER. Causing a +later probe to attempt to branch to hyperspace. + +Cc: <stable@vger.kernel.org> +Signed-off-by: Rob Clark <robdclark@gmail.com> +Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> +--- + drivers/thermal/qcom/tsens-common.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/drivers/thermal/qcom/tsens-common.c b/drivers/thermal/qcom/tsens-common.c +index b1449ad67fc0..22ad37c9808c 100644 +--- a/drivers/thermal/qcom/tsens-common.c ++++ b/drivers/thermal/qcom/tsens-common.c +@@ -123,7 +123,7 @@ static const struct regmap_config tsens_config = { + .reg_stride = 4, + }; + +-int __init init_common(struct tsens_device *tmdev) ++int init_common(struct tsens_device *tmdev) + { + void __iomem *base; + +-- +2.13.0 + +From ae9b4fa55748cc9ce3c8ac039e46feab7257eff9 Mon Sep 17 00:00:00 2001 +From: Rob Clark <robdclark@gmail.com> +Date: Sun, 2 Jul 2017 09:23:36 -0400 +Subject: [PATCH 5/6] soc: qcom: wcnss_ctrl: add missing MODULE_DEVICE_TABLE() + +This fixes a problem of wifi module not loading on db410c. + +Signed-off-by: Rob Clark <robdclark@gmail.com> +Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> +--- + drivers/soc/qcom/wcnss_ctrl.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/drivers/soc/qcom/wcnss_ctrl.c b/drivers/soc/qcom/wcnss_ctrl.c +index b9069184df19..d008e5b82db4 100644 +--- a/drivers/soc/qcom/wcnss_ctrl.c ++++ b/drivers/soc/qcom/wcnss_ctrl.c +@@ -347,6 +347,7 @@ static const struct of_device_id wcnss_ctrl_of_match[] = { + { .compatible = "qcom,wcnss", }, + {} + }; ++MODULE_DEVICE_TABLE(of, wcnss_ctrl_of_match); + + static struct rpmsg_driver wcnss_ctrl_driver = { + .probe = wcnss_ctrl_probe, +-- +2.13.0 + +From 173c1207986956ea4c00601a67c952751a1985e6 Mon Sep 17 00:00:00 2001 +From: Peter Robinson <pbrobinson@gmail.com> +Date: Mon, 3 Jul 2017 10:10:21 +0100 +Subject: [PATCH 6/6] wcn36xx: check dma_mapping_error() + +Fixes splat: + + wcn36xx a204000.wcnss:smd-edge:wcnss:wifi: DMA-API: device driver failed to check map error[device address=0x00000000b45ba000] [size=3872 bytes] [mapped as single] + ------------[ cut here ]------------ + WARNING: CPU: 0 PID: 0 at ../lib/dma-debug.c:1167 check_unmap+0x474/0x8d0 + Modules linked in: bnep(E) arc4(E) wcn36xx(E) mac80211(E) btqcomsmd(E) btqca(E) bluetooth(E) cfg80211(E) ecdh_generic(E) rfkill(E) vfat(E) fat(E) wcnss_ctrl qcom_wcnss_pil(E) mdt_loader(E) qcom_common(E) remoteproc(E) crc32_ce(E) virtio_ring(E) snd_soc_lpass_apq8016(E) snd_soc_lpass_cpu(E) virtio(E) snd_soc_lpass_platform(E) leds_gpio(E) snd_soc_hdmi_codec(E) snd_soc_apq8016_sbc(E) snd_soc_msm8916_digital(E) snd_soc_core(E) qcom_spmi_temp_alarm(E) ac97_bus(E) snd_pcm_dmaengine(E) snd_seq(E) snd_seq_device(E) snd_pcm(E) spi_qup(E) nvmem_qfprom(E) snd_timer(E) snd(E) soundcore(E) msm_rng(E) qcom_tsens(E) nvmem_core(E) uas(E) usb_storage(E) dm9601(E) cdc_ether(E) usbnet(E) mii(E) mmc_block(E) sdhci_msm(E) sdhci_pltfm(E) qcom_spmi_vadc(E) qcom_vadc_common(PE) clk_smd_rpm(E) industrialio(E) + qcom_smd_regulator(E) pinctrl_spmi_mpp(E) pinctrl_spmi_gpio(E) rtc_pm8xxx(E) adv7511(E) smd_rpm(E) qcom_spmi_pmic(E) regmap_spmi(E) phy_msm_usb(E) usb3503(E) extcon_usb_gpio(E) ci_hdrc_msm(E) ci_hdrc(E) qcom_hwspinlock(E) udc_core(E) extcon_core(E) ehci_msm(E) i2c_qup(E) sdhci(E) msm(E) mmc_core(E) drm_kms_helper(E) syscopyarea(E) sysfillrect(E) sysimgblt(E) fb_sys_fops(E) spmi_pmic_arb(E) drm(E) spmi(E) qcom_smd(E) rpmsg_core smsm(E) gpio_keys(E) smp2p(E) smem(E) hwspinlock_core(E) sunrpc(E) scsi_transport_iscsi(E) + CPU: 0 PID: 0 Comm: swapper/0 Tainted: P E 4.12.0-rc7+ #1476 + Hardware name: qualcomm dragonboard410c/dragonboard410c, BIOS 2017.07-rc1-00234-g22fa70a-dirty 06/26/2017 + task: ffff000009049780 task.stack: ffff000009030000 + PC is at check_unmap+0x474/0x8d0 + LR is at check_unmap+0x474/0x8d0 + ... + Mapped at: + dma_entry_alloc+0x68/0xa8 + debug_dma_map_page+0x94/0x148 + wcn36xx_dxe_fill_skb.isra.1+0xbc/0xf8 [wcn36xx] + wcn36xx_dxe_init+0x244/0x398 [wcn36xx] + wcn36xx_start+0xf4/0x298 [wcn36xx] + +v2: pbrobinson: add kfree_skb(skb); + +Signed-off-by: Rob Clark <robdclark@gmail.com> +Signed-off-by: Peter Robinson <pbrobinson@gmail.com> +--- + drivers/net/wireless/ath/wcn36xx/dxe.c | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/drivers/net/wireless/ath/wcn36xx/dxe.c b/drivers/net/wireless/ath/wcn36xx/dxe.c +index 87dfdaf9044c..d5c810a8cc52 100644 +--- a/drivers/net/wireless/ath/wcn36xx/dxe.c ++++ b/drivers/net/wireless/ath/wcn36xx/dxe.c +@@ -289,6 +289,11 @@ static int wcn36xx_dxe_fill_skb(struct device *dev, struct wcn36xx_dxe_ctl *ctl) + skb_tail_pointer(skb), + WCN36XX_PKT_SIZE, + DMA_FROM_DEVICE); ++ if (dma_mapping_error(dev, dxe->dst_addr_l)) { ++ dev_err(dev, "unable to map skb\n"); ++ kfree_skb(skb); ++ return -ENOMEM; ++ } + ctl->skb = skb; + + return 0; +-- +2.13.0 + diff --git a/qcom-rmsg-spmi-fixes.patch b/qcom-rmsg-spmi-fixes.patch deleted file mode 100644 index 7aa1ca18c..000000000 --- a/qcom-rmsg-spmi-fixes.patch +++ /dev/null @@ -1,85 +0,0 @@ -From patchwork Wed Jun 28 21:53:23 2017 -Content-Type: text/plain; charset="utf-8" -MIME-Version: 1.0 -Content-Transfer-Encoding: 7bit -Subject: [v2] rpmsg: Make modalias work for DeviceTree based devices -From: Bjorn Andersson <bjorn.andersson@linaro.org> -X-Patchwork-Id: 9815555 -Message-Id: <20170628215323.5658-1-bjorn.andersson@linaro.org> -To: Ohad Ben-Cohen <ohad@wizery.com>, - Bjorn Andersson <bjorn.andersson@linaro.org> -Cc: linux-remoteproc@vger.kernel.org, linux-kernel@vger.kernel.org, - Rob Clark <robdclark@gmail.com> -Date: Wed, 28 Jun 2017 14:53:23 -0700 - -When rpmsg devices are expected to be matched based on their compatible -the modalias should reflect this, so that module autoloading has a -chance to match and load the appropriate module. - -Tested-by: Rob Clark <robdclark@gmail.com> -Reported-by: Rob Clark <robdclark@gmail.com> -Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> ---- - -Changes since v1: -- Also update rpmsg_uevent() - - drivers/rpmsg/rpmsg_core.c | 10 ++++++++++ - 1 file changed, 10 insertions(+) - -diff --git a/drivers/rpmsg/rpmsg_core.c b/drivers/rpmsg/rpmsg_core.c -index ad3d2a9df287..067650c5bcb6 100644 ---- a/drivers/rpmsg/rpmsg_core.c -+++ b/drivers/rpmsg/rpmsg_core.c -@@ -343,6 +343,11 @@ static ssize_t modalias_show(struct device *dev, - struct device_attribute *attr, char *buf) - { - struct rpmsg_device *rpdev = to_rpmsg_device(dev); -+ ssize_t len; -+ -+ len = of_device_modalias(dev, buf, PAGE_SIZE); -+ if (len != -ENODEV) -+ return len; - - return sprintf(buf, RPMSG_DEVICE_MODALIAS_FMT "\n", rpdev->id.name); - } -@@ -387,6 +392,11 @@ static int rpmsg_dev_match(struct device *dev, struct device_driver *drv) - static int rpmsg_uevent(struct device *dev, struct kobj_uevent_env *env) - { - struct rpmsg_device *rpdev = to_rpmsg_device(dev); -+ int ret; -+ -+ ret = of_device_uevent_modalias(dev, env); -+ if (ret != -ENODEV) -+ return ret; - - return add_uevent_var(env, "MODALIAS=" RPMSG_DEVICE_MODALIAS_FMT, - rpdev->id.name); -diff --git a/drivers/spmi/spmi.c b/drivers/spmi/spmi.c -index 2b9b0941d9eb..6d23226e5f69 100644 ---- a/drivers/spmi/spmi.c -+++ b/drivers/spmi/spmi.c -@@ -365,11 +365,23 @@ static int spmi_drv_remove(struct device *dev) - return 0; - } - -+static int spmi_drv_uevent(struct device *dev, struct kobj_uevent_env *env) -+{ -+ int ret; -+ -+ ret = of_device_uevent_modalias(dev, env); -+ if (ret != -ENODEV) -+ return ret; -+ -+ return 0; -+} -+ - static struct bus_type spmi_bus_type = { - .name = "spmi", - .match = spmi_device_match, - .probe = spmi_drv_probe, - .remove = spmi_drv_remove, -+ .uevent = spmi_drv_uevent, - }; - - /** |