diff options
-rw-r--r-- | drivers/s390/net/qeth_main.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/s390/net/qeth_main.c b/drivers/s390/net/qeth_main.c index 2bde4f1fb9c2..f17d7cfb4207 100644 --- a/drivers/s390/net/qeth_main.c +++ b/drivers/s390/net/qeth_main.c | |||
@@ -2560,7 +2560,6 @@ qeth_process_inbound_buffer(struct qeth_card *card, | |||
2560 | int offset; | 2560 | int offset; |
2561 | int rxrc; | 2561 | int rxrc; |
2562 | __u16 vlan_tag = 0; | 2562 | __u16 vlan_tag = 0; |
2563 | __u16 *vlan_addr; | ||
2564 | 2563 | ||
2565 | /* get first element of current buffer */ | 2564 | /* get first element of current buffer */ |
2566 | element = (struct qdio_buffer_element *)&buf->buffer->element[0]; | 2565 | element = (struct qdio_buffer_element *)&buf->buffer->element[0]; |
@@ -4844,9 +4843,11 @@ qeth_arp_query(struct qeth_card *card, char __user *udata) | |||
4844 | "(0x%x/%d)\n", | 4843 | "(0x%x/%d)\n", |
4845 | QETH_CARD_IFNAME(card), qeth_arp_get_error_cause(&rc), | 4844 | QETH_CARD_IFNAME(card), qeth_arp_get_error_cause(&rc), |
4846 | tmp, tmp); | 4845 | tmp, tmp); |
4847 | copy_to_user(udata, qinfo.udata, 4); | 4846 | if (copy_to_user(udata, qinfo.udata, 4)) |
4847 | rc = -EFAULT; | ||
4848 | } else { | 4848 | } else { |
4849 | copy_to_user(udata, qinfo.udata, qinfo.udata_len); | 4849 | if (copy_to_user(udata, qinfo.udata, qinfo.udata_len)) |
4850 | rc = -EFAULT; | ||
4850 | } | 4851 | } |
4851 | kfree(qinfo.udata); | 4852 | kfree(qinfo.udata); |
4852 | return rc; | 4853 | return rc; |
@@ -4992,8 +4993,10 @@ qeth_snmp_command(struct qeth_card *card, char __user *udata) | |||
4992 | if (rc) | 4993 | if (rc) |
4993 | PRINT_WARN("SNMP command failed on %s: (0x%x)\n", | 4994 | PRINT_WARN("SNMP command failed on %s: (0x%x)\n", |
4994 | QETH_CARD_IFNAME(card), rc); | 4995 | QETH_CARD_IFNAME(card), rc); |
4995 | else | 4996 | else { |
4996 | copy_to_user(udata, qinfo.udata, qinfo.udata_len); | 4997 | if (copy_to_user(udata, qinfo.udata, qinfo.udata_len)) |
4998 | rc = -EFAULT; | ||
4999 | } | ||
4997 | 5000 | ||
4998 | kfree(ureq); | 5001 | kfree(ureq); |
4999 | kfree(qinfo.udata); | 5002 | kfree(qinfo.udata); |