lkml.org 
[lkml]   [2015]   [Nov]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 1/2] dl2k: Add support for IP1000A-based cards
From
From: Andy Shevchenko <andy.shevchenko@gmail.com>
Date: Sun, 15 Nov 2015 04:30:25 +0200

> On Sun, Nov 15, 2015 at 12:05 AM, Ondrej Zary
>> @@ -433,9 +474,10 @@ rio_open (struct net_device *dev)
>>
>> alloc_list (dev);
>>
>> - /* Get station address */
>> - for (i = 0; i < 6; i++)
>> - dw8(StationAddr0 + i, dev->dev_addr[i]);
>> + /* Set station address */
>> + for (i = 0; i < 3; i++)
>> + dw16(StationAddr0 + 2 * i,
>> + cpu_to_le16(((u16 *)dev->dev_addr)[i]));
>
> Is it specific requirement for new HW? If not, may be another patch
> with micro optimizations.

I absolutely agree, this definitely should not just be blindly copied
over from the other driver.

And if it is a requirement:

1) It must be documented as per why, both in a comment above the loop
and in the commit log message.

2) It must therefore be tested on dl2k chips that worked with the
dl2k driver beforehand to prove that it doesn't break them.


\
 
 \ /
  Last update: 2015-11-15 19:21    [W:0.062 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site