diff options
Diffstat (limited to 'net/atm')
-rw-r--r-- | net/atm/br2684.c | 7 | ||||
-rw-r--r-- | net/atm/clip.c | 1 | ||||
-rw-r--r-- | net/atm/ioctl.c | 1 | ||||
-rw-r--r-- | net/atm/lec.c | 10 | ||||
-rw-r--r-- | net/atm/mpc.c | 3 | ||||
-rw-r--r-- | net/atm/pppoatm.c | 1 | ||||
-rw-r--r-- | net/atm/raw.c | 1 | ||||
-rw-r--r-- | net/atm/resources.c | 1 | ||||
-rw-r--r-- | net/atm/signaling.c | 9 |
9 files changed, 18 insertions, 16 deletions
diff --git a/net/atm/br2684.c b/net/atm/br2684.c index 72f3f7b8de8..680ccb12aae 100644 --- a/net/atm/br2684.c +++ b/net/atm/br2684.c @@ -18,6 +18,7 @@ Author: Marcell GAL, 2000, XDSL Ltd, Hungary #include <net/arp.h> #include <linux/atm.h> #include <linux/atmdev.h> +#include <linux/capability.h> #include <linux/seq_file.h> #include <linux/atmbr2684.h> @@ -295,14 +296,14 @@ static inline __be16 br_type_trans(struct sk_buff *skb, struct net_device *dev) unsigned char *rawp; eth = eth_hdr(skb); - if (*eth->h_dest & 1) { - if (memcmp(eth->h_dest, dev->broadcast, ETH_ALEN) == 0) + if (is_multicast_ether_addr(eth->h_dest)) { + if (!compare_ether_addr(eth->h_dest, dev->broadcast)) skb->pkt_type = PACKET_BROADCAST; else skb->pkt_type = PACKET_MULTICAST; } - else if (memcmp(eth->h_dest, dev->dev_addr, ETH_ALEN)) + else if (compare_ether_addr(eth->h_dest, dev->dev_addr)) skb->pkt_type = PACKET_OTHERHOST; if (ntohs(eth->h_proto) >= 1536) diff --git a/net/atm/clip.c b/net/atm/clip.c index 4f54c9a5e84..73370de9753 100644 --- a/net/atm/clip.c +++ b/net/atm/clip.c @@ -19,6 +19,7 @@ #include <linux/atmdev.h> #include <linux/atmclip.h> #include <linux/atmarp.h> +#include <linux/capability.h> #include <linux/ip.h> /* for net/route.h */ #include <linux/in.h> /* for struct sockaddr_in */ #include <linux/if.h> /* for IFF_UP */ diff --git a/net/atm/ioctl.c b/net/atm/ioctl.c index a150198b05a..eb109af7eb4 100644 --- a/net/atm/ioctl.c +++ b/net/atm/ioctl.c @@ -12,6 +12,7 @@ #include <linux/atmdev.h> #include <linux/atmclip.h> /* CLIP_*ENCAP */ #include <linux/atmarp.h> /* manifest constants */ +#include <linux/capability.h> #include <linux/sonet.h> /* for ioctls */ #include <linux/atmsvc.h> #include <linux/atmmpc.h> diff --git a/net/atm/lec.c b/net/atm/lec.c index ad840b9afba..c4fc722fef9 100644 --- a/net/atm/lec.c +++ b/net/atm/lec.c @@ -7,6 +7,7 @@ #include <linux/config.h> #include <linux/kernel.h> #include <linux/bitops.h> +#include <linux/capability.h> /* We are ethernet device */ #include <linux/if_ether.h> @@ -1321,7 +1322,7 @@ static int lane2_associate_req (struct net_device *dev, u8 *lan_dst, struct sk_buff *skb; struct lec_priv *priv = (struct lec_priv*)dev->priv; - if ( memcmp(lan_dst, dev->dev_addr, ETH_ALEN) != 0 ) + if (compare_ether_addr(lan_dst, dev->dev_addr)) return (0); /* not our mac address */ kfree(priv->tlvs); /* NULL if there was no previous association */ @@ -1798,7 +1799,7 @@ lec_arp_find(struct lec_priv *priv, to_return = priv->lec_arp_tables[place]; while(to_return) { - if (memcmp(mac_addr, to_return->mac_addr, ETH_ALEN) == 0) { + if (!compare_ether_addr(mac_addr, to_return->mac_addr)) { return to_return; } to_return = to_return->next; @@ -1811,8 +1812,7 @@ make_entry(struct lec_priv *priv, unsigned char *mac_addr) { struct lec_arp_table *to_return; - to_return = (struct lec_arp_table *) kmalloc(sizeof(struct lec_arp_table), - GFP_ATOMIC); + to_return = kmalloc(sizeof(struct lec_arp_table), GFP_ATOMIC); if (!to_return) { printk("LEC: Arp entry kmalloc failed\n"); return NULL; @@ -2002,7 +2002,7 @@ lec_arp_resolve(struct lec_priv *priv, unsigned char *mac_to_find, return priv->mcast_vcc; break; case 2: /* LANE2 wants arp for multicast addresses */ - if ( memcmp(mac_to_find, bus_mac, ETH_ALEN) == 0) + if (!compare_ether_addr(mac_to_find, bus_mac)) return priv->mcast_vcc; break; default: diff --git a/net/atm/mpc.c b/net/atm/mpc.c index 526d9531411..c304ef1513b 100644 --- a/net/atm/mpc.c +++ b/net/atm/mpc.c @@ -3,6 +3,7 @@ #include <linux/timer.h> #include <linux/init.h> #include <linux/bitops.h> +#include <linux/capability.h> #include <linux/seq_file.h> /* We are an ethernet device */ @@ -552,7 +553,7 @@ static int mpc_send_packet(struct sk_buff *skb, struct net_device *dev) goto non_ip; /* Multi-Protocol Over ATM :-) */ while (i < mpc->number_of_mps_macs) { - if (memcmp(eth->h_dest, (mpc->mps_macs + i*ETH_ALEN), ETH_ALEN) == 0) + if (!compare_ether_addr(eth->h_dest, (mpc->mps_macs + i*ETH_ALEN))) if ( send_via_shortcut(skb, mpc) == 0 ) /* try shortcut */ return 0; /* success! */ i++; diff --git a/net/atm/pppoatm.c b/net/atm/pppoatm.c index 58f4a2b5aeb..1489067c1e8 100644 --- a/net/atm/pppoatm.c +++ b/net/atm/pppoatm.c @@ -39,6 +39,7 @@ #include <linux/skbuff.h> #include <linux/atm.h> #include <linux/atmdev.h> +#include <linux/capability.h> #include <linux/ppp_defs.h> #include <linux/if_ppp.h> #include <linux/ppp_channel.h> diff --git a/net/atm/raw.c b/net/atm/raw.c index 4a0466e91aa..3e57b17ca52 100644 --- a/net/atm/raw.c +++ b/net/atm/raw.c @@ -6,6 +6,7 @@ #include <linux/module.h> #include <linux/sched.h> #include <linux/atmdev.h> +#include <linux/capability.h> #include <linux/kernel.h> #include <linux/skbuff.h> #include <linux/mm.h> diff --git a/net/atm/resources.c b/net/atm/resources.c index c8c459fcb03..224190537c9 100644 --- a/net/atm/resources.c +++ b/net/atm/resources.c @@ -16,6 +16,7 @@ #include <linux/kernel.h> /* for barrier */ #include <linux/module.h> #include <linux/bitops.h> +#include <linux/capability.h> #include <linux/delay.h> #include <net/sock.h> /* for struct sock */ diff --git a/net/atm/signaling.c b/net/atm/signaling.c index e7211a7f382..31d98b57e1d 100644 --- a/net/atm/signaling.c +++ b/net/atm/signaling.c @@ -39,24 +39,19 @@ static DECLARE_WAIT_QUEUE_HEAD(sigd_sleep); static void sigd_put_skb(struct sk_buff *skb) { #ifdef WAIT_FOR_DEMON - static unsigned long silence; DECLARE_WAITQUEUE(wait,current); add_wait_queue(&sigd_sleep,&wait); while (!sigd) { set_current_state(TASK_UNINTERRUPTIBLE); - if (time_after(jiffies, silence) || silence == 0) { - printk(KERN_INFO "atmsvc: waiting for signaling demon " - "...\n"); - silence = (jiffies+30*HZ)|1; - } + DPRINTK("atmsvc: waiting for signaling demon...\n"); schedule(); } current->state = TASK_RUNNING; remove_wait_queue(&sigd_sleep,&wait); #else if (!sigd) { - printk(KERN_WARNING "atmsvc: no signaling demon\n"); + DPRINTK("atmsvc: no signaling demon\n"); kfree_skb(skb); return; } |