lkml.org 
[lkml]   [2013]   [Aug]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH V2 3/3] ethernet: Convert mac address uses of 6 to ETH_ALEN
From
Hi,

On Thu, Aug 1, 2013 at 1:14 PM, Joe Perches <joe@perches.com> wrote:

> diff --git a/drivers/net/ethernet/pasemi/pasemi_mac.h b/drivers/net/ethernet/pasemi/pasemi_mac.h
> index e2f4efa..649fdb4 100644
> --- a/drivers/net/ethernet/pasemi/pasemi_mac.h
> +++ b/drivers/net/ethernet/pasemi/pasemi_mac.h
> @@ -79,11 +79,11 @@ struct pasemi_mac {
> int last_cs;
> int num_cs;
> u32 dma_if;
> - u8 type;
> #define MAC_TYPE_GMAC 1
> #define MAC_TYPE_XAUI 2
>
> - u8 mac_addr[6];
> + u8 mac_addr[ETH_ALEN];
> + u8 type;

Just promote 'type' to u32 instead, saves you from moving the #defines
down, etc, etc.


-Olof


\
 
 \ /
  Last update: 2013-08-01 23:01    [W:0.062 / U:0.036 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site