patacongo commented on a change in pull request #1233: URL: https://github.com/apache/incubator-nuttx/pull/1233#discussion_r439834486
########## File path: include/nuttx/net/net.h ########## @@ -155,7 +155,8 @@ enum net_lltype_e NET_LL_BLUETOOTH, /* Bluetooth */ NET_LL_IEEE80211, /* IEEE 802.11 */ NET_LL_IEEE802154, /* IEEE 802.15.4 MAC */ - NET_LL_PKTRADIO /* Non-standard packet radio */ + NET_LL_PKTRADIO, /* Non-standard packet radio */ + NET_LL_MBIM Review comment: What concerns me most is that NET_LL_MBIN is defined but used only in netdev_register(). For other MAC layers, there are numerous references throughout the networking (see below). My gut says that the the NET_LL_MBIM must be integrated into the network in many of these places too. Certainly ALL of these must be reviewed and those that require modification must be fixed: $ grep -r NET_LL_ net | grep -v NET_LL_HDRLEN net/arp/arp_send.c: if (dev->d_lltype != NET_LL_ETHERNET && net/arp/arp_send.c: dev->d_lltype != NET_LL_IEEE80211) net/arp/arp_table.c: if (dev->d_lltype != NET_LL_ETHERNET && net/arp/arp_table.c: dev->d_lltype != NET_LL_IEEE80211) net/bluetooth/bluetooth_finddev.c: if (dev->d_lltype == NET_LL_BLUETOOTH && dev->d_mac.radio.nv_addrlen > 0) net/bluetooth/bluetooth_recvfrom.c: if (dev->d_lltype != NET_LL_BLUETOOTH) net/bluetooth/bluetooth_sendto.c: if (dev->d_lltype != NET_LL_BLUETOOTH) net/devif/devif_poll.c: if (dev->d_lltype == NET_LL_IEEE802154 || net/devif/devif_poll.c: dev->d_lltype == NET_LL_PKTRADIO) net/ieee802154/ieee802154_finddev.c: if (dev->d_lltype == NET_LL_IEEE802154 && dev->d_mac.radio.nv_addrlen > 0) net/ieee802154/ieee802154_recvfrom.c: if (dev->d_lltype != NET_LL_IEEE802154) net/ieee802154/ieee802154_sendto.c: if (dev->d_lltype != NET_LL_IEEE802154) net/ipforward/ipfwd_poll.c: if (dev->d_lltype == NET_LL_IEEE802154 || net/ipforward/ipfwd_poll.c: dev->d_lltype == NET_LL_PKTRADIO) net/ipforward/ipfwd_poll.c: if (dev->d_lltype == NET_LL_IEEE802154 || net/ipforward/ipfwd_poll.c: dev->d_lltype == NET_LL_PKTRADIO) net/ipforward/ipv6_forward.c: if (fwddev->d_lltype != NET_LL_IEEE802154 && net/ipforward/ipv6_forward.c: fwddev->d_lltype != NET_LL_PKTRADIO) net/neighbor/neighbor_out.c: case NET_LL_ETHERNET: net/neighbor/neighbor_out.c: case NET_LL_IEEE80211: net/netdev/netdev_default.c: if (dev->d_lltype != NET_LL_LOOPBACK) net/netdev/netdev_ioctl.c: if (dev != NULL && dev->d_lltype == NET_LL_BLUETOOTH) net/netdev/netdev_ioctl.c: if (dev != NULL && dev->d_lltype == NET_LL_IEEE802154) net/netdev/netdev_ioctl.c: if (dev != NULL && dev->d_lltype == NET_LL_PKTRADIO) net/netdev/netdev_ioctl.c: if (dev->d_lltype == NET_LL_ETHERNET || net/netdev/netdev_ioctl.c: dev->d_lltype == NET_LL_IEEE80211) net/netdev/netdev_ioctl.c: if (dev->d_lltype == NET_LL_IEEE802154 || net/netdev/netdev_ioctl.c: dev->d_lltype == NET_LL_PKTRADIO) net/netdev/netdev_ioctl.c: if (dev->d_lltype == NET_LL_ETHERNET || net/netdev/netdev_ioctl.c: dev->d_lltype == NET_LL_IEEE80211) net/netdev/netdev_ioctl.c: if (dev->d_lltype == NET_LL_IEEE802154 || net/netdev/netdev_ioctl.c: dev->d_lltype == NET_LL_PKTRADIO) net/netdev/netdev_lladdrsize.c: case NET_LL_ETHERNET: net/netdev/netdev_lladdrsize.c: case NET_LL_IEEE80211: net/netdev/netdev_lladdrsize.c: case NET_LL_BLUETOOTH: net/netdev/netdev_lladdrsize.c: case NET_LL_IEEE802154: net/netdev/netdev_lladdrsize.c: case NET_LL_PKTRADIO: net/netdev/netdev_lladdrsize.c: case NET_LL_BLUETOOTH: net/netdev/netdev_register.c: case NET_LL_LOOPBACK: /* Local loopback */ net/netdev/netdev_register.c: case NET_LL_ETHERNET: /* Ethernet */ net/netdev/netdev_register.c: case NET_LL_IEEE80211: /* IEEE 802.11 */ net/netdev/netdev_register.c: case NET_LL_BLUETOOTH: /* Bluetooth */ net/netdev/netdev_register.c: case NET_LL_IEEE802154: /* IEEE 802.15.4 MAC */ net/netdev/netdev_register.c: case NET_LL_PKTRADIO: /* Non-IEEE 802.15.4 packet radio */ net/netdev/netdev_register.c: case NET_LL_SLIP: /* Serial Line Internet Protocol (SLIP) */ net/netdev/netdev_register.c: case NET_LL_TUN: /* Virtual Network Device (TUN) */ net/netdev/netdev_register.c: if (lltype == NET_LL_LOOPBACK) net/pkt/pkt_sockif.c: if (dev->d_lltype != NET_LL_ETHERNET && net/pkt/pkt_sockif.c: dev->d_lltype != NET_LL_IEEE80211) net/procfs/netdev_statistics.c: case NET_LL_ETHERNET: net/procfs/netdev_statistics.c: case NET_LL_IEEE80211: net/procfs/netdev_statistics.c: case NET_LL_IEEE802154: net/procfs/netdev_statistics.c: case NET_LL_PKTRADIO: net/procfs/netdev_statistics.c: case NET_LL_LOOPBACK: net/procfs/netdev_statistics.c: case NET_LL_SLIP: net/procfs/netdev_statistics.c: case NET_LL_PPP: net/procfs/netdev_statistics.c: case NET_LL_TUN: net/sixlowpan/sixlowpan_framelist.c: if (radio->r_dev.d_lltype == NET_LL_IEEE802154) net/sixlowpan/sixlowpan_send.c: if (dev->d_lltype != NET_LL_IEEE802154 && net/sixlowpan/sixlowpan_send.c: dev->d_lltype != NET_LL_PKTRADIO) net/sixlowpan/sixlowpan_tcpsend.c: if (dev->d_lltype != NET_LL_IEEE802154 && net/sixlowpan/sixlowpan_tcpsend.c: dev->d_lltype != NET_LL_PKTRADIO) net/sixlowpan/sixlowpan_tcpsend.c: if (dev->d_lltype != NET_LL_IEEE802154 && net/sixlowpan/sixlowpan_tcpsend.c: dev->d_lltype != NET_LL_PKTRADIO) net/sixlowpan/sixlowpan_udpsend.c: if (dev->d_lltype != NET_LL_IEEE802154 && net/sixlowpan/sixlowpan_udpsend.c: dev->d_lltype != NET_LL_PKTRADIO) net/sixlowpan/sixlowpan_utils.c: if (radio->r_dev.d_lltype == NET_LL_PKTRADIO) net/sixlowpan/sixlowpan_utils.c: if (radio->r_dev.d_lltype == NET_LL_IEEE802154) net/sixlowpan/sixlowpan_utils.c: if (radio->r_dev.d_lltype == NET_LL_IEEE802154) ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org