You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by "xiaoxiang781216 (via GitHub)" <gi...@apache.org> on 2023/01/27 15:03:05 UTC

[GitHub] [nuttx] xiaoxiang781216 commented on a diff in pull request #8304: Added SocketCAN driver implementation to the tiva chip, modified the …

xiaoxiang781216 commented on code in PR #8304:
URL: https://github.com/apache/nuttx/pull/8304#discussion_r1089063052


##########
boards/arm/tiva/tm4c1294-launchpad/src/tm4c_can.c:
##########
@@ -115,11 +131,25 @@ int tm4c_can_setup(void)
       canerr("ERROR:  Failed to get/register CAN interface 1\n");
       return ret;
     }
+
+#    endif /* CONFIG_TIVA_CHAR_DEV_CAN */
+#    if defined(CONFIG_TIVA_SOCKET_CAN)
+  /* Call tiva_cansockinitialize() to get an instance of CAN interface 0
+   * and register it.
+   */
+
+  ret = tiva_cansockinitialize(0);
+  if (ret < 0)
+    {
+      canerr("ERROR:  Failed to get/register CAN interface 0\n");
+      return ret;
+    }
+#    endif /* CONFIG_TIVA_SOCKET_CAN */
 #  endif /* CONFIG_TIVA_CAN1 */
 
   return OK;
 
-configgpio_error:
+  configgpio_error:

Review Comment:
   revert the change?



-- 
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-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org