diff options
author | David S. Miller <davem@davemloft.net> | 2005-08-09 22:25:21 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2005-08-29 18:31:14 -0400 |
commit | 8728b834b226ffcf2c94a58530090e292af2a7bf (patch) | |
tree | 2fd51ff3b7097eb3ffc41ea3a1d8b3ba04715b4c /drivers/net/wan | |
parent | 6869c4d8e066e21623c812c448a05f1ed931c9c6 (diff) |
[NET]: Kill skb->list
Remove the "list" member of struct sk_buff, as it is entirely
redundant. All SKB list removal callers know which list the
SKB is on, so storing this in sk_buff does nothing other than
taking up some space.
Two tricky bits were SCTP, which I took care of, and two ATM
drivers which Francois Romieu <romieu@fr.zoreil.com> fixed
up.
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
Diffstat (limited to 'drivers/net/wan')
-rw-r--r-- | drivers/net/wan/sdla_fr.c | 22 |
1 files changed, 7 insertions, 15 deletions
diff --git a/drivers/net/wan/sdla_fr.c b/drivers/net/wan/sdla_fr.c index c5f5e62aab8b..0497dbdb8631 100644 --- a/drivers/net/wan/sdla_fr.c +++ b/drivers/net/wan/sdla_fr.c | |||
@@ -445,7 +445,7 @@ void s508_s514_unlock(sdla_t *card, unsigned long *smp_flags); | |||
445 | void s508_s514_lock(sdla_t *card, unsigned long *smp_flags); | 445 | void s508_s514_lock(sdla_t *card, unsigned long *smp_flags); |
446 | 446 | ||
447 | unsigned short calc_checksum (char *, int); | 447 | unsigned short calc_checksum (char *, int); |
448 | static int setup_fr_header(struct sk_buff** skb, | 448 | static int setup_fr_header(struct sk_buff *skb, |
449 | struct net_device* dev, char op_mode); | 449 | struct net_device* dev, char op_mode); |
450 | 450 | ||
451 | 451 | ||
@@ -1372,7 +1372,7 @@ static int if_send(struct sk_buff* skb, struct net_device* dev) | |||
1372 | /* Move the if_header() code to here. By inserting frame | 1372 | /* Move the if_header() code to here. By inserting frame |
1373 | * relay header in if_header() we would break the | 1373 | * relay header in if_header() we would break the |
1374 | * tcpdump and other packet sniffers */ | 1374 | * tcpdump and other packet sniffers */ |
1375 | chan->fr_header_len = setup_fr_header(&skb,dev,chan->common.usedby); | 1375 | chan->fr_header_len = setup_fr_header(skb,dev,chan->common.usedby); |
1376 | if (chan->fr_header_len < 0 ){ | 1376 | if (chan->fr_header_len < 0 ){ |
1377 | ++chan->ifstats.tx_dropped; | 1377 | ++chan->ifstats.tx_dropped; |
1378 | ++card->wandev.stats.tx_dropped; | 1378 | ++card->wandev.stats.tx_dropped; |
@@ -1597,8 +1597,6 @@ static int setup_for_delayed_transmit(struct net_device* dev, | |||
1597 | return 1; | 1597 | return 1; |
1598 | } | 1598 | } |
1599 | 1599 | ||
1600 | skb_unlink(skb); | ||
1601 | |||
1602 | chan->transmit_length = len; | 1600 | chan->transmit_length = len; |
1603 | chan->delay_skb = skb; | 1601 | chan->delay_skb = skb; |
1604 | 1602 | ||
@@ -4871,18 +4869,15 @@ static void unconfig_fr (sdla_t *card) | |||
4871 | } | 4869 | } |
4872 | } | 4870 | } |
4873 | 4871 | ||
4874 | static int setup_fr_header(struct sk_buff **skb_orig, struct net_device* dev, | 4872 | static int setup_fr_header(struct sk_buff *skb, struct net_device* dev, |
4875 | char op_mode) | 4873 | char op_mode) |
4876 | { | 4874 | { |
4877 | struct sk_buff *skb = *skb_orig; | ||
4878 | fr_channel_t *chan=dev->priv; | 4875 | fr_channel_t *chan=dev->priv; |
4879 | 4876 | ||
4880 | if (op_mode == WANPIPE){ | 4877 | if (op_mode == WANPIPE) { |
4881 | |||
4882 | chan->fr_header[0]=Q922_UI; | 4878 | chan->fr_header[0]=Q922_UI; |
4883 | 4879 | ||
4884 | switch (htons(skb->protocol)){ | 4880 | switch (htons(skb->protocol)){ |
4885 | |||
4886 | case ETH_P_IP: | 4881 | case ETH_P_IP: |
4887 | chan->fr_header[1]=NLPID_IP; | 4882 | chan->fr_header[1]=NLPID_IP; |
4888 | break; | 4883 | break; |
@@ -4894,16 +4889,14 @@ static int setup_fr_header(struct sk_buff **skb_orig, struct net_device* dev, | |||
4894 | } | 4889 | } |
4895 | 4890 | ||
4896 | /* If we are in bridging mode, we must apply | 4891 | /* If we are in bridging mode, we must apply |
4897 | * an Ethernet header */ | 4892 | * an Ethernet header |
4898 | if (op_mode == BRIDGE || op_mode == BRIDGE_NODE){ | 4893 | */ |
4899 | 4894 | if (op_mode == BRIDGE || op_mode == BRIDGE_NODE) { | |
4900 | |||
4901 | /* Encapsulate the packet as a bridged Ethernet frame. */ | 4895 | /* Encapsulate the packet as a bridged Ethernet frame. */ |
4902 | #ifdef DEBUG | 4896 | #ifdef DEBUG |
4903 | printk(KERN_INFO "%s: encapsulating skb for frame relay\n", | 4897 | printk(KERN_INFO "%s: encapsulating skb for frame relay\n", |
4904 | dev->name); | 4898 | dev->name); |
4905 | #endif | 4899 | #endif |
4906 | |||
4907 | chan->fr_header[0] = 0x03; | 4900 | chan->fr_header[0] = 0x03; |
4908 | chan->fr_header[1] = 0x00; | 4901 | chan->fr_header[1] = 0x00; |
4909 | chan->fr_header[2] = 0x80; | 4902 | chan->fr_header[2] = 0x80; |
@@ -4916,7 +4909,6 @@ static int setup_fr_header(struct sk_buff **skb_orig, struct net_device* dev, | |||
4916 | /* Yuck. */ | 4909 | /* Yuck. */ |
4917 | skb->protocol = ETH_P_802_3; | 4910 | skb->protocol = ETH_P_802_3; |
4918 | return 8; | 4911 | return 8; |
4919 | |||
4920 | } | 4912 | } |
4921 | 4913 | ||
4922 | return 0; | 4914 | return 0; |