Xenomai  3.0.8
arp.h
1 /***
2  *
3  * include/ipv4/arp.h - Adress Resolution Protocol for RTnet
4  *
5  * RTnet - real-time networking subsystem
6  * Copyright (C) 1999,2000 Zentropic Computing, LLC
7  * 2002 Ulrich Marx <marx@kammer.uni-hannover.de>
8  * 2004 Jan Kiszka <jan.kiszka@web.de>
9  *
10  * This program is free software; you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation; either version 2 of the License, or
13  * (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the GNU General Public License
21  * along with this program; if not, write to the Free Software
22  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23  *
24  */
25 
26 #ifndef __RTNET_ARP_H_
27 #define __RTNET_ARP_H_
28 
29 #include <linux/if_arp.h>
30 #include <linux/init.h>
31 #include <linux/types.h>
32 
33 #include <ipv4/route.h>
34 
35 
36 #define RT_ARP_SKB_PRIO RTSKB_PRIO_VALUE(QUEUE_MIN_PRIO-1, \
37  RTSKB_DEF_NRT_CHANNEL)
38 
39 void rt_arp_send(int type, int ptype, u32 dest_ip,
40  struct rtnet_device *rtdev, u32 src_ip,
41  unsigned char *dest_hw, unsigned char *src_hw,
42  unsigned char *target_hw);
43 
44 static inline void rt_arp_solicit(struct rtnet_device *rtdev, u32 target)
45 {
46  rt_arp_send(ARPOP_REQUEST, ETH_P_ARP, target, rtdev, rtdev->local_ip,
47  NULL, NULL, NULL);
48 }
49 
50 void __init rt_arp_init(void);
51 void rt_arp_release(void);
52 
53 
54 #endif /* __RTNET_ARP_H_ */