]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ENGR00274382 imx6q: fix can transceiver unwork on AI RevE baseboard
authorDong Aisheng <b29396@freescale.com>
Wed, 7 Aug 2013 12:20:27 +0000 (20:20 +0800)
committerOliver Wendt <ow@karo-electronics.de>
Mon, 30 Sep 2013 12:14:17 +0000 (14:14 +0200)
The transceiver TJA1041A on sabreauto RevE baseboard will
fail to transit to Normal state if EN/STBY is high by default
after board power up. So we set the EN/STBY initial state to low
first then to high to guarantee the state transition successfully.

Signed-off-by: Dong Aisheng <b29396@freescale.com>
Acked-by: Jason Liu <r64343@freescale.com>
arch/arm/mach-mx6/board-mx6q_sabreauto.c

index e1df8723146cad8396611bb0be13a3e88aeacbe2..7c1fadaf1d47c7772ef4c8bc32baed3ced54dcfa 100644 (file)
@@ -1116,6 +1116,15 @@ static int flexcan1_en;
 static void mx6q_flexcan_switch(void)
 {
   if (flexcan0_en || flexcan1_en) {
+       /*
+        * The transceiver TJA1041A on sabreauto RevE baseboard will
+        * fail to transit to Normal state if EN/STBY is high by default
+        * after board power up. So we set the EN/STBY initial state to low
+        * first then to high to guarantee the state transition successfully.
+        */
+       gpio_set_value_cansleep(SABREAUTO_CAN_EN, 0);
+       gpio_set_value_cansleep(SABREAUTO_CAN_STBY, 0);
+
        gpio_set_value_cansleep(SABREAUTO_CAN_EN, 1);
        gpio_set_value_cansleep(SABREAUTO_CAN_STBY, 1);
        /* Enable STEER pin if CAN1 interface is required.