Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge tag 'soc-fsl-fix-v4.19-2' of git://git.kernel.org/pub/scm/linux/kernel/git/leo/linux into fixes

NXP/FSL SoC driver fixes for v4.19 round 2

- Fix crash of qman_portal by deferring its probe if qman is not probed

* tag 'soc-fsl-fix-v4.19-2' of git://git.kernel.org/pub/scm/linux/kernel/git/leo/linux:
soc: fsl: qman_portals: defer probe after qman's probe
soc: fsl: qbman: add APIs to retrieve the probing status
soc: fsl: qe: Fix copy/paste bug in ucc_get_tdm_sync_shift()
soc: fsl: qbman: qman: avoid allocating from non existing gen_pool
ARM: dts: BCM63xx: Fix incorrect interrupt specifiers
MAINTAINERS: update the Annapurna Labs maintainer email
ARM: dts: sun8i: drop A64 HDMI PHY fallback compatible from R40 DT
ARM: dts: at91: sama5d2_ptc_ek: fix nand pinctrl

Signed-off-by: Arnd Bergmann <arnd@arndb.de>

+62 -10
+1 -1
MAINTAINERS
··· 1251 1251 1252 1252 ARM/Annapurna Labs ALPINE ARCHITECTURE 1253 1253 M: Tsahee Zidenberg <tsahee@annapurnalabs.com> 1254 - M: Antoine Tenart <antoine.tenart@free-electrons.com> 1254 + M: Antoine Tenart <antoine.tenart@bootlin.com> 1255 1255 L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 1256 1256 S: Maintained 1257 1257 F: arch/arm/mach-alpine/
+2
arch/arm/boot/dts/at91-sama5d2_ptc_ek.dts
··· 11 11 #include "sama5d2-pinfunc.h" 12 12 #include <dt-bindings/mfd/atmel-flexcom.h> 13 13 #include <dt-bindings/gpio/gpio.h> 14 + #include <dt-bindings/pinctrl/at91.h> 14 15 15 16 / { 16 17 model = "Atmel SAMA5D2 PTC EK"; ··· 300 299 <PIN_PA30__NWE_NANDWE>, 301 300 <PIN_PB2__NRD_NANDOE>; 302 301 bias-pull-up; 302 + atmel,drive-strength = <ATMEL_PIO_DRVSTR_ME>; 303 303 }; 304 304 305 305 ale_cle_rdy_cs {
+8 -6
arch/arm/boot/dts/bcm63138.dtsi
··· 106 106 global_timer: timer@1e200 { 107 107 compatible = "arm,cortex-a9-global-timer"; 108 108 reg = <0x1e200 0x20>; 109 - interrupts = <GIC_PPI 11 IRQ_TYPE_LEVEL_HIGH>; 109 + interrupts = <GIC_PPI 11 IRQ_TYPE_EDGE_RISING>; 110 110 clocks = <&axi_clk>; 111 111 }; 112 112 113 113 local_timer: local-timer@1e600 { 114 114 compatible = "arm,cortex-a9-twd-timer"; 115 115 reg = <0x1e600 0x20>; 116 - interrupts = <GIC_PPI 13 IRQ_TYPE_LEVEL_HIGH>; 116 + interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(2) | 117 + IRQ_TYPE_EDGE_RISING)>; 117 118 clocks = <&axi_clk>; 118 119 }; 119 120 120 121 twd_watchdog: watchdog@1e620 { 121 122 compatible = "arm,cortex-a9-twd-wdt"; 122 123 reg = <0x1e620 0x20>; 123 - interrupts = <GIC_PPI 14 IRQ_TYPE_LEVEL_HIGH>; 124 + interrupts = <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(2) | 125 + IRQ_TYPE_LEVEL_HIGH)>; 124 126 }; 125 127 126 128 armpll: armpll { ··· 160 158 serial0: serial@600 { 161 159 compatible = "brcm,bcm6345-uart"; 162 160 reg = <0x600 0x1b>; 163 - interrupts = <GIC_SPI 32 0>; 161 + interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_HIGH>; 164 162 clocks = <&periph_clk>; 165 163 clock-names = "periph"; 166 164 status = "disabled"; ··· 169 167 serial1: serial@620 { 170 168 compatible = "brcm,bcm6345-uart"; 171 169 reg = <0x620 0x1b>; 172 - interrupts = <GIC_SPI 33 0>; 170 + interrupts = <GIC_SPI 33 IRQ_TYPE_LEVEL_HIGH>; 173 171 clocks = <&periph_clk>; 174 172 clock-names = "periph"; 175 173 status = "disabled"; ··· 182 180 reg = <0x2000 0x600>, <0xf0 0x10>; 183 181 reg-names = "nand", "nand-int-base"; 184 182 status = "disabled"; 185 - interrupts = <GIC_SPI 38 0>; 183 + interrupts = <GIC_SPI 38 IRQ_TYPE_LEVEL_HIGH>; 186 184 interrupt-names = "nand"; 187 185 }; 188 186
+1 -2
arch/arm/boot/dts/sun8i-r40.dtsi
··· 800 800 }; 801 801 802 802 hdmi_phy: hdmi-phy@1ef0000 { 803 - compatible = "allwinner,sun8i-r40-hdmi-phy", 804 - "allwinner,sun50i-a64-hdmi-phy"; 803 + compatible = "allwinner,sun8i-r40-hdmi-phy"; 805 804 reg = <0x01ef0000 0x10000>; 806 805 clocks = <&ccu CLK_BUS_HDMI1>, <&ccu CLK_HDMI_SLOW>, 807 806 <&ccu 7>, <&ccu 16>;
+11
drivers/soc/fsl/qbman/bman_ccsr.c
··· 120 120 */ 121 121 static dma_addr_t fbpr_a; 122 122 static size_t fbpr_sz; 123 + static int __bman_probed; 123 124 124 125 static int bman_fbpr(struct reserved_mem *rmem) 125 126 { ··· 167 166 return IRQ_HANDLED; 168 167 } 169 168 169 + int bman_is_probed(void) 170 + { 171 + return __bman_probed; 172 + } 173 + EXPORT_SYMBOL_GPL(bman_is_probed); 174 + 170 175 static int fsl_bman_probe(struct platform_device *pdev) 171 176 { 172 177 int ret, err_irq; ··· 181 174 struct resource *res; 182 175 u16 id, bm_pool_cnt; 183 176 u8 major, minor; 177 + 178 + __bman_probed = -1; 184 179 185 180 res = platform_get_resource(pdev, IORESOURCE_MEM, 0); 186 181 if (!res) { ··· 263 254 0, bm_pool_cnt - 1, ret); 264 255 return ret; 265 256 } 257 + 258 + __bman_probed = 1; 266 259 267 260 return 0; 268 261 };
+3
drivers/soc/fsl/qbman/qman.c
··· 2729 2729 { 2730 2730 unsigned long addr; 2731 2731 2732 + if (!p) 2733 + return -ENODEV; 2734 + 2732 2735 addr = gen_pool_alloc(p, cnt); 2733 2736 if (!addr) 2734 2737 return -ENOMEM;
+11
drivers/soc/fsl/qbman/qman_ccsr.c
··· 273 273 static u32 __iomem *qm_ccsr_start; 274 274 /* A SDQCR mask comprising all the available/visible pool channels */ 275 275 static u32 qm_pools_sdqcr; 276 + static int __qman_probed; 276 277 277 278 static inline u32 qm_ccsr_in(u32 offset) 278 279 { ··· 687 686 return 0; 688 687 } 689 688 689 + int qman_is_probed(void) 690 + { 691 + return __qman_probed; 692 + } 693 + EXPORT_SYMBOL_GPL(qman_is_probed); 694 + 690 695 static int fsl_qman_probe(struct platform_device *pdev) 691 696 { 692 697 struct device *dev = &pdev->dev; ··· 701 694 int ret, err_irq; 702 695 u16 id; 703 696 u8 major, minor; 697 + 698 + __qman_probed = -1; 704 699 705 700 res = platform_get_resource(pdev, IORESOURCE_MEM, 0); 706 701 if (!res) { ··· 836 827 ret = qman_wq_alloc(); 837 828 if (ret) 838 829 return ret; 830 + 831 + __qman_probed = 1; 839 832 840 833 return 0; 841 834 }
+8
drivers/soc/fsl/qbman/qman_portal.c
··· 227 227 int irq, cpu, err; 228 228 u32 val; 229 229 230 + err = qman_is_probed(); 231 + if (!err) 232 + return -EPROBE_DEFER; 233 + if (err < 0) { 234 + dev_err(&pdev->dev, "failing probe due to qman probe error\n"); 235 + return -ENODEV; 236 + } 237 + 230 238 pcfg = devm_kmalloc(dev, sizeof(*pcfg), GFP_KERNEL); 231 239 if (!pcfg) 232 240 return -ENOMEM;
+1 -1
drivers/soc/fsl/qe/ucc.c
··· 626 626 { 627 627 u32 shift; 628 628 629 - shift = (mode == COMM_DIR_RX) ? RX_SYNC_SHIFT_BASE : RX_SYNC_SHIFT_BASE; 629 + shift = (mode == COMM_DIR_RX) ? RX_SYNC_SHIFT_BASE : TX_SYNC_SHIFT_BASE; 630 630 shift -= tdm_num * 2; 631 631 632 632 return shift;
+8
include/soc/fsl/bman.h
··· 126 126 */ 127 127 int bman_acquire(struct bman_pool *pool, struct bm_buffer *bufs, u8 num); 128 128 129 + /** 130 + * bman_is_probed - Check if bman is probed 131 + * 132 + * Returns 1 if the bman driver successfully probed, -1 if the bman driver 133 + * failed to probe or 0 if the bman driver did not probed yet. 134 + */ 135 + int bman_is_probed(void); 136 + 129 137 #endif /* __FSL_BMAN_H */
+8
include/soc/fsl/qman.h
··· 1186 1186 */ 1187 1187 int qman_release_cgrid(u32 id); 1188 1188 1189 + /** 1190 + * qman_is_probed - Check if qman is probed 1191 + * 1192 + * Returns 1 if the qman driver successfully probed, -1 if the qman driver 1193 + * failed to probe or 0 if the qman driver did not probed yet. 1194 + */ 1195 + int qman_is_probed(void); 1196 + 1189 1197 #endif /* __FSL_QMAN_H */