On 31 Aug 2014, at 13:58 , Bjoern A. Zeeb <b...@freebsd.org> wrote:

> 
> On 31 Aug 2014, at 13:30 , Gleb Smirnoff <gleb...@freebsd.org> wrote:
> 
>> Author: glebius
>> Date: Sun Aug 31 13:30:54 2014
>> New Revision: 270877
>> URL: http://svnweb.freebsd.org/changeset/base/270877
>> 
>> Log:
>> Toss fields so that no padding field is required to achieve alignment.
>> 
>> Modified:
>> head/sys/net/if_var.h
>> 
>> Modified: head/sys/net/if_var.h
>> ==============================================================================
>> --- head/sys/net/if_var.h    Sun Aug 31 12:48:13 2014        (r270876)
>> +++ head/sys/net/if_var.h    Sun Aug 31 13:30:54 2014        (r270877)
>> @@ -146,11 +146,11 @@ struct ifnet {
>> 
>>      /* Variable fields that are touched by the stack and drivers. */
>>      int     if_flags;               /* up/down, broadcast, etc. */
>> +    int     if_drv_flags;           /* driver-managed status flags */
>>      int     if_capabilities;        /* interface features & capabilities */
>>      int     if_capenable;           /* enabled features & capabilities */
>>      void    *if_linkmib;            /* link-type-specific MIB data */
>>      size_t  if_linkmiblen;          /* length of above data */
>> -    int     if_drv_flags;           /* driver-managed status flags */
>>      u_int   if_refcount;            /* reference count */
>> 
>>      /* These fields are shared with struct if_data. */
>> @@ -158,7 +158,6 @@ struct ifnet {
>>      uint8_t         if_addrlen;     /* media address length */
>>      uint8_t         if_hdrlen;      /* media header length */
>>      uint8_t         if_link_state;  /* current link state */
>> -    uint32_t        if_spare32;
> 
> Doesn’t this leave a gap on 64bit alignment now again?

Disregard.  It’s fine.

> 
>>      uint32_t        if_mtu;         /* maximum transmission unit */
>>      uint32_t        if_metric;      /* routing metric (external only) */
>>      uint64_t        if_baudrate;    /* linespeed */
>> 
> 
> — 
> Bjoern A. Zeeb             "Come on. Learn, goddamn it.", WarGames, 1983
> 
> 

— 
Bjoern A. Zeeb             "Come on. Learn, goddamn it.", WarGames, 1983

_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to