net: unify FAR keyword usage for all net buffer memory mapped buffers

Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
This commit is contained in:
Petro Karashchenko 2022-01-18 00:09:14 +02:00 committed by Xiang Xiao
parent fc3167b584
commit 08043fb5bc
66 changed files with 108 additions and 108 deletions

View file

@ -281,7 +281,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)priv->c_dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->c_dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -260,7 +260,7 @@
* the contents of the Ethernet header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
#define IMX_BUF_SIZE ENET_ALIGN_UP(CONFIG_NET_ETH_PKTSIZE)

View file

@ -244,7 +244,7 @@
* the contents of the Ethernet header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
#define IMXRT_BUF_SIZE ENET_ALIGN_UP(CONFIG_NET_ETH_PKTSIZE + \
CONFIG_NET_GUARDSIZE)

View file

@ -194,7 +194,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
#define KINETIS_BUF_SIZE ((CONFIG_NET_ETH_PKTSIZE & 0xfffffff0) + 0x10)

View file

@ -165,7 +165,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)priv->lp_dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->lp_dev.d_buf)
/* This is the number of ethernet GPIO pins that must be configured */

View file

@ -498,7 +498,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -257,8 +257,8 @@
* header.
*/
#define ETHBUF ((struct eth_hdr_s *)priv->eth_dev.d_buf)
#define ETH8021QWBUF ((struct eth_8021qhdr_s *)priv->eth_dev.d_buf)
#define ETHBUF ((FAR struct eth_hdr_s *)priv->eth_dev.d_buf)
#define ETH8021QWBUF ((FAR struct eth_8021qhdr_s *)priv->eth_dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -156,7 +156,7 @@ void amebaz_netdev_notify_receive(FAR struct amebaz_dev_s *priv,
NETDEV_RXPACKETS(&priv->dev);
net_lock();
oldbuf = priv->dev.d_buf;
hdr = (struct eth_hdr_s *)skb->data;
hdr = (FAR struct eth_hdr_s *)skb->data;
priv->dev.d_buf = (void *)skb->data;
priv->dev.d_len = len;
#ifdef CONFIG_NET_PKT

View file

@ -239,7 +239,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
#define S32K1XX_BUF_SIZE ENET_ALIGN_UP(CONFIG_NET_ETH_PKTSIZE)

View file

@ -236,7 +236,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -267,7 +267,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -314,7 +314,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -193,7 +193,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -190,7 +190,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -410,7 +410,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -607,7 +607,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -594,7 +594,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -599,7 +599,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -167,7 +167,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define ETHBUF ((struct eth_hdr_s *)priv->ld_dev.d_buf)
#define ETHBUF ((FAR struct eth_hdr_s *)priv->ld_dev.d_buf)
#define TIVA_MAX_MDCCLK 2500000

View file

@ -615,7 +615,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -69,7 +69,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)priv->d_dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->d_dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -215,7 +215,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->pd_dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->pd_dev.d_buf)
/* PHYs *********************************************************************/

View file

@ -254,7 +254,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->pd_dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->pd_dev.d_buf)
/* PHYs *********************************************************************/

View file

@ -88,7 +88,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)priv->misoc_net_dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->misoc_net_dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -198,7 +198,7 @@
* header
*/
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/* PHY return definitions */

View file

@ -1077,7 +1077,7 @@ static void wlan_txtimeout_expiry(wdparm_t arg)
static void wlan_poll_work(void *arg)
{
int32_t delay_tick = WLAN_WDDELAY;
FAR struct wlan_priv_s *priv = (FAR struct wlan_priv_s *)arg;
struct wlan_priv_s *priv = (struct wlan_priv_s *)arg;
struct net_driver_s *dev = &priv->dev;
struct wlan_pktbuf *pktbuf;

View file

@ -255,7 +255,7 @@ extern uintptr_t _RAM_ADDR_U_INIT_PARAM;
/* This is a helper pointer for accessing the contents of Ethernet header */
#define ETHBUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define ETHBUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -281,7 +281,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)priv->dm_dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dm_dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -181,7 +181,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/* Debug ********************************************************************/

View file

@ -164,7 +164,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->dev.d_buf)
/* Debug ********************************************************************/

View file

@ -95,7 +95,7 @@
* header.
*/
#define BUF ((struct eth_hdr_s *)priv->ft_dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->ft_dev.d_buf)
/* RX/TX buffer alignment */

View file

