Skip to content

Commit 4964c66

Browse files
julianwiedmanndavem330
authored andcommitted
Revert "s390/qeth: fix using of ref counter for rxip addresses"
This reverts commit cb81619. The issue this attempted to fix never actually occurs. l3_add_rxip() checks (via l3_ip_from_hash()) if the requested address was previously added to the card. If so, it returns -EEXIST and doesn't call l3_add_ip(). As a result, the "address exists" path in l3_add_ip() is never taken for rxip addresses, and this patch had no effect. Fixes: cb81619 ("s390/qeth: fix using of ref counter for rxip addresses") Signed-off-by: Julian Wiedmann <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 14d066c commit 4964c66

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

drivers/s390/net/qeth_l3_main.c

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -167,8 +167,7 @@ int qeth_l3_delete_ip(struct qeth_card *card, struct qeth_ipaddr *tmp_addr)
167167
return -ENOENT;
168168

169169
addr->ref_counter--;
170-
if (addr->ref_counter > 0 && (addr->type == QETH_IP_TYPE_NORMAL ||
171-
addr->type == QETH_IP_TYPE_RXIP))
170+
if (addr->type == QETH_IP_TYPE_NORMAL && addr->ref_counter > 0)
172171
return rc;
173172
if (addr->in_progress)
174173
return -EINPROGRESS;
@@ -246,9 +245,8 @@ int qeth_l3_add_ip(struct qeth_card *card, struct qeth_ipaddr *tmp_addr)
246245
kfree(addr);
247246
}
248247
} else {
249-
if (addr->type == QETH_IP_TYPE_NORMAL ||
250-
addr->type == QETH_IP_TYPE_RXIP)
251-
addr->ref_counter++;
248+
if (addr->type == QETH_IP_TYPE_NORMAL)
249+
addr->ref_counter++;
252250
}
253251

254252
return rc;

0 commit comments

Comments
 (0)