ethertap, skb_push, and IPX

Petr Vandrovec Ing. VTEI (VANDROVE@vc.cvut.cz)
Wed, 21 Apr 1999 18:12:56 MET-1


Hi network gurus,
I'm writting linux side of Novell Compatibility Mode Device (IPX frames
transmitted from/to UDP socket 2645 (probably to get rid of IPX traffic
on wire)) and I decided to use ethertap for feeding IPX packets from UDP
connection to Linux kernel and vice versa.
But, unfortunately, it works only in netlink->ethertap->IPX direction.
>From IPX->ethertap it does not work, because of ipx reserves only
dev->hard_header_len + datalink->header_length in skb, so ethertap gives
up xmit with 'bug --- xmit with head<2' :-( It works with IP because of
IP reserves (dev->hard_header_len + 15) & ~15, so for 14 bytes ethernet
header it reserves 16 - there are just two unused bytes for ethertap.
So I have four questions:
a) Should not ethertap try reallocate skb as (for example) ppp does if
there is not enough space?
b) Even if I do (a), ethertap will have to copy data on each IPX transmit
:-( It looks like that IPX should reserve more than
hard_header_len + header_length bytes. But how much? For
ethertap+IPX+any ethernet frame, rounding up to multiple of 16 as
ipv4/ip_output does, is sufficient. But I really think that code should
not rely on that there is at least two byte difference between header
size and header size rounded up to multiple of 16.
c) And this brings another question: Ethertap needs two bytes... Is there
another stuff, which does not report correct hard_header_len?
d) Is there another solution which I oversight?
Thanks,
Petr Vandrovec
vandrove@vc.cvut.cz
-
To unsubscribe from this list: send the line "unsubscribe linux-net" in
the body of a message to majordomo@vger.rutgers.edu