Samuel Thibault, le lun. 10 févr. 2025 13:57:46 +0100, a ecrit:
> Flavio Cruz, le dim. 09 févr. 2025 22:36:30 -0500, a ecrit:
> > * pfinet/linux-src/net/ipv4/{tcp,udp}_ipv4.c: mark lookup functions as
> >   extern since they are used in another module (icmp.c) and shouldn't be
> >   removed.
> 
> > diff --git a/pfinet/linux-src/net/ipv4/tcp_ipv4.c 
> > b/pfinet/linux-src/net/ipv4/tcp_ipv4.c
> > index 8a5f7175..e67137e4 100644
> > --- a/pfinet/linux-src/net/ipv4/tcp_ipv4.c
> > +++ b/pfinet/linux-src/net/ipv4/tcp_ipv4.c
> > @@ -448,7 +448,7 @@ hit:
> >     return sk;
> >  }
> >  
> > -__inline__ struct sock *tcp_v4_lookup(u32 saddr, u16 sport, u32 daddr, u16 
> > dport, int dif)
> > +extern __inline__ struct sock *tcp_v4_lookup(u32 saddr, u16 sport, u32 
> > daddr, u16 dport, int dif)
> >  {
> >     return __tcp_v4_lookup(0, saddr, sport, daddr, dport, dif);
> >  }
> 
> I don't remember the details of what we currently have, but iirc in
> some compilation cases, setting extern inline on a function tells the
> compiler that this is a possible inline but if the compiler prefers not
> to inline, it can just emit a reference, and a definition is available
> somewhere else. Thus why we have FOO_EI in variouis headers headers.
> 
> It'd probably be simpler to just drop the __inline__ keyword, it's not
> that performance sensitive?

I have done so and pushed.

Thanks!
Samuel

Reply via email to