@ -457,8 +457,8 @@ static int net_rpmsg_drv_sockioctl_handler(FAR struct rpmsg_endpoint *ept,
static bool net_rpmsg_drv_is_ipv4(FAR struct net_driver_s *dev)
{
FAR struct ipv4_hdr_s *ip =
(struct ipv4_hdr_s *)(dev->d_buf + dev->d_llhdrlen);
FAR struct eth_hdr_s *eth = (struct eth_hdr_s *)dev->d_buf;
(FAR struct ipv4_hdr_s *)(dev->d_buf + dev->d_llhdrlen);
FAR struct eth_hdr_s *eth = (FAR struct eth_hdr_s *)dev->d_buf;
if (dev->d_lltype == NET_LL_ETHERNET || dev->d_lltype == NET_LL_IEEE80211)
{
@ -475,8 +475,8 @@ static bool net_rpmsg_drv_is_ipv4(FAR struct net_driver_s *dev)
static bool net_rpmsg_drv_is_ipv6(FAR struct net_driver_s *dev)
{
FAR struct ipv6_hdr_s *ip =
(struct ipv6_hdr_s *)(dev->d_buf + dev->d_llhdrlen);
FAR struct eth_hdr_s *eth = (struct eth_hdr_s *)dev->d_buf;
(FAR struct ipv6_hdr_s *)(dev->d_buf + dev->d_llhdrlen);
FAR struct eth_hdr_s *eth = (FAR struct eth_hdr_s *)dev->d_buf;
if (dev->d_lltype == NET_LL_ETHERNET || dev->d_lltype == NET_LL_IEEE80211)
{
@ -492,7 +492,7 @@ static bool net_rpmsg_drv_is_ipv6(FAR struct net_driver_s *dev)
#ifdef CONFIG_NET_ARP
static bool net_rpmsg_drv_is_arp(FAR struct net_driver_s *dev)
{
FAR struct eth_hdr_s *eth = (struct eth_hdr_s *)dev->d_buf;
FAR struct eth_hdr_s *eth = (FAR struct eth_hdr_s *)dev->d_buf;
if (dev->d_lltype == NET_LL_ETHERNET || dev->d_lltype == NET_LL_IEEE80211)
{

View file

@ -88,7 +88,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)priv->sk_dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->sk_dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -102,7 +102,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)self->dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)self->dev.d_buf)
/****************************************************************************
* Private Types

View file

@ -2271,7 +2271,7 @@ static void cdcmbim_receive(struct usbhost_cdcmbim_s *priv,
priv->netdev.d_buf = buf;
priv->netdev.d_len = len;
switch (((struct ipv4_hdr_s *)buf)->vhl & IP_VERSION_MASK)
switch (((FAR struct ipv4_hdr_s *)buf)->vhl & IP_VERSION_MASK)
{
#ifdef CONFIG_NET_IPv4
case IPv4_VERSION:

View file

@ -95,7 +95,7 @@
/* This is a helper pointer for accessing the contents of Ethernet header */
#define BUF ((struct eth_hdr_s *)priv->bc_dev.d_buf)
#define BUF ((FAR struct eth_hdr_s *)priv->bc_dev.d_buf)
/****************************************************************************
* Private Function Prototypes

View file

@ -451,7 +451,7 @@ typedef CODE int (*devif_poll_callback_t)(FAR struct net_driver_s *dev);
* Ethernet, you will need to call the network ARP code before calling
* this function:
*
* #define BUF ((struct eth_hdr_s *)&dev->d_buf[0])
* #define BUF ((FAR struct eth_hdr_s *)&dev->d_buf[0])
* dev->d_len = ethernet_devicedrver_poll();
* if (dev->d_len > 0)
* {

View file

@ -59,8 +59,8 @@
* Pre-processor Definitions
****************************************************************************/
#define ETHBUF ((struct eth_hdr_s *)&dev->d_buf[0])
#define ARPBUF ((struct arp_hdr_s *)&dev->d_buf[ETH_HDRLEN])
#define ETHBUF ((FAR struct eth_hdr_s *)&dev->d_buf[0])
#define ARPBUF ((FAR struct arp_hdr_s *)&dev->d_buf[ETH_HDRLEN])
/****************************************************************************
* Public Functions

View file

@ -59,8 +59,8 @@
* Pre-processor Definitions
****************************************************************************/
#define ETHBUF ((struct eth_hdr_s *)&dev->d_buf[0])
#define ARPBUF ((struct arp_hdr_s *)&dev->d_buf[ETH_HDRLEN])
#define ETHBUF ((FAR struct eth_hdr_s *)&dev->d_buf[0])
#define ARPBUF ((FAR struct arp_hdr_s *)&dev->d_buf[ETH_HDRLEN])
/****************************************************************************
* Public Functions

View file

@ -56,8 +56,8 @@
* Pre-processor Definitions
****************************************************************************/
#define ETHBUF ((struct eth_hdr_s *)&dev->d_buf[0])
#define IPBUF ((struct arp_iphdr_s *)&dev->d_buf[ETH_HDRLEN])
#define ETHBUF ((FAR struct eth_hdr_s *)&dev->d_buf[0])
#define IPBUF ((FAR struct arp_iphdr_s *)&dev->d_buf[ETH_HDRLEN])
/****************************************************************************
* Public Functions

View file

@ -59,9 +59,9 @@
* Pre-processor Definitions
****************************************************************************/
#define ETHBUF ((struct eth_hdr_s *)&dev->d_buf[0])
#define ARPBUF ((struct arp_hdr_s *)&dev->d_buf[ETH_HDRLEN])
#define IPBUF ((struct arp_iphdr_s *)&dev->d_buf[ETH_HDRLEN])
#define ETHBUF ((FAR struct eth_hdr_s *)&dev->d_buf[0])
#define ARPBUF ((FAR struct arp_hdr_s *)&dev->d_buf[ETH_HDRLEN])
#define IPBUF ((FAR struct arp_iphdr_s *)&dev->d_buf[ETH_HDRLEN])
/****************************************************************************
* Private Data

View file

@ -110,7 +110,7 @@
/* Macros */
#define BUF ((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define BUF ((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
/****************************************************************************
* Private Data

View file

@ -43,8 +43,8 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv4BUF ((struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define ICMPBUF ((struct icmp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define IPv4BUF ((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define ICMPBUF ((FAR struct icmp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define ICMPSIZE ((dev)->d_len - IPv4_HDRLEN)
/****************************************************************************

View file

@ -51,7 +51,7 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv4BUF ((struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv4BUF ((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
/* RFC 1812:
* 4.3.2.3, Original Message Header
@ -93,7 +93,7 @@ void icmp_reply(FAR struct net_driver_s *dev, int type, int code)
{
int ipicmplen = IPv4_HDRLEN + sizeof(struct icmp_hdr_s);
FAR struct ipv4_hdr_s *ipv4 = IPv4BUF;
FAR struct icmp_hdr_s *icmp = (FAR void *)(ipv4 + 1);
FAR struct icmp_hdr_s *icmp = (FAR struct icmp_hdr_s *)(ipv4 + 1);
uint16_t datalen;
#ifdef CONFIG_NET_BROADCAST
const in_addr_t bcast = INADDR_BROADCAST;

View file

@ -60,9 +60,9 @@
****************************************************************************/
#define IPv4BUF \
((struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define ICMPBUF \
((struct icmp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
((FAR struct icmp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
/****************************************************************************
* Private Types

View file

@ -45,10 +45,10 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define ICMPv6ADVERTISE \
((struct icmpv6_neighbor_advertise_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
((FAR struct icmpv6_neighbor_advertise_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Public Functions

View file

@ -52,9 +52,9 @@
#define ICMPv6REPLY ((FAR struct icmpv6_echo_reply_s *)icmpv6)
#define ICMPv6SIZE ((dev)->d_len - iplen)
#define ICMPv6SOLICIT ((struct icmpv6_neighbor_solicit_s *)icmpv6)
#define ICMPv6ADVERTISE ((struct icmpv6_neighbor_advertise_s *)icmpv6)
#define ICMPv6RADVERTISE ((struct icmpv6_router_advertise_s *)icmpv6)
#define ICMPv6SOLICIT ((FAR struct icmpv6_neighbor_solicit_s *)icmpv6)
#define ICMPv6ADVERTISE ((FAR struct icmpv6_neighbor_advertise_s *)icmpv6)
#define ICMPv6RADVERTISE ((FAR struct icmpv6_router_advertise_s *)icmpv6)
#define MLDQUERY ((FAR struct mld_mcast_listen_query_s *)icmpv6)
#define MLDREPORT_V1 ((FAR struct mld_mcast_listen_report_v1_s *)icmpv6)

View file

@ -45,10 +45,10 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define ICMPv6ADVERTISE \
((struct icmpv6_router_advertise_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
((FAR struct icmpv6_router_advertise_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Private Data

View file

@ -44,9 +44,9 @@
****************************************************************************/
#define IPv6_BUF \
((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define ICMPv6_BUF \
((struct icmpv6_echo_reply_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
((FAR struct icmpv6_echo_reply_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
#define ICMPv6_SIZE \
((dev)->d_len - IPv6_HDRLEN)

View file

@ -51,7 +51,7 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
/* The latest drafts declared increase in minimal mtu up to 1280. */
@ -88,7 +88,7 @@ void icmpv6_reply(FAR struct net_driver_s *dev, int type, int code, int data)
{
int ipicmplen = IPv6_HDRLEN + sizeof(struct icmpv6_hdr_s);
FAR struct ipv6_hdr_s *ipv6 = IPv6BUF;
FAR struct icmpv6_hdr_s *icmpv6 = (FAR void *)(ipv6 + 1);
FAR struct icmpv6_hdr_s *icmpv6 = (FAR struct icmpv6_hdr_s *)(ipv6 + 1);
uint16_t datalen;
if (net_ipv6addr_cmp(ipv6->destipaddr, g_ipv6_unspecaddr)

View file

@ -43,9 +43,9 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define ICMPv6RSOLICIT \
((struct icmpv6_router_solicit_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
((FAR struct icmpv6_router_solicit_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Public Functions

View file

@ -59,9 +59,9 @@
****************************************************************************/
#define IPv6BUF \
((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define ICMPv6BUF \
((struct icmpv6_echo_request_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
((FAR struct icmpv6_echo_request_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Private Types

View file

@ -43,9 +43,9 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define ICMPv6SOLICIT \
((struct icmpv6_neighbor_solicit_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
((FAR struct icmpv6_neighbor_solicit_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Private Data

View file

@ -52,7 +52,7 @@
/* Buffer access helpers */
#define TCPBUF(dev) ((FAR struct tcp_hdr_s *)(&(dev)->d_buf[IPv6_HDRLEN]))
#define TCPBUF(dev) ((FAR struct tcp_hdr_s *)(&(dev)->d_buf[IPv6_HDRLEN]))
/****************************************************************************
* Pre-processor Definitions

View file

@ -72,8 +72,8 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv4BUF ((struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv4BUF ((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
/****************************************************************************
* Private Data

View file

@ -46,11 +46,11 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv4BUF ((struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv4BUF ((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define TCPIPv4BUF ((struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define TCPIPv6BUF ((struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
#define TCPIPv4BUF ((FAR struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define TCPIPv6BUF ((FAR struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Private Types

View file

@ -66,11 +66,11 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv4BUF ((struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv4BUF ((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define TCPIPv4BUF ((struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define TCPIPv6BUF ((struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
#define TCPIPv4BUF ((FAR struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define TCPIPv6BUF ((FAR struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Private Functions
@ -649,7 +649,7 @@ uint16_t tcp_rx_mss(FAR struct net_driver_s *dev)
void tcp_synack(FAR struct net_driver_s *dev, FAR struct tcp_conn_s *conn,
uint8_t ack)
{
struct tcp_hdr_s *tcp;
FAR struct tcp_hdr_s *tcp;
uint16_t tcp_mss;
int16_t optlen = 0;

View file

@ -77,8 +77,8 @@
# define NEED_IPDOMAIN_SUPPORT 1
#endif
#define TCPIPv4BUF ((struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define TCPIPv6BUF ((struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
#define TCPIPv4BUF ((FAR struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define TCPIPv6BUF ((FAR struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/* Debug */

View file

@ -67,8 +67,8 @@
# define NEED_IPDOMAIN_SUPPORT 1
#endif
#define TCPIPv4BUF ((struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define TCPIPv6BUF ((struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
#define TCPIPv4BUF ((FAR struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define TCPIPv6BUF ((FAR struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Private Types

View file

@ -62,8 +62,8 @@
* Pre-processor Definitions
****************************************************************************/
#define TCPIPv4BUF ((struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define TCPIPv6BUF ((struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
#define TCPIPv4BUF ((FAR struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define TCPIPv6BUF ((FAR struct tcp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Private Types

View file

@ -72,8 +72,8 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv4BUF ((struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv4BUF ((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
/****************************************************************************
* Private Data

View file

@ -46,11 +46,11 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv4BUF ((struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv4BUF ((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define UDPIPv4BUF ((struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define UDPIPv6BUF ((struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
#define UDPIPv4BUF ((FAR struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define UDPIPv6BUF ((FAR struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Private Types

View file

@ -66,14 +66,14 @@
****************************************************************************/
#define IPv4BUF \
((struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF \
((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define UDPIPv4BUF \
((struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
((FAR struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define UDPIPv6BUF \
((struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
((FAR struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/****************************************************************************
* Public Functions

View file

@ -74,8 +74,8 @@
# define NEED_IPDOMAIN_SUPPORT 1
#endif
#define UDPIPv4BUF ((struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define UDPIPv6BUF ((struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
#define UDPIPv4BUF ((FAR struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv4_HDRLEN])
#define UDPIPv6BUF ((FAR struct udp_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev) + IPv6_HDRLEN])
/* Debug */

View file

@ -37,8 +37,8 @@
* Pre-processor Definitions
****************************************************************************/
#define IPv4BUF ((struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv4BUF ((FAR struct ipv4_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
#define IPv6BUF ((FAR struct ipv6_hdr_s *)&dev->d_buf[NET_LL_HDRLEN(dev)])
/****************************************************************************
* Public Functions

View file

@ -808,7 +808,7 @@ void nx_start(void)
{
#if CONFIG_TASK_NAME_SIZE > 0
_alert("Stack check failed, pid %d, name %s\n",
tcb->pid, tcb->name);
tcb->pid, tcb->name);
#else
_alert("Stack check failed, pid %d\n", tcb->pid);
#endif