[ovs-dev] [compat 6/6] datapath: Introduce more compat support for <net/netlink.h>.

Ben Pfaff blp at nicira.com
Mon Dec 13 18:19:59 UTC 2010


On Sat, Dec 11, 2010 at 03:01:45PM -0800, Jesse Gross wrote:
> On Fri, Dec 10, 2010 at 2:47 PM, Ben Pfaff <blp at nicira.com> wrote:
> > +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,34)
> > +/* This function was introduced in 2.6.31, but initially it performed an
> > + * unaligned access, so we replace it up to 2.6.34 where it was fixed.  */
> > +#define nla_get_be64 rpl_nla_get_be64
> > +static inline __be64 nla_get_be64(const struct nlattr *nla)
> > +{
> > +        __be64 tmp;
> > +
> > +       /* The additional cast is necessary because  */
> > +        nla_memcpy(&tmp, (struct nlattr *) nla, sizeof(tmp));
> > +
> > +        return tmp;
> > +}
> > +#endif  /* !HAVE_NLA_GET_BE64 */
> 
> There isn't a HAVE_NLA_GET_BE64 - the test is based on version.

Thanks, I deleted that comment.




More information about the dev mailing list