normanr commented on code in PR #4335: URL: https://github.com/apache/incubator-nuttx/pull/4335#discussion_r907084014
########## arch/risc-v/src/bl602/bl602_netdev.c: ########## @@ -2120,10 +2122,12 @@ void bl602_net_event(int evt, int val) case CODE_WIFI_ON_DISCONNECT: do { - struct bl602_net_driver_s *priv = &g_bl602_net[0]; + /* struct bl602_net_driver_s *priv = &g_bl602_net[0]; */ + if (g_state.sta_connected == 1) { - netdev_carrier_off(&priv->net_dev); + /* netdev_carrier_off(&priv->net_dev); */ Review Comment: It was included in https://github.com/apache/incubator-nuttx/commit/d489392d08e550e828146395d4e945de9952e6e3 (which was merged) though. To me it makes more sense to _have_ the call to `netdev_carrier_off` in `CODE_WIFI_ON_DISCONNECT` (so that userspace can detect the disconnection), and to _not_ have the call to `wifi_mgmr_sta_autoconnect_disable` in `CODE_WIFI_ON_CONNECTED` (so that `CODE_WIFI_CMD_RECONNECT` can trigger correctly). Thoughts? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org