Hi Joe,

On Sat, Jan 23, 2016 at 6:32 AM, Joe Hershberger
<joe.hershber...@gmail.com> wrote:
> Hi Bin,
>
> On Sun, Jan 17, 2016 at 10:41 PM, Bin Meng <bmeng...@gmail.com> wrote:
>> Hi Simon,
>>
>> On Mon, Jan 18, 2016 at 5:51 AM, Simon Glass <s...@chromium.org> wrote:
>>> Move the functions which set ethernet environment variables to the common
>>> file.
>>>
>>> Signed-off-by: Simon Glass <s...@chromium.org>
>>> ---
>>>
>>>  net/eth.c          | 43 -------------------------------------------
>>>  net/eth_common.c   | 43 +++++++++++++++++++++++++++++++++++++++++++
>>>  net/eth_internal.h | 16 ++++++++++++++++
>>>  3 files changed, 59 insertions(+), 43 deletions(-)
>>>
>
> <snip>
>
>>> diff --git a/net/eth_internal.h b/net/eth_internal.h
>>> index e65d898..38d8420 100644
>>> --- a/net/eth_internal.h
>>> +++ b/net/eth_internal.h
>>> @@ -12,4 +12,20 @@
>>>  /* Do init that is common to driver model and legacy networking */
>>>  void eth_common_init(void);
>>>
>>> +/**
>>> + * eth_setenv_enetaddr_by_index() - set the MAC address envrionment 
>>> variable
>>> + *
>>> + * This sets up an environment variable with the given MAC address 
>>> (@enetaddr).
>>> + * The environment variable to be set is defined by 
>>> <@base_name><@index>addr.
>>> + * If @index is 0 it is omitted. For common Ethernet this means ethaddr,
>>> + * eth1addr, etc.
>>> + *
>>> + * @base_name: Base name for variable, typically "eth"
>>> + * @index:     Index of interface being updated (>=0)
>>> + * @enetaddr:  Pointer to MAC address to put into the variable
>>> + * @return 0 if OK, other value on error
>>> + */
>>> +int eth_setenv_enetaddr_by_index(const char *base_name, int index,
>>> +                                uchar *enetaddr);
>>> +
>>>  #endif
>>> --
>>
>> Could you add some comments about the other routines
>> (eth_parse_enetaddr, eth_getenv_enetaddr, eth_setenv_enetaddr,
>> eth_getenv_enetaddr_by_index)?
>
> That would be great, but those are already defined in include/net.h
> with poor / incomplete comments. I don't think fixing that *needs* to
> be part of this patch, but it would be welcomed.
>

Simon added comments for eth_setenv_enetaddr_by_index() which did not
have any comments before, so I'd assume we should add comments for
others in the same patch. Otherwise it looks odd to me.

Regards,
Bin
_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to