diff options
Diffstat (limited to 'drivers/s390/net')
-rw-r--r-- | drivers/s390/net/qeth_core_main.c | 3 | ||||
-rw-r--r-- | drivers/s390/net/qeth_l2_main.c | 27 | ||||
-rw-r--r-- | drivers/s390/net/qeth_l3_main.c | 13 | ||||
-rw-r--r-- | drivers/s390/net/qeth_l3_sys.c | 7 |
4 files changed, 12 insertions, 38 deletions
diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index 7de410d5be4a..52d26592c72c 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c | |||
@@ -3025,7 +3025,7 @@ static inline void __qeth_fill_buffer(struct sk_buff *skb, | |||
3025 | struct qdio_buffer *buffer, int is_tso, int *next_element_to_fill, | 3025 | struct qdio_buffer *buffer, int is_tso, int *next_element_to_fill, |
3026 | int offset) | 3026 | int offset) |
3027 | { | 3027 | { |
3028 | int length = skb->len - offset; | 3028 | int length = skb->len; |
3029 | int length_here; | 3029 | int length_here; |
3030 | int element; | 3030 | int element; |
3031 | char *data; | 3031 | char *data; |
@@ -3037,6 +3037,7 @@ static inline void __qeth_fill_buffer(struct sk_buff *skb, | |||
3037 | 3037 | ||
3038 | if (offset >= 0) { | 3038 | if (offset >= 0) { |
3039 | data = skb->data + offset; | 3039 | data = skb->data + offset; |
3040 | length -= offset; | ||
3040 | first_lap = 0; | 3041 | first_lap = 0; |
3041 | } | 3042 | } |
3042 | 3043 | ||
diff --git a/drivers/s390/net/qeth_l2_main.c b/drivers/s390/net/qeth_l2_main.c index 18623ef01287..8a8fad7a8bea 100644 --- a/drivers/s390/net/qeth_l2_main.c +++ b/drivers/s390/net/qeth_l2_main.c | |||
@@ -367,8 +367,6 @@ static int qeth_l2_stop_card(struct qeth_card *card, int recovery_mode) | |||
367 | QETH_DBF_HEX(SETUP, 2, &card, sizeof(void *)); | 367 | QETH_DBF_HEX(SETUP, 2, &card, sizeof(void *)); |
368 | 368 | ||
369 | qeth_set_allowed_threads(card, 0, 1); | 369 | qeth_set_allowed_threads(card, 0, 1); |
370 | if (qeth_wait_for_threads(card, ~QETH_RECOVER_THREAD)) | ||
371 | return -ERESTARTSYS; | ||
372 | if (card->read.state == CH_STATE_UP && | 370 | if (card->read.state == CH_STATE_UP && |
373 | card->write.state == CH_STATE_UP && | 371 | card->write.state == CH_STATE_UP && |
374 | (card->state == CARD_STATE_UP)) { | 372 | (card->state == CARD_STATE_UP)) { |
@@ -445,12 +443,15 @@ static void qeth_l2_process_inbound_buffer(struct qeth_card *card, | |||
445 | netif_rx(skb); | 443 | netif_rx(skb); |
446 | break; | 444 | break; |
447 | case QETH_HEADER_TYPE_OSN: | 445 | case QETH_HEADER_TYPE_OSN: |
448 | skb_push(skb, sizeof(struct qeth_hdr)); | 446 | if (card->info.type == QETH_CARD_TYPE_OSN) { |
449 | skb_copy_to_linear_data(skb, hdr, | 447 | skb_push(skb, sizeof(struct qeth_hdr)); |
448 | skb_copy_to_linear_data(skb, hdr, | ||
450 | sizeof(struct qeth_hdr)); | 449 | sizeof(struct qeth_hdr)); |
451 | len = skb->len; | 450 | len = skb->len; |
452 | card->osn_info.data_cb(skb); | 451 | card->osn_info.data_cb(skb); |
453 | break; | 452 | break; |
453 | } | ||
454 | /* else unknown */ | ||
454 | default: | 455 | default: |
455 | dev_kfree_skb_any(skb); | 456 | dev_kfree_skb_any(skb); |
456 | QETH_DBF_TEXT(TRACE, 3, "inbunkno"); | 457 | QETH_DBF_TEXT(TRACE, 3, "inbunkno"); |
@@ -969,12 +970,6 @@ static int __qeth_l2_set_online(struct ccwgroup_device *gdev, int recovery_mode) | |||
969 | QETH_DBF_HEX(SETUP, 2, &card, sizeof(void *)); | 970 | QETH_DBF_HEX(SETUP, 2, &card, sizeof(void *)); |
970 | 971 | ||
971 | qeth_set_allowed_threads(card, QETH_RECOVER_THREAD, 1); | 972 | qeth_set_allowed_threads(card, QETH_RECOVER_THREAD, 1); |
972 | if (qeth_wait_for_threads(card, ~QETH_RECOVER_THREAD)) { | ||
973 | PRINT_WARN("set_online of card %s interrupted by user!\n", | ||
974 | CARD_BUS_ID(card)); | ||
975 | return -ERESTARTSYS; | ||
976 | } | ||
977 | |||
978 | recover_flag = card->state; | 973 | recover_flag = card->state; |
979 | rc = ccw_device_set_online(CARD_RDEV(card)); | 974 | rc = ccw_device_set_online(CARD_RDEV(card)); |
980 | if (rc) { | 975 | if (rc) { |
@@ -1085,11 +1080,7 @@ static int __qeth_l2_set_offline(struct ccwgroup_device *cgdev, | |||
1085 | if (card->dev && netif_carrier_ok(card->dev)) | 1080 | if (card->dev && netif_carrier_ok(card->dev)) |
1086 | netif_carrier_off(card->dev); | 1081 | netif_carrier_off(card->dev); |
1087 | recover_flag = card->state; | 1082 | recover_flag = card->state; |
1088 | if (qeth_l2_stop_card(card, recovery_mode) == -ERESTARTSYS) { | 1083 | qeth_l2_stop_card(card, recovery_mode); |
1089 | PRINT_WARN("Stopping card %s interrupted by user!\n", | ||
1090 | CARD_BUS_ID(card)); | ||
1091 | return -ERESTARTSYS; | ||
1092 | } | ||
1093 | rc = ccw_device_set_offline(CARD_DDEV(card)); | 1084 | rc = ccw_device_set_offline(CARD_DDEV(card)); |
1094 | rc2 = ccw_device_set_offline(CARD_WDEV(card)); | 1085 | rc2 = ccw_device_set_offline(CARD_WDEV(card)); |
1095 | rc3 = ccw_device_set_offline(CARD_RDEV(card)); | 1086 | rc3 = ccw_device_set_offline(CARD_RDEV(card)); |
diff --git a/drivers/s390/net/qeth_l3_main.c b/drivers/s390/net/qeth_l3_main.c index 99547dea44de..ed59fedd5922 100644 --- a/drivers/s390/net/qeth_l3_main.c +++ b/drivers/s390/net/qeth_l3_main.c | |||
@@ -2064,8 +2064,6 @@ static int qeth_l3_stop_card(struct qeth_card *card, int recovery_mode) | |||
2064 | QETH_DBF_HEX(SETUP, 2, &card, sizeof(void *)); | 2064 | QETH_DBF_HEX(SETUP, 2, &card, sizeof(void *)); |
2065 | 2065 | ||
2066 | qeth_set_allowed_threads(card, 0, 1); | 2066 | qeth_set_allowed_threads(card, 0, 1); |
2067 | if (qeth_wait_for_threads(card, ~QETH_RECOVER_THREAD)) | ||
2068 | return -ERESTARTSYS; | ||
2069 | if (card->read.state == CH_STATE_UP && | 2067 | if (card->read.state == CH_STATE_UP && |
2070 | card->write.state == CH_STATE_UP && | 2068 | card->write.state == CH_STATE_UP && |
2071 | (card->state == CARD_STATE_UP)) { | 2069 | (card->state == CARD_STATE_UP)) { |
@@ -3049,11 +3047,6 @@ static int __qeth_l3_set_online(struct ccwgroup_device *gdev, int recovery_mode) | |||
3049 | QETH_DBF_HEX(SETUP, 2, &card, sizeof(void *)); | 3047 | QETH_DBF_HEX(SETUP, 2, &card, sizeof(void *)); |
3050 | 3048 | ||
3051 | qeth_set_allowed_threads(card, QETH_RECOVER_THREAD, 1); | 3049 | qeth_set_allowed_threads(card, QETH_RECOVER_THREAD, 1); |
3052 | if (qeth_wait_for_threads(card, ~QETH_RECOVER_THREAD)) { | ||
3053 | PRINT_WARN("set_online of card %s interrupted by user!\n", | ||
3054 | CARD_BUS_ID(card)); | ||
3055 | return -ERESTARTSYS; | ||
3056 | } | ||
3057 | 3050 | ||
3058 | recover_flag = card->state; | 3051 | recover_flag = card->state; |
3059 | rc = ccw_device_set_online(CARD_RDEV(card)); | 3052 | rc = ccw_device_set_online(CARD_RDEV(card)); |
@@ -3170,11 +3163,7 @@ static int __qeth_l3_set_offline(struct ccwgroup_device *cgdev, | |||
3170 | if (card->dev && netif_carrier_ok(card->dev)) | 3163 | if (card->dev && netif_carrier_ok(card->dev)) |
3171 | netif_carrier_off(card->dev); | 3164 | netif_carrier_off(card->dev); |
3172 | recover_flag = card->state; | 3165 | recover_flag = card->state; |
3173 | if (qeth_l3_stop_card(card, recovery_mode) == -ERESTARTSYS) { | 3166 | qeth_l3_stop_card(card, recovery_mode); |
3174 | PRINT_WARN("Stopping card %s interrupted by user!\n", | ||
3175 | CARD_BUS_ID(card)); | ||
3176 | return -ERESTARTSYS; | ||
3177 | } | ||
3178 | rc = ccw_device_set_offline(CARD_DDEV(card)); | 3167 | rc = ccw_device_set_offline(CARD_DDEV(card)); |
3179 | rc2 = ccw_device_set_offline(CARD_WDEV(card)); | 3168 | rc2 = ccw_device_set_offline(CARD_WDEV(card)); |
3180 | rc3 = ccw_device_set_offline(CARD_RDEV(card)); | 3169 | rc3 = ccw_device_set_offline(CARD_RDEV(card)); |
diff --git a/drivers/s390/net/qeth_l3_sys.c b/drivers/s390/net/qeth_l3_sys.c index 210ddb639748..c144b9924d52 100644 --- a/drivers/s390/net/qeth_l3_sys.c +++ b/drivers/s390/net/qeth_l3_sys.c | |||
@@ -121,9 +121,6 @@ static ssize_t qeth_l3_dev_route6_show(struct device *dev, | |||
121 | if (!card) | 121 | if (!card) |
122 | return -EINVAL; | 122 | return -EINVAL; |
123 | 123 | ||
124 | if (!qeth_is_supported(card, IPA_IPV6)) | ||
125 | return sprintf(buf, "%s\n", "n/a"); | ||
126 | |||
127 | return qeth_l3_dev_route_show(card, &card->options.route6, buf); | 124 | return qeth_l3_dev_route_show(card, &card->options.route6, buf); |
128 | } | 125 | } |
129 | 126 | ||
@@ -135,10 +132,6 @@ static ssize_t qeth_l3_dev_route6_store(struct device *dev, | |||
135 | if (!card) | 132 | if (!card) |
136 | return -EINVAL; | 133 | return -EINVAL; |
137 | 134 | ||
138 | if (!qeth_is_supported(card, IPA_IPV6)) { | ||
139 | return -EOPNOTSUPP; | ||
140 | } | ||
141 | |||
142 | return qeth_l3_dev_route_store(card, &card->options.route6, | 135 | return qeth_l3_dev_route_store(card, &card->options.route6, |
143 | QETH_PROT_IPV6, buf, count); | 136 | QETH_PROT_IPV6, buf, count); |
144 | } | 137 | } |