s390/qeth: remove redundant netif_carrier_ok() checks
authorJulian Wiedmann <jwi@linux.ibm.com>
Thu, 19 Jul 2018 10:43:50 +0000 (12:43 +0200)
committerDavid S. Miller <davem@davemloft.net>
Sat, 21 Jul 2018 17:12:29 +0000 (10:12 -0700)
netif_carrier_off() does its own checking.

Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/s390/net/qeth_core_main.c
drivers/s390/net/qeth_l2_main.c
drivers/s390/net/qeth_l3_main.c

index f7ddd6455638aa79357f005610e7b07070a52f14..7c3b643550f61e7c94175b8eb4fb7bc9a942fa12 100644 (file)
@@ -653,7 +653,7 @@ static struct qeth_ipa_cmd *qeth_check_ipa_data(struct qeth_card *card,
                                                cmd->hdr.return_code, card);
                                }
                                card->lan_online = 0;
-                               if (card->dev && netif_carrier_ok(card->dev))
+                               if (card->dev)
                                        netif_carrier_off(card->dev);
                                return NULL;
                        case IPA_CMD_STARTLAN:
index 8ac243de7a9e4e08f4862ea3b85c247c260bf913..089bde458fd52546437607a14fd0dd71d9b001bd 100644 (file)
@@ -1163,7 +1163,7 @@ static int __qeth_l2_set_offline(struct ccwgroup_device *cgdev,
        QETH_DBF_TEXT(SETUP, 3, "setoffl");
        QETH_DBF_HEX(SETUP, 3, &card, sizeof(void *));
 
-       if (card->dev && netif_carrier_ok(card->dev))
+       if (card->dev)
                netif_carrier_off(card->dev);
        recover_flag = card->state;
        if ((!recovery_mode && card->info.hwtrap) || card->info.hwtrap == 2) {
index 062f62b4929490504f0b341a9c49f2e8c25e5e21..ee99af08b2c490f1267515a252774ffd04810087 100644 (file)
@@ -2773,7 +2773,7 @@ static int __qeth_l3_set_offline(struct ccwgroup_device *cgdev,
        QETH_DBF_TEXT(SETUP, 3, "setoffl");
        QETH_DBF_HEX(SETUP, 3, &card, sizeof(void *));
 
-       if (card->dev && netif_carrier_ok(card->dev))
+       if (card->dev)
                netif_carrier_off(card->dev);
        recover_flag = card->state;
        if ((!recovery_mode && card->info.hwtrap) || card->info.hwtrap == 2) {