Skip to contentSkip to conversation

ARM: dts: fix imx7d boot spi dma setup error

PATCH In review Clark Wang 2 participants 2 messages Oct 23, 2018

Subsystems (2)
lore
Share & tools
lore

Clark Wang

author
#0 lore raw

PATCH 1/1 ARM: dts: fix imx7d boot spi dma setup error

Add dmas and dma-names for ecspi1~4 to fix kernel boot error:
"spi_imx 30840000.ecspi: dma setup error -19, use pio".

---
 arch/arm/boot/dts/imx7s.dtsi | 8 ++++++++
 1 file changed, 8 insertions(+)
arch/arm/boot/dts/imx7s.dtsi +8 -0
index aa8df7d93b2e..043e39124c43 100644
@@ -651,6 +651,8 @@
 				clocks = <&clks IMX7D_ECSPI4_ROOT_CLK>,
 					<&clks IMX7D_ECSPI4_ROOT_CLK>;
 				clock-names = "ipg", "per";
+				dmas = <&sdma 6 7 1>, <&sdma 7 7 2>;
+				dma-names = "rx", "tx";
 				status = "disabled";
 			};
 
@@ -732,6 +734,8 @@
 					clocks = <&clks IMX7D_ECSPI1_ROOT_CLK>,
 						<&clks IMX7D_ECSPI1_ROOT_CLK>;
 					clock-names = "ipg", "per";
+					dmas = <&sdma 0 7 1>, <&sdma 1 7 2>;
+					dma-names = "rx", "tx";
 					status = "disabled";
 				};
 
@@ -744,6 +748,8 @@
 					clocks = <&clks IMX7D_ECSPI2_ROOT_CLK>,
 						<&clks IMX7D_ECSPI2_ROOT_CLK>;
 					clock-names = "ipg", "per";
+					dmas = <&sdma 2 7 1>, <&sdma 3 7 2>;
+					dma-names = "rx", "tx";
 					status = "disabled";
 				};
 
@@ -756,6 +762,8 @@
 					clocks = <&clks IMX7D_ECSPI3_ROOT_CLK>,
 						<&clks IMX7D_ECSPI3_ROOT_CLK>;
 					clock-names = "ipg", "per";
+					dmas = <&sdma 4 7 1>, <&sdma 5 7 2>;
+					dma-names = "rx", "tx";
 					status = "disabled";
 				};
 
Signature · 1 line
2.17.1
#1 lore raw
Quoted 2 lines · Clark Wang

Add dmas and dma-names for ecspi1~4 to fix kernel boot error:
"spi_imx 30840000.ecspi: dma setup error -19, use pio".

Actually this should not be an error and the message is supposed to say:

Unable to setup DMA, falling back to PIO

So IMHO this should be downgraded from dev_err to dev_info and reworded. Maybe even try DMA-setup on devices where it is known to fail and don't emit a message on -ENODEV at all.

Best regards
Uwe

Signature · 2 lines
Pengutronix e.K.                           | Uwe Kleine-K?nig            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |