Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[NETFILTER]: ebtables: remove casts, use consts

Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Jan Engelhardt and committed by
David S. Miller
abfdf1c4 000e8a53

+95 -70
+5 -3
include/net/arp.h
··· 13 13 extern int arp_ioctl(struct net *net, unsigned int cmd, void __user *arg); 14 14 extern void arp_send(int type, int ptype, __be32 dest_ip, 15 15 struct net_device *dev, __be32 src_ip, 16 - unsigned char *dest_hw, unsigned char *src_hw, unsigned char *th); 16 + const unsigned char *dest_hw, 17 + const unsigned char *src_hw, const unsigned char *th); 17 18 extern int arp_bind_neighbour(struct dst_entry *dst); 18 19 extern int arp_mc_map(__be32 addr, u8 *haddr, struct net_device *dev, int dir); 19 20 extern void arp_ifdown(struct net_device *dev); 20 21 21 22 extern struct sk_buff *arp_create(int type, int ptype, __be32 dest_ip, 22 23 struct net_device *dev, __be32 src_ip, 23 - unsigned char *dest_hw, unsigned char *src_hw, 24 - unsigned char *target_hw); 24 + const unsigned char *dest_hw, 25 + const unsigned char *src_hw, 26 + const unsigned char *target_hw); 25 27 extern void arp_xmit(struct sk_buff *skb); 26 28 27 29 extern struct neigh_ops arp_broken_ops;
+3 -3
net/bridge/netfilter/ebt_802_3.c
··· 15 15 static int ebt_filter_802_3(const struct sk_buff *skb, const struct net_device *in, 16 16 const struct net_device *out, const void *data, unsigned int datalen) 17 17 { 18 - struct ebt_802_3_info *info = (struct ebt_802_3_info *)data; 19 - struct ebt_802_3_hdr *hdr = ebt_802_3_hdr(skb); 18 + const struct ebt_802_3_info *info = data; 19 + const struct ebt_802_3_hdr *hdr = ebt_802_3_hdr(skb); 20 20 __be16 type = hdr->llc.ui.ctrl & IS_UI ? hdr->llc.ui.type : hdr->llc.ni.type; 21 21 22 22 if (info->bitmask & EBT_802_3_SAP) { ··· 40 40 static int ebt_802_3_check(const char *tablename, unsigned int hookmask, 41 41 const struct ebt_entry *e, void *data, unsigned int datalen) 42 42 { 43 - struct ebt_802_3_info *info = (struct ebt_802_3_info *)data; 43 + const struct ebt_802_3_info *info = data; 44 44 45 45 if (datalen < sizeof(struct ebt_802_3_info)) 46 46 return -EINVAL;
+15 -9
net/bridge/netfilter/ebt_among.c
··· 25 25 const struct ebt_mac_wormhash_tuple *p; 26 26 int start, limit, i; 27 27 uint32_t cmp[2] = { 0, 0 }; 28 - int key = (const unsigned char) mac[5]; 28 + int key = ((const unsigned char *)mac)[5]; 29 29 30 30 memcpy(((char *) cmp) + 2, mac, 6); 31 31 start = wh->table[key]; ··· 73 73 static int get_ip_dst(const struct sk_buff *skb, __be32 *addr) 74 74 { 75 75 if (eth_hdr(skb)->h_proto == htons(ETH_P_IP)) { 76 - struct iphdr _iph, *ih; 76 + const struct iphdr *ih; 77 + struct iphdr _iph; 77 78 78 79 ih = skb_header_pointer(skb, 0, sizeof(_iph), &_iph); 79 80 if (ih == NULL) 80 81 return -1; 81 82 *addr = ih->daddr; 82 83 } else if (eth_hdr(skb)->h_proto == htons(ETH_P_ARP)) { 83 - struct arphdr _arph, *ah; 84 - __be32 buf, *bp; 84 + const struct arphdr *ah; 85 + struct arphdr _arph; 86 + const __be32 *bp; 87 + __be32 buf; 85 88 86 89 ah = skb_header_pointer(skb, 0, sizeof(_arph), &_arph); 87 90 if (ah == NULL || ··· 104 101 static int get_ip_src(const struct sk_buff *skb, __be32 *addr) 105 102 { 106 103 if (eth_hdr(skb)->h_proto == htons(ETH_P_IP)) { 107 - struct iphdr _iph, *ih; 104 + const struct iphdr *ih; 105 + struct iphdr _iph; 108 106 109 107 ih = skb_header_pointer(skb, 0, sizeof(_iph), &_iph); 110 108 if (ih == NULL) 111 109 return -1; 112 110 *addr = ih->saddr; 113 111 } else if (eth_hdr(skb)->h_proto == htons(ETH_P_ARP)) { 114 - struct arphdr _arph, *ah; 115 - __be32 buf, *bp; 112 + const struct arphdr *ah; 113 + struct arphdr _arph; 114 + const __be32 *bp; 115 + __be32 buf; 116 116 117 117 ah = skb_header_pointer(skb, 0, sizeof(_arph), &_arph); 118 118 if (ah == NULL || ··· 136 130 const struct net_device *out, const void *data, 137 131 unsigned int datalen) 138 132 { 139 - struct ebt_among_info *info = (struct ebt_among_info *) data; 133 + const struct ebt_among_info *info = data; 140 134 const char *dmac, *smac; 141 135 const struct ebt_mac_wormhash *wh_dst, *wh_src; 142 136 __be32 dip = 0, sip = 0; ··· 181 175 const struct ebt_entry *e, void *data, 182 176 unsigned int datalen) 183 177 { 184 - struct ebt_among_info *info = (struct ebt_among_info *) data; 178 + const struct ebt_among_info *info = data; 185 179 int expected_length = sizeof(struct ebt_among_info); 186 180 const struct ebt_mac_wormhash *wh_dst, *wh_src; 187 181 int err;
+8 -5
net/bridge/netfilter/ebt_arp.c
··· 18 18 static int ebt_filter_arp(const struct sk_buff *skb, const struct net_device *in, 19 19 const struct net_device *out, const void *data, unsigned int datalen) 20 20 { 21 - struct ebt_arp_info *info = (struct ebt_arp_info *)data; 22 - struct arphdr _arph, *ah; 21 + const struct ebt_arp_info *info = data; 22 + const struct arphdr *ah; 23 + struct arphdr _arph; 23 24 24 25 ah = skb_header_pointer(skb, 0, sizeof(_arph), &_arph); 25 26 if (ah == NULL) ··· 36 35 return EBT_NOMATCH; 37 36 38 37 if (info->bitmask & (EBT_ARP_SRC_IP | EBT_ARP_DST_IP | EBT_ARP_GRAT)) { 39 - __be32 saddr, daddr, *sap, *dap; 38 + const __be32 *sap, *dap; 39 + __be32 saddr, daddr; 40 40 41 41 if (ah->ar_pln != sizeof(__be32) || ah->ar_pro != htons(ETH_P_IP)) 42 42 return EBT_NOMATCH; ··· 63 61 } 64 62 65 63 if (info->bitmask & (EBT_ARP_SRC_MAC | EBT_ARP_DST_MAC)) { 66 - unsigned char _mac[ETH_ALEN], *mp; 64 + const unsigned char *mp; 65 + unsigned char _mac[ETH_ALEN]; 67 66 uint8_t verdict, i; 68 67 69 68 if (ah->ar_hln != ETH_ALEN || ah->ar_hrd != htons(ARPHRD_ETHER)) ··· 103 100 static int ebt_arp_check(const char *tablename, unsigned int hookmask, 104 101 const struct ebt_entry *e, void *data, unsigned int datalen) 105 102 { 106 - struct ebt_arp_info *info = (struct ebt_arp_info *)data; 103 + const struct ebt_arp_info *info = data; 107 104 108 105 if (datalen != EBT_ALIGN(sizeof(struct ebt_arp_info))) 109 106 return -EINVAL;
+8 -5
net/bridge/netfilter/ebt_arpreply.c
··· 19 19 const struct net_device *in, const struct net_device *out, 20 20 const void *data, unsigned int datalen) 21 21 { 22 - struct ebt_arpreply_info *info = (struct ebt_arpreply_info *)data; 23 - __be32 _sip, *siptr, _dip, *diptr; 24 - struct arphdr _ah, *ap; 25 - unsigned char _sha[ETH_ALEN], *shp; 22 + struct ebt_arpreply_info *info = (void *)data; 23 + const __be32 *siptr, *diptr; 24 + __be32 _sip, _dip; 25 + const struct arphdr *ap; 26 + struct arphdr _ah; 27 + const unsigned char *shp; 28 + unsigned char _sha[ETH_ALEN]; 26 29 27 30 ap = skb_header_pointer(skb, 0, sizeof(_ah), &_ah); 28 31 if (ap == NULL) ··· 61 58 static int ebt_target_reply_check(const char *tablename, unsigned int hookmask, 62 59 const struct ebt_entry *e, void *data, unsigned int datalen) 63 60 { 64 - struct ebt_arpreply_info *info = (struct ebt_arpreply_info *)data; 61 + const struct ebt_arpreply_info *info = data; 65 62 66 63 if (datalen != EBT_ALIGN(sizeof(struct ebt_arpreply_info))) 67 64 return -EINVAL;
+2 -2
net/bridge/netfilter/ebt_dnat.c
··· 18 18 const struct net_device *in, const struct net_device *out, 19 19 const void *data, unsigned int datalen) 20 20 { 21 - struct ebt_nat_info *info = (struct ebt_nat_info *)data; 21 + const struct ebt_nat_info *info = data; 22 22 23 23 if (skb_make_writable(skb, 0)) 24 24 return NF_DROP; ··· 30 30 static int ebt_target_dnat_check(const char *tablename, unsigned int hookmask, 31 31 const struct ebt_entry *e, void *data, unsigned int datalen) 32 32 { 33 - struct ebt_nat_info *info = (struct ebt_nat_info *)data; 33 + const struct ebt_nat_info *info = data; 34 34 35 35 if (BASE_CHAIN && info->target == EBT_RETURN) 36 36 return -EINVAL;
+6 -4
net/bridge/netfilter/ebt_ip.c
··· 28 28 const struct net_device *out, const void *data, 29 29 unsigned int datalen) 30 30 { 31 - struct ebt_ip_info *info = (struct ebt_ip_info *)data; 32 - struct iphdr _iph, *ih; 33 - struct tcpudphdr _ports, *pptr; 31 + const struct ebt_ip_info *info = data; 32 + const struct iphdr *ih; 33 + struct iphdr _iph; 34 + const struct tcpudphdr *pptr; 35 + struct tcpudphdr _ports; 34 36 35 37 ih = skb_header_pointer(skb, 0, sizeof(_iph), &_iph); 36 38 if (ih == NULL) ··· 81 79 static int ebt_ip_check(const char *tablename, unsigned int hookmask, 82 80 const struct ebt_entry *e, void *data, unsigned int datalen) 83 81 { 84 - struct ebt_ip_info *info = (struct ebt_ip_info *)data; 82 + const struct ebt_ip_info *info = data; 85 83 86 84 if (datalen != EBT_ALIGN(sizeof(struct ebt_ip_info))) 87 85 return -EINVAL;
+1 -1
net/bridge/netfilter/ebt_limit.c
··· 69 69 static int ebt_limit_check(const char *tablename, unsigned int hookmask, 70 70 const struct ebt_entry *e, void *data, unsigned int datalen) 71 71 { 72 - struct ebt_limit_info *info = (struct ebt_limit_info *)data; 72 + struct ebt_limit_info *info = data; 73 73 74 74 if (datalen != EBT_ALIGN(sizeof(struct ebt_limit_info))) 75 75 return -EINVAL;
+11 -7
net/bridge/netfilter/ebt_log.c
··· 24 24 static int ebt_log_check(const char *tablename, unsigned int hookmask, 25 25 const struct ebt_entry *e, void *data, unsigned int datalen) 26 26 { 27 - struct ebt_log_info *info = (struct ebt_log_info *)data; 27 + struct ebt_log_info *info = data; 28 28 29 29 if (datalen != EBT_ALIGN(sizeof(struct ebt_log_info))) 30 30 return -EINVAL; ··· 50 50 unsigned char ip_dst[4]; 51 51 }; 52 52 53 - static void print_MAC(unsigned char *p) 53 + static void print_MAC(const unsigned char *p) 54 54 { 55 55 int i; 56 56 ··· 84 84 85 85 if ((bitmask & EBT_LOG_IP) && eth_hdr(skb)->h_proto == 86 86 htons(ETH_P_IP)){ 87 - struct iphdr _iph, *ih; 87 + const struct iphdr *ih; 88 + struct iphdr _iph; 88 89 89 90 ih = skb_header_pointer(skb, 0, sizeof(_iph), &_iph); 90 91 if (ih == NULL) { ··· 100 99 ih->protocol == IPPROTO_UDPLITE || 101 100 ih->protocol == IPPROTO_SCTP || 102 101 ih->protocol == IPPROTO_DCCP) { 103 - struct tcpudphdr _ports, *pptr; 102 + const struct tcpudphdr *pptr; 103 + struct tcpudphdr _ports; 104 104 105 105 pptr = skb_header_pointer(skb, ih->ihl*4, 106 106 sizeof(_ports), &_ports); ··· 118 116 if ((bitmask & EBT_LOG_ARP) && 119 117 ((eth_hdr(skb)->h_proto == htons(ETH_P_ARP)) || 120 118 (eth_hdr(skb)->h_proto == htons(ETH_P_RARP)))) { 121 - struct arphdr _arph, *ah; 119 + const struct arphdr *ah; 120 + struct arphdr _arph; 122 121 123 122 ah = skb_header_pointer(skb, 0, sizeof(_arph), &_arph); 124 123 if (ah == NULL) { ··· 135 132 if (ah->ar_hrd == htons(1) && 136 133 ah->ar_hln == ETH_ALEN && 137 134 ah->ar_pln == sizeof(__be32)) { 138 - struct arppayload _arpp, *ap; 135 + const struct arppayload *ap; 136 + struct arppayload _arpp; 139 137 140 138 ap = skb_header_pointer(skb, sizeof(_arph), 141 139 sizeof(_arpp), &_arpp); ··· 164 160 const struct net_device *in, const struct net_device *out, 165 161 const void *data, unsigned int datalen) 166 162 { 167 - struct ebt_log_info *info = (struct ebt_log_info *)data; 163 + const struct ebt_log_info *info = data; 168 164 struct nf_loginfo li; 169 165 170 166 li.type = NF_LOG_TYPE_LOG;
+2 -2
net/bridge/netfilter/ebt_mark.c
··· 21 21 const struct net_device *in, const struct net_device *out, 22 22 const void *data, unsigned int datalen) 23 23 { 24 - struct ebt_mark_t_info *info = (struct ebt_mark_t_info *)data; 24 + const struct ebt_mark_t_info *info = data; 25 25 int action = info->target & -16; 26 26 27 27 if (action == MARK_SET_VALUE) ··· 39 39 static int ebt_target_mark_check(const char *tablename, unsigned int hookmask, 40 40 const struct ebt_entry *e, void *data, unsigned int datalen) 41 41 { 42 - struct ebt_mark_t_info *info = (struct ebt_mark_t_info *)data; 42 + const struct ebt_mark_t_info *info = data; 43 43 int tmp; 44 44 45 45 if (datalen != EBT_ALIGN(sizeof(struct ebt_mark_t_info)))
+2 -2
net/bridge/netfilter/ebt_mark_m.c
··· 16 16 const struct net_device *in, const struct net_device *out, const void *data, 17 17 unsigned int datalen) 18 18 { 19 - struct ebt_mark_m_info *info = (struct ebt_mark_m_info *) data; 19 + const struct ebt_mark_m_info *info = data; 20 20 21 21 if (info->bitmask & EBT_MARK_OR) 22 22 return !(!!(skb->mark & info->mask) ^ info->invert); ··· 26 26 static int ebt_mark_check(const char *tablename, unsigned int hookmask, 27 27 const struct ebt_entry *e, void *data, unsigned int datalen) 28 28 { 29 - struct ebt_mark_m_info *info = (struct ebt_mark_m_info *) data; 29 + const struct ebt_mark_m_info *info = data; 30 30 31 31 if (datalen != EBT_ALIGN(sizeof(struct ebt_mark_m_info))) 32 32 return -EINVAL;
+2 -2
net/bridge/netfilter/ebt_pkttype.c
··· 18 18 const void *data, 19 19 unsigned int datalen) 20 20 { 21 - struct ebt_pkttype_info *info = (struct ebt_pkttype_info *)data; 21 + const struct ebt_pkttype_info *info = data; 22 22 23 23 return (skb->pkt_type != info->pkt_type) ^ info->invert; 24 24 } ··· 26 26 static int ebt_pkttype_check(const char *tablename, unsigned int hookmask, 27 27 const struct ebt_entry *e, void *data, unsigned int datalen) 28 28 { 29 - struct ebt_pkttype_info *info = (struct ebt_pkttype_info *)data; 29 + const struct ebt_pkttype_info *info = data; 30 30 31 31 if (datalen != EBT_ALIGN(sizeof(struct ebt_pkttype_info))) 32 32 return -EINVAL;
+2 -2
net/bridge/netfilter/ebt_redirect.c
··· 19 19 const struct net_device *in, const struct net_device *out, 20 20 const void *data, unsigned int datalen) 21 21 { 22 - struct ebt_redirect_info *info = (struct ebt_redirect_info *)data; 22 + const struct ebt_redirect_info *info = data; 23 23 24 24 if (skb_make_writable(skb, 0)) 25 25 return NF_DROP; ··· 36 36 static int ebt_target_redirect_check(const char *tablename, unsigned int hookmask, 37 37 const struct ebt_entry *e, void *data, unsigned int datalen) 38 38 { 39 - struct ebt_redirect_info *info = (struct ebt_redirect_info *)data; 39 + const struct ebt_redirect_info *info = data; 40 40 41 41 if (datalen != EBT_ALIGN(sizeof(struct ebt_redirect_info))) 42 42 return -EINVAL;
+4 -3
net/bridge/netfilter/ebt_snat.c
··· 20 20 const struct net_device *in, const struct net_device *out, 21 21 const void *data, unsigned int datalen) 22 22 { 23 - struct ebt_nat_info *info = (struct ebt_nat_info *) data; 23 + const struct ebt_nat_info *info = data; 24 24 25 25 if (skb_make_writable(skb, 0)) 26 26 return NF_DROP; ··· 28 28 memcpy(eth_hdr(skb)->h_source, info->mac, ETH_ALEN); 29 29 if (!(info->target & NAT_ARP_BIT) && 30 30 eth_hdr(skb)->h_proto == htons(ETH_P_ARP)) { 31 - struct arphdr _ah, *ap; 31 + const struct arphdr *ap; 32 + struct arphdr _ah; 32 33 33 34 ap = skb_header_pointer(skb, 0, sizeof(_ah), &_ah); 34 35 if (ap == NULL) ··· 46 45 static int ebt_target_snat_check(const char *tablename, unsigned int hookmask, 47 46 const struct ebt_entry *e, void *data, unsigned int datalen) 48 47 { 49 - struct ebt_nat_info *info = (struct ebt_nat_info *) data; 48 + const struct ebt_nat_info *info = data; 50 49 int tmp; 51 50 52 51 if (datalen != EBT_ALIGN(sizeof(struct ebt_nat_info)))
+13 -11
net/bridge/netfilter/ebt_stp.c
··· 40 40 #define NR16(p) (p[0] << 8 | p[1]) 41 41 #define NR32(p) ((p[0] << 24) | (p[1] << 16) | (p[2] << 8) | p[3]) 42 42 43 - static int ebt_filter_config(struct ebt_stp_info *info, 44 - struct stp_config_pdu *stpc) 43 + static int ebt_filter_config(const struct ebt_stp_info *info, 44 + const struct stp_config_pdu *stpc) 45 45 { 46 - struct ebt_stp_config_info *c; 46 + const struct ebt_stp_config_info *c; 47 47 uint16_t v16; 48 48 uint32_t v32; 49 49 int verdict, i; ··· 122 122 static int ebt_filter_stp(const struct sk_buff *skb, const struct net_device *in, 123 123 const struct net_device *out, const void *data, unsigned int datalen) 124 124 { 125 - struct ebt_stp_info *info = (struct ebt_stp_info *)data; 126 - struct stp_header _stph, *sp; 127 - uint8_t header[6] = {0x42, 0x42, 0x03, 0x00, 0x00, 0x00}; 125 + const struct ebt_stp_info *info = data; 126 + const struct stp_header *sp; 127 + struct stp_header _stph; 128 + const uint8_t header[6] = {0x42, 0x42, 0x03, 0x00, 0x00, 0x00}; 128 129 129 130 sp = skb_header_pointer(skb, 0, sizeof(_stph), &_stph); 130 131 if (sp == NULL) ··· 141 140 142 141 if (sp->type == BPDU_TYPE_CONFIG && 143 142 info->bitmask & EBT_STP_CONFIG_MASK) { 144 - struct stp_config_pdu _stpc, *st; 143 + const struct stp_config_pdu *st; 144 + struct stp_config_pdu _stpc; 145 145 146 146 st = skb_header_pointer(skb, sizeof(_stph), 147 147 sizeof(_stpc), &_stpc); ··· 156 154 static int ebt_stp_check(const char *tablename, unsigned int hookmask, 157 155 const struct ebt_entry *e, void *data, unsigned int datalen) 158 156 { 159 - struct ebt_stp_info *info = (struct ebt_stp_info *)data; 160 - int len = EBT_ALIGN(sizeof(struct ebt_stp_info)); 161 - uint8_t bridge_ula[6] = { 0x01, 0x80, 0xc2, 0x00, 0x00, 0x00 }; 162 - uint8_t msk[6] = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }; 157 + const struct ebt_stp_info *info = data; 158 + const unsigned int len = EBT_ALIGN(sizeof(struct ebt_stp_info)); 159 + const uint8_t bridge_ula[6] = {0x01, 0x80, 0xc2, 0x00, 0x00, 0x00}; 160 + const uint8_t msk[6] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff}; 163 161 164 162 if (info->bitmask & ~EBT_STP_MASK || info->invflags & ~EBT_STP_MASK || 165 163 !(info->bitmask & EBT_STP_MASK))
+2 -2
net/bridge/netfilter/ebt_ulog.c
··· 249 249 const struct net_device *in, const struct net_device *out, 250 250 const void *data, unsigned int datalen) 251 251 { 252 - struct ebt_ulog_info *uloginfo = (struct ebt_ulog_info *)data; 252 + const struct ebt_ulog_info *uloginfo = data; 253 253 254 254 ebt_ulog_packet(hooknr, skb, in, out, uloginfo, NULL); 255 255 } ··· 258 258 static int ebt_ulog_check(const char *tablename, unsigned int hookmask, 259 259 const struct ebt_entry *e, void *data, unsigned int datalen) 260 260 { 261 - struct ebt_ulog_info *uloginfo = (struct ebt_ulog_info *)data; 261 + struct ebt_ulog_info *uloginfo = data; 262 262 263 263 if (datalen != EBT_ALIGN(sizeof(struct ebt_ulog_info)) || 264 264 uloginfo->nlgroup > 31)
+4 -3
net/bridge/netfilter/ebt_vlan.c
··· 46 46 const struct net_device *out, 47 47 const void *data, unsigned int datalen) 48 48 { 49 - struct ebt_vlan_info *info = (struct ebt_vlan_info *) data; 50 - struct vlan_hdr _frame, *fp; 49 + const struct ebt_vlan_info *info = data; 50 + const struct vlan_hdr *fp; 51 + struct vlan_hdr _frame; 51 52 52 53 unsigned short TCI; /* Whole TCI, given from parsed frame */ 53 54 unsigned short id; /* VLAN ID, given from frame TCI */ ··· 92 91 unsigned int hooknr, 93 92 const struct ebt_entry *e, void *data, unsigned int datalen) 94 93 { 95 - struct ebt_vlan_info *info = (struct ebt_vlan_info *) data; 94 + struct ebt_vlan_info *info = data; 96 95 97 96 /* Parameters buffer overflow check */ 98 97 if (datalen != EBT_ALIGN(sizeof(struct ebt_vlan_info))) {
+5 -4
net/ipv4/arp.c
··· 558 558 */ 559 559 struct sk_buff *arp_create(int type, int ptype, __be32 dest_ip, 560 560 struct net_device *dev, __be32 src_ip, 561 - unsigned char *dest_hw, unsigned char *src_hw, 562 - unsigned char *target_hw) 561 + const unsigned char *dest_hw, 562 + const unsigned char *src_hw, 563 + const unsigned char *target_hw) 563 564 { 564 565 struct sk_buff *skb; 565 566 struct arphdr *arp; ··· 673 672 */ 674 673 void arp_send(int type, int ptype, __be32 dest_ip, 675 674 struct net_device *dev, __be32 src_ip, 676 - unsigned char *dest_hw, unsigned char *src_hw, 677 - unsigned char *target_hw) 675 + const unsigned char *dest_hw, const unsigned char *src_hw, 676 + const unsigned char *target_hw) 678 677 { 679 678 struct sk_buff *skb; 680 679