lkml.org 
[lkml]   [2013]   [Dec]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH net-next v2 11/20] net: packetengines: slight optimization of addr
From
Date
On Mon, 2013-12-30 at 10:39 +0800, Ding Tianhong wrote:
> I don't understand packetengine NIC anymore, But I think the change is clearly,
> as your said, the broadcast check is enough here, did you mean that?
>
> !is_broadcast_ether_addr((u8 *)(le32_to_cpu(yp->rx_ring_dma) +
> entry * sizeof(struct yellowfin_desc)))

Not quite. I meant this could be:

u8 *addr = (u8 *)(unsigned long)le32_to_cpu(yp->rx_ring_dma) +
entry * sizeof(struct yellowfin_desc);

if (!ether_addr_equal(addr, dev->dev_addr) &&
!is_broadcast_ether_addr(addr)) {
etc...

but again, I think thus hardly matters and could just as well
be left alone.




\
 
 \ /
  Last update: 2013-12-30 07:41    [W:0.041 / U:1.452 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site