lkml.org 
[lkml]   [2010]   [Sep]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] Gigabit Ethernet driver of Topcliff PCH
From
Date
Le vendredi 03 septembre 2010 à 22:32 +0900, Masayuki Ohtake a écrit :
> Hi Eric and Stephen
>
> Thank you for your suggestion.
>
> I tried modification of "dev->hard_header_len".
> However, there was no changed to a format of SKB received by kernel.
> [Header:14octet] + [payload]
>
> So, I can not a single memcpy.

Hmm, maybe you did this at the wrong place ?

Take a look at other drivers how they do this

(network stack default hard_header_len to 14, in net/ethernet/eth.c,
function ether_setup())


find drivers/net | xargs grep -n hard_header_len

Example in drivers/net/wan/hdlc.c

static void hdlc_setup_dev(struct net_device *dev)
{
/* Re-init all variables changed by HDLC protocol drivers,
* including ether_setup() called from hdlc_raw_eth.c.
*/
dev->flags = IFF_POINTOPOINT | IFF_NOARP;
dev->priv_flags = IFF_WAN_HDLC;
dev->mtu = HDLC_MAX_MTU;
dev->type = ARPHRD_RAWHDLC;
dev->hard_header_len = 16;
dev->addr_len = 0;
dev->header_ops = &hdlc_null_ops;
}



--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2010-09-03 15:47    [W:0.072 / U:0.340 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site