Hi Sylvian,

I think I actually use tcpip_input but please correct me if I'm doing
something wrong

this is how I add the netif:

// netif_add(&netif, &laddr, &netmask, &gw, 0, arm9emac_init,
arm9emac_low_level_input);
// netif_add(&netif, &laddr, &netmask, &gw, 0, arm9emac_init,
ethernet_input);
netif_add(&netif, &laddr, &netmask, &gw, 0, arm9emac_init, tcpip_input);
// netif_add(&netif, IPADDR_NONE, IPADDR_NONE, IPADDR_NONE, 0,
arm9emac_init, NULL);

Inside my callback if I change from ethernet_input to tcpip_input I can't
not longer ping the target. This is the callback, called by the emac rx
interrupt.

err_t arm9emac_low_level_input(struct pbuf *p, struct netif *netif)
{
 /* This means the pbuf is freed or consumed,
    so the caller doesn't have to free it again */
//  return ethernet_input(p, netif);
 return tcpip_input(p, netif);
}

On Thu, Jul 7, 2016 at 2:54 PM, Jaime Fernández <[email protected]>
wrote:

> Thanks Sylvain
>
> I will try today with tcpip_input and move to use the raw api. Thanks.
>
> Sent from my iPhone
>
> > On Jul 7, 2016, at 14:35, Sylvain Rochet <[email protected]> wrote:
> >
> > Hi Jaime,
> >
> >> On Thu, Jul 07, 2016 at 02:21:22PM -0500, Jaime Fernández wrote:
> >>
> >> Can the raw api be used with an OS or is it exclusively for none os
> >> implementations ?
> >
> > That's properly documented inside lwip/doc/rawapi.txt AFAIK.
> >
> > It can be used, but all raw API calls must be from the TCPIP thread
> > context. Remember, the raw API is *not* thread-safe.
> >
> > Sylvain
> > _______________________________________________
> > lwip-users mailing list
> > [email protected]
> > https://lists.nongnu.org/mailman/listinfo/lwip-users
>
_______________________________________________
lwip-users mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/lwip-users

Reply via email to