This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
routing sockets / far end address resolution
- From: "Daniel Paape" <dpaape at amtelco dot com>
- To: <ecos-discuss at ecos dot sourceware dot org>
- Date: Mon, 21 Jan 2008 16:07:30 -0600
- Subject: [ECOS] routing sockets / far end address resolution
Hello,
Someone asked a question
(http://sourceware.org/ml/ecos-discuss/2006-12/msg00137.html) about a
year ago regarding routing sockets. There was no response to the
question and I'm wondering whether someone might have a go at a
re-worded version. Does eCos support routing sockets? The individual
above was having difficulty with the fileio (read/write) calls
associated with a routing socket. Could one use sendmsg/recvmsg instead
(if they are indeed supported)? If so, how does one convey that the
second argument is a "rt_msghdr" rather than just a "msghdr" structure?
My ultimate goal is to resolve a far end IP address to its mac address
(it may be local or may be on the other side of the gateway). The
address probably isn't resident in the ARP table, so what I am in
essence attempting to do is to get the stack to do a synchronized ARP
request for me. A ping would (most likely) get the address into the ARP
table but I would really like to avoid an ICMP exchange. I've cobbled a
proprietary IOCTL into the stack and can get it to do a lookup and if
necessary send out the ARP request... but implementing a wait for the
response is going to be difficult.
Is there a better way?
Thanks for any help.
Dan Paape
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss