anchao commented on code in PR #7616: URL: https://github.com/apache/nuttx/pull/7616#discussion_r1037520421
########## include/nuttx/net/netdev.h: ########## @@ -154,17 +157,25 @@ # define NETDEV_ERRORS(dev) #endif -/* There are some helper pointers for accessing the contents of the Ethernet - * headers +/* There are some helper pointers for accessing the contents of the Link + * layer headers */ -#define ETHBUF ((FAR struct eth_hdr_s *)&dev->d_buf[0]) +#define LLBUF ((FAR void *)(dev->d_iob ? \ + &dev->d_iob->io_data[CONFIG_NET_LL_GUARDSIZE - \ Review Comment: Some common code still use ETHBUF, in these drivers, they can only use flat buffer(d_buf) #define LLBUF ((FAR void *)(dev->d_iob ? \ #define ETHBUF ((FAR struct eth_hdr_s *)LLBUF) -- 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