diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1998-03-17 22:05:47 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 1998-03-17 22:05:47 +0000 |
commit | 27cfca1ec98e91261b1a5355d10a8996464b63af (patch) | |
tree | 8e895a53e372fa682b4c0a585b9377d67ed70d0e /net/bridge | |
parent | 6a76fb7214c477ccf6582bd79c5b4ccc4f9c41b1 (diff) |
Look Ma' what I found on my harddisk ...
o New faster syscalls for 2.1.x, too
o Upgrade to 2.1.89.
Don't try to run this. It's flaky as hell. But feel free to debug ...
Diffstat (limited to 'net/bridge')
-rw-r--r-- | net/bridge/.cvsignore | 1 | ||||
-rw-r--r-- | net/bridge/br.c | 46 |
2 files changed, 20 insertions, 27 deletions
diff --git a/net/bridge/.cvsignore b/net/bridge/.cvsignore index 4671378ae..857dd22e9 100644 --- a/net/bridge/.cvsignore +++ b/net/bridge/.cvsignore @@ -1 +1,2 @@ .depend +.*.flags diff --git a/net/bridge/br.c b/net/bridge/br.c index b68751dd8..2961ff3c6 100644 --- a/net/bridge/br.c +++ b/net/bridge/br.c @@ -1000,16 +1000,16 @@ static int hold_timer_expired(int port_no) static int send_config_bpdu(int port_no, Config_bpdu *config_bpdu) { -struct sk_buff *skb; -struct device *dev = port_info[port_no].dev; -int size; -unsigned long flags; -struct ethhdr *eth; + struct sk_buff *skb; + struct device *dev = port_info[port_no].dev; + int size; + struct ethhdr *eth; if (port_info[port_no].state == Disabled) { printk(KERN_DEBUG "send_config_bpdu: port %i not valid\n",port_no); return(-1); - } + } + if (br_stats.flags & BR_DEBUG) printk("send_config_bpdu: "); /* @@ -1017,10 +1017,11 @@ struct ethhdr *eth; */ size = dev->hard_header_len + sizeof(Config_bpdu); skb = alloc_skb(size, GFP_ATOMIC); - if (skb == NULL) { + if (skb == NULL) + { printk(KERN_DEBUG "send_config_bpdu: no skb available\n"); return(-1); - } + } skb->dev = dev; skb->mac.raw = skb->h.raw = skb_put(skb, size); eth = skb->mac.ethernet; @@ -1049,21 +1050,17 @@ struct ethhdr *eth; /* won't get bridged again... */ skb->pkt_bridged = IS_BRIDGED; - skb->arp = 1; /* do not resolve... */ - save_flags(flags); - cli(); - skb_queue_tail(dev->buffs, skb); - restore_flags(flags); + skb->dev=dev; + dev_queue_xmit(skb); return(0); } static int send_tcn_bpdu(int port_no, Tcn_bpdu *bpdu) { -struct sk_buff *skb; -struct device *dev = port_info[port_no].dev; -int size; -unsigned long flags; -struct ethhdr *eth; + struct sk_buff *skb; + struct device *dev = port_info[port_no].dev; + int size; + struct ethhdr *eth; if (port_info[port_no].state == Disabled) { printk(KERN_DEBUG "send_tcn_bpdu: port %i not valid\n",port_no); @@ -1105,11 +1102,8 @@ struct ethhdr *eth; /* mark that we've been here... */ skb->pkt_bridged = IS_BRIDGED; - skb->arp = 1; /* do not resolve... */ - save_flags(flags); - cli(); - skb_queue_tail(dev->buffs, skb); - restore_flags(flags); + skb->dev=dev; + dev_queue_xmit(skb); return(0); } @@ -1199,7 +1193,6 @@ int br_receive_frame(struct sk_buff *skb) /* 3.5 */ port = find_port(skb->dev); - skb->arp = 1; /* Received frame so it is resolved */ skb->h.raw = skb->mac.raw; eth = skb->mac.ethernet; if (br_stats.flags & BR_DEBUG) @@ -1393,7 +1386,7 @@ static int br_learn(struct sk_buff *skb, int port) /* 3.8 */ static int br_drop(struct sk_buff *skb) { - kfree_skb(skb, 0); + kfree_skb(skb); return(1); } @@ -1403,7 +1396,7 @@ static int br_drop(struct sk_buff *skb) static int br_dev_drop(struct sk_buff *skb) { - dev_kfree_skb(skb, 0); + dev_kfree_skb(skb); return(1); } @@ -1519,7 +1512,6 @@ static int br_flood(struct sk_buff *skb, int port) nskb->dev= port_info[i].dev; /* To get here we must have done ARP already, or have a received valid MAC header */ - nskb->arp = 1; /* printk("Flood to port %d\n",i);*/ nskb->h.raw = nskb->data + ETH_HLEN; |