diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-30 11:45:48 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-30 11:45:48 -0400 |
commit | 95dfec6ae1cb8c03406aac612a5642cbddb676b3 (patch) | |
tree | 978de715f45de94a8e79eb08a08ca5fb9dfd9dea /drivers/s390/net/qeth_l2_main.c | |
parent | ae3a0064e6d69068b1c9fd075095da062430bda9 (diff) | |
parent | 159131149c2f56c1da5ae5e23ab9d5acef4916d1 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (53 commits)
tcp: Overflow bug in Vegas
[IPv4] UFO: prevent generation of chained skb destined to UFO device
iwlwifi: move the selects to the tristate drivers
ipv4: annotate a few functions __init in ipconfig.c
atm: ambassador: vcc_sf semaphore to mutex
MAINTAINERS: The socketcan-core list is subscribers-only.
netfilter: nf_conntrack: padding breaks conntrack hash on ARM
ipv4: Update MTU to all related cache entries in ip_rt_frag_needed()
sch_sfq: use del_timer_sync() in sfq_destroy()
net: Add compat support for getsockopt (MCAST_MSFILTER)
net: Several cleanups for the setsockopt compat support.
ipvs: fix oops in backup for fwmark conn templates
bridge: kernel panic when unloading bridge module
bridge: fix error handling in br_add_if()
netfilter: {nfnetlink,ip,ip6}_queue: fix skb_over_panic when enlarging packets
netfilter: x_tables: fix net namespace leak when reading /proc/net/xxx_tables_names
netfilter: xt_TCPOPTSTRIP: signed tcphoff for ipv6_skip_exthdr() retval
tcp: Limit cwnd growth when deferring for GSO
tcp: Allow send-limited cwnd to grow up to max_burst when gso disabled
[netdrvr] gianfar: Determine TBIPA value dynamically
...
Diffstat (limited to 'drivers/s390/net/qeth_l2_main.c')
-rw-r--r-- | drivers/s390/net/qeth_l2_main.c | 30 |
1 files changed, 22 insertions, 8 deletions
diff --git a/drivers/s390/net/qeth_l2_main.c b/drivers/s390/net/qeth_l2_main.c index 3921d1631a7..86ec50ddae1 100644 --- a/drivers/s390/net/qeth_l2_main.c +++ b/drivers/s390/net/qeth_l2_main.c | |||
@@ -22,9 +22,6 @@ | |||
22 | #include "qeth_core.h" | 22 | #include "qeth_core.h" |
23 | #include "qeth_core_offl.h" | 23 | #include "qeth_core_offl.h" |
24 | 24 | ||
25 | #define QETH_DBF_TXT_BUF qeth_l2_dbf_txt_buf | ||
26 | static DEFINE_PER_CPU(char[256], qeth_l2_dbf_txt_buf); | ||
27 | |||
28 | static int qeth_l2_set_offline(struct ccwgroup_device *); | 25 | static int qeth_l2_set_offline(struct ccwgroup_device *); |
29 | static int qeth_l2_stop(struct net_device *); | 26 | static int qeth_l2_stop(struct net_device *); |
30 | static int qeth_l2_send_delmac(struct qeth_card *, __u8 *); | 27 | static int qeth_l2_send_delmac(struct qeth_card *, __u8 *); |
@@ -635,8 +632,6 @@ static int qeth_l2_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
635 | enum qeth_large_send_types large_send = QETH_LARGE_SEND_NO; | 632 | enum qeth_large_send_types large_send = QETH_LARGE_SEND_NO; |
636 | struct qeth_eddp_context *ctx = NULL; | 633 | struct qeth_eddp_context *ctx = NULL; |
637 | 634 | ||
638 | QETH_DBF_TEXT(TRACE, 6, "l2xmit"); | ||
639 | |||
640 | if ((card->state != CARD_STATE_UP) || !card->lan_online) { | 635 | if ((card->state != CARD_STATE_UP) || !card->lan_online) { |
641 | card->stats.tx_carrier_errors++; | 636 | card->stats.tx_carrier_errors++; |
642 | goto tx_drop; | 637 | goto tx_drop; |
@@ -658,9 +653,12 @@ static int qeth_l2_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
658 | if (card->info.type == QETH_CARD_TYPE_OSN) | 653 | if (card->info.type == QETH_CARD_TYPE_OSN) |
659 | hdr = (struct qeth_hdr *)skb->data; | 654 | hdr = (struct qeth_hdr *)skb->data; |
660 | else { | 655 | else { |
661 | new_skb = qeth_prepare_skb(card, skb, &hdr); | 656 | /* create a clone with writeable headroom */ |
657 | new_skb = skb_realloc_headroom(skb, sizeof(struct qeth_hdr)); | ||
662 | if (!new_skb) | 658 | if (!new_skb) |
663 | goto tx_drop; | 659 | goto tx_drop; |
660 | hdr = (struct qeth_hdr *)skb_push(new_skb, | ||
661 | sizeof(struct qeth_hdr)); | ||
664 | qeth_l2_fill_header(card, hdr, new_skb, ipv, cast_type); | 662 | qeth_l2_fill_header(card, hdr, new_skb, ipv, cast_type); |
665 | } | 663 | } |
666 | 664 | ||
@@ -747,7 +745,6 @@ static void qeth_l2_qdio_input_handler(struct ccw_device *ccwdev, | |||
747 | int index; | 745 | int index; |
748 | int i; | 746 | int i; |
749 | 747 | ||
750 | QETH_DBF_TEXT(TRACE, 6, "qdinput"); | ||
751 | card = (struct qeth_card *) card_ptr; | 748 | card = (struct qeth_card *) card_ptr; |
752 | net_dev = card->dev; | 749 | net_dev = card->dev; |
753 | if (card->options.performance_stats) { | 750 | if (card->options.performance_stats) { |
@@ -852,6 +849,22 @@ static void qeth_l2_remove_device(struct ccwgroup_device *cgdev) | |||
852 | return; | 849 | return; |
853 | } | 850 | } |
854 | 851 | ||
852 | static int qeth_l2_ethtool_set_tso(struct net_device *dev, u32 data) | ||
853 | { | ||
854 | struct qeth_card *card = netdev_priv(dev); | ||
855 | |||
856 | if (data) { | ||
857 | if (card->options.large_send == QETH_LARGE_SEND_NO) { | ||
858 | card->options.large_send = QETH_LARGE_SEND_EDDP; | ||
859 | dev->features |= NETIF_F_TSO; | ||
860 | } | ||
861 | } else { | ||
862 | dev->features &= ~NETIF_F_TSO; | ||
863 | card->options.large_send = QETH_LARGE_SEND_NO; | ||
864 | } | ||
865 | return 0; | ||
866 | } | ||
867 | |||
855 | static struct ethtool_ops qeth_l2_ethtool_ops = { | 868 | static struct ethtool_ops qeth_l2_ethtool_ops = { |
856 | .get_link = ethtool_op_get_link, | 869 | .get_link = ethtool_op_get_link, |
857 | .get_tx_csum = ethtool_op_get_tx_csum, | 870 | .get_tx_csum = ethtool_op_get_tx_csum, |
@@ -859,11 +872,12 @@ static struct ethtool_ops qeth_l2_ethtool_ops = { | |||
859 | .get_sg = ethtool_op_get_sg, | 872 | .get_sg = ethtool_op_get_sg, |
860 | .set_sg = ethtool_op_set_sg, | 873 | .set_sg = ethtool_op_set_sg, |
861 | .get_tso = ethtool_op_get_tso, | 874 | .get_tso = ethtool_op_get_tso, |
862 | .set_tso = ethtool_op_set_tso, | 875 | .set_tso = qeth_l2_ethtool_set_tso, |
863 | .get_strings = qeth_core_get_strings, | 876 | .get_strings = qeth_core_get_strings, |
864 | .get_ethtool_stats = qeth_core_get_ethtool_stats, | 877 | .get_ethtool_stats = qeth_core_get_ethtool_stats, |
865 | .get_stats_count = qeth_core_get_stats_count, | 878 | .get_stats_count = qeth_core_get_stats_count, |
866 | .get_drvinfo = qeth_core_get_drvinfo, | 879 | .get_drvinfo = qeth_core_get_drvinfo, |
880 | .get_settings = qeth_core_ethtool_get_settings, | ||
867 | }; | 881 | }; |
868 | 882 | ||
869 | static struct ethtool_ops qeth_l2_osn_ops = { | 883 | static struct ethtool_ops qeth_l2_osn_ops = { |