can: m_can: Set pinmux into "default" state on start
Subsystems (4)
PATCH 1/1 can: m_can: Set pinmux into "default" state on start
On systems like stm32mp1 where pins have both "default" and "sleep" pinmux states in DT, the pins are in "sleep" state by default. Switch the pins into the "default" state when bringing the interface up in m_can_start(), because otherwise no CAN communication is possible. This replicates the behavior of the resume path, which does the same.
--- drivers/net/can/m_can/m_can.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/net/can/m_can/m_can.c +2 -0
@@ -1247,6 +1247,8 @@ static void m_can_start(struct net_device *dev)/* basic m_can configuration */ m_can_chip_config (dev); +pinctrl_pm_select_default_state (cdev->dev); + cdev->can.state =CAN_STATE_ERROR_ACTIVE ;m_can_enable_all_interrupts (cdev);
Signature · 1 line
2.25.1
Quoted 21 lines · Marek Vasut
On systems like stm32mp1 where pins have both "default" and "sleep" pinmux states in DT, the pins are in "sleep" state by default. Switch the pins into the "default" state when bringing the interface up in
m_can_start(), because otherwise no CAN communication is possible. This replicates the behavior of the resume path, which does the same.Signed-off-by Marek Vasut <[email protected]>Cc Alexandre Torgue <[email protected]>Cc Marc Kleine-Budde <[email protected]>Cc Wolfgang Grandegger <[email protected]>--- drivers/net/can/m_can/m_can.c | 2 ++ 1 file changed, 2 insertions(+)drivers/net/can/m_can/m_can.c +0
-0
drivers/net/can/m_can/m_can.c static void m_can_start(struct net_device *dev) · line 1254
Quoted 8 lines
drivers/net/can/m_can/m_can.c +2
-0@@ -1247,6 +1247,8 @@ static void m_can_start(struct net_device *dev)/* basic m_can configuration */ m_can_chip_config (dev); +pinctrl_pm_select_default_state (cdev->dev); + cdev->can.state =CAN_STATE_ERROR_ACTIVE ;m_can_enable_all_interrupts (cdev);
Any news on this ?
Quoted 24 lines · Marek Vasut
Quoted 23 lines · Marek Vasut
On systems like stm32mp1 where pins have both "default" and "sleep" pinmux states in DT, the pins are in "sleep" state by default. Switch the pins into the "default" state when bringing the interface up in
m_can_start(), because otherwise no CAN communication is possible. This replicates the behavior of the resume path, which does the same.Signed-off-by Marek Vasut <[email protected]>Cc Alexandre Torgue <[email protected]>Cc Marc Kleine-Budde <[email protected]>Cc Wolfgang Grandegger <[email protected]>--- drivers/net/can/m_can/m_can.c | 2 ++ 1 file changed, 2 insertions(+)drivers/net/can/m_can/m_can.c +0
-0@@ -1247,6 +1247,8 @@ static void m_can_start(struct net_device *dev)/* basic m_can configuration */ m_can_chip_config (dev);
Quoted 8 lines
drivers/net/can/m_can/m_can.c static void m_can_start(struct net_device *dev) · line 1254
Quoted 6 lines
drivers/net/can/m_can/m_can.c +2
-0+pinctrl_pm_select_default_state (cdev->dev); + cdev->can.state =CAN_STATE_ERROR_ACTIVE ;m_can_enable_all_interrupts (cdev);Any news on this ?
Almost another month has passed by, ping ?
Quoted 29 lines · Marek Vasut
Quoted 28 lines · Marek Vasut
Quoted 27 lines · Marek Vasut
On systems like stm32mp1 where pins have both "default" and "sleep" pinmux states in DT, the pins are in "sleep" state by default. Switch the pins into the "default" state when bringing the interface up in
m_can_start(), because otherwise no CAN communication is possible. This replicates the behavior of the resume path, which does the same.Signed-off-by Marek Vasut <[email protected]>Cc Alexandre Torgue <[email protected]>Cc Marc Kleine-Budde <[email protected]>Cc Wolfgang Grandegger <[email protected]>--- drivers/net/can/m_can/m_can.c | 2 ++ 1 file changed, 2 insertions(+)drivers/net/can/m_can/m_can.c +2
-0@@ -1247,6 +1247,8 @@ static void m_can_start(struct net_device *dev)/* basic m_can configuration */ m_can_chip_config (dev); +pinctrl_pm_select_default_state (cdev->dev); + cdev->can.state =CAN_STATE_ERROR_ACTIVE ;
Quoted 6 lines
Quoted 4 lines
drivers/net/can/m_can/m_can.c static void m_can_start(struct net_device *dev) · line 1254
Quoted 2 lines
drivers/net/can/m_can/m_can.c +0
-0m_can_enable_all_interrupts (cdev);Any news on this ?
Almost another month has passed by, ping ?
Bump ?