net/fec: add mac field into platform data and consolidate fec_get_mac
Add mac field into fec_platform_data and consolidate function
fec_get_mac to get mac address in following order.
1) module parameter via kernel command line fec.macaddr=0x00,0x04,...
2) from flash in case of CONFIG_M5272 or fec_platform_data mac
field for others, which typically have mac stored in fuse
3) fec mac address registers set by bootloader
Signed-off-by: Shawn Guo <shawn.guo@freescale.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
8649a230e3
commit
49da97dcb6
2 changed files with 41 additions and 43 deletions
|
|
@ -3,6 +3,8 @@
|
|||
* Copyright (c) 2009 Orex Computed Radiography
|
||||
* Baruch Siach <baruch@tkos.co.il>
|
||||
*
|
||||
* Copyright (C) 2010 Freescale Semiconductor, Inc.
|
||||
*
|
||||
* Header file for the FEC platform data
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
|
|
@ -16,6 +18,7 @@
|
|||
|
||||
struct fec_platform_data {
|
||||
phy_interface_t phy;
|
||||
unsigned char mac[ETH_ALEN];
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue