From patchwork Mon Jul 18 02:43:24 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AceLan Kao X-Patchwork-Id: 1657277 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=SLIYuowt; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4LmR9d3bwTz9sGD for ; Mon, 18 Jul 2022 12:43:47 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1oDGjU-0003sS-1h; Mon, 18 Jul 2022 02:43:40 +0000 Received: from mail-pg1-f181.google.com ([209.85.215.181]) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1oDGjP-0003qj-Ew for kernel-team@lists.ubuntu.com; Mon, 18 Jul 2022 02:43:35 +0000 Received: by mail-pg1-f181.google.com with SMTP id 23so9403728pgc.8 for ; Sun, 17 Jul 2022 19:43:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=eQXXu/vR9ozhhHRsCuJzJQhFKeHQtZ1tPTi539HF2K0=; b=SLIYuowtztxA3RrRt3N2lsGkwe03weA6wLwTosjr6RNjG/TjB1hhMUfQiq+M+iRXJ1 bJgU12O5XCyywltyHd7uGGsrMuTAuRCC4FAUh9B28sYaZLjbhnr/UQefXA9G2WVgrA3s 8QAvA0m9i7y8U4jqBu9z9mHaYuZYyZdyT4K5QWuJ/NwejVmwVEqjSJ+KitZHfLCY87LJ g1Mwi+QwF+ap1jJXUWW5F9eSprU3HImkn3yeBDZ6j6tvm4zxNbsEmcjmdwfMiMoXG4XU 64gMigjj45ErMNrUSB/6pRcfJOhktMs8imWcWffovQ90rjqngfW/z5eJwbN4cDfE6NH7 rnvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=eQXXu/vR9ozhhHRsCuJzJQhFKeHQtZ1tPTi539HF2K0=; b=gHtaoytUIP5rOIrFonvdupS0/lAstnhuMI+Jvl20STrUHJwWXQIskq0/W5+kR/hDAb C3QQV4MUkTEKKita5GVsXbu16IyMkgZ1k2yCscIVLamtqiYUWvC7DqLYryqvfdsxKK8z jntvJo9qhkZN/WWYmLTHY5Q0OMHtUnqqGDOP8WfQEQj+XqYlWgZh11bordH7PhGpZOdj VAr3iEk9r64dEAjsiSRuZ5sUMHA0btty0v68JpSEsYg6Vho31Jn3MwpUZY1n+eNxZOdJ WTpSAWWc/UStjy2nuPu888J7Hj/FKavss1HG17l3hXwGHenLnga52Ti77JnGy1mhtNJ4 aQcg== X-Gm-Message-State: AJIora+KBP4fTP5nrTWFs/ruipUsEQf3DxXlSd+o5FB14PUx74trKoKd Ty/fszxFAEekRD4fv13foZZnKUFhrGqssg== X-Google-Smtp-Source: AGRyM1t7UKt65kTvy/AKljKhgrGxy/qZxehn7dZHufcb6z9y285VSkV8E6VWn5wTNJ1y1acPpjA9LA== X-Received: by 2002:a63:84c8:0:b0:415:b761:efa1 with SMTP id k191-20020a6384c8000000b00415b761efa1mr22348458pgd.89.1658112213415; Sun, 17 Jul 2022 19:43:33 -0700 (PDT) Received: from localhost (220-135-95-34.hinet-ip.hinet.net. [220.135.95.34]) by smtp.gmail.com with ESMTPSA id w12-20020a170902e88c00b0016c4cbefea3sm8040912plg.218.2022.07.17.19.43.32 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 17 Jul 2022 19:43:32 -0700 (PDT) From: AceLan Kao To: kernel-team@lists.ubuntu.com Subject: [PATCH 2/2][SRU][J][OEM-5.14][OEM-5.17] net: atlantic: remove aq_nic_deinit() when resume Date: Mon, 18 Jul 2022 10:43:24 +0800 Message-Id: <20220718024324.1932501-3-acelan.kao@canonical.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220718024324.1932501-1-acelan.kao@canonical.com> References: <20220718024324.1932501-1-acelan.kao@canonical.com> MIME-Version: 1.0 Received-SPF: pass client-ip=209.85.215.181; envelope-from=acelan@gmail.com; helo=mail-pg1-f181.google.com X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" From: "Chia-Lin Kao (AceLan)" BugLink: https://bugs.launchpad.net/bugs/1981950 aq_nic_deinit() has been called while suspending, so we don't have to call it again on resume. Actually, call it again leads to another hang issue when resuming from S3. Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992345] Call Trace: Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992346] Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992348] aq_nic_deinit+0xb4/0xd0 [atlantic] Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992356] aq_pm_thaw+0x7f/0x100 [atlantic] Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992362] pci_pm_resume+0x5c/0x90 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992366] ? pci_pm_thaw+0x80/0x80 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992368] dpm_run_callback+0x4e/0x120 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992371] device_resume+0xad/0x200 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992373] async_resume+0x1e/0x40 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992374] async_run_entry_fn+0x33/0x120 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992377] process_one_work+0x220/0x3c0 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992380] worker_thread+0x4d/0x3f0 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992382] ? process_one_work+0x3c0/0x3c0 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992384] kthread+0x12a/0x150 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992386] ? set_kthread_struct+0x40/0x40 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992387] ret_from_fork+0x22/0x30 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992391] Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992392] ---[ end trace 1ec8c79604ed5e0d ]--- Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992394] PM: dpm_run_callback(): pci_pm_resume+0x0/0x90 returns -110 Jul 8 03:09:44 u-Precision-7865-Tower kernel: [ 5910.992397] atlantic 0000:02:00.0: PM: failed to resume async: error -110 Fixes: 1809c30b6e5a ("net: atlantic: always deep reset on pm op, fixing up my null deref regression") Signed-off-by: Chia-Lin Kao (AceLan) Link: https://lore.kernel.org/r/20220713111224.1535938-2-acelan.kao@canonical.com Signed-off-by: Paolo Abeni (cherry picked from commit 2e15c51fefaffaf9f72255eaef4fada05055e4c5) Signed-off-by: Chia-Lin Kao (AceLan) --- drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c b/drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c index 8c05b2b793392..a0ce213c473bc 100644 --- a/drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c +++ b/drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c @@ -419,9 +419,6 @@ static int atl_resume_common(struct device *dev) pci_set_power_state(pdev, PCI_D0); pci_restore_state(pdev); - /* Reinitialize Nic/Vecs objects */ - aq_nic_deinit(nic, !nic->aq_hw->aq_nic_cfg->wol); - if (netif_running(nic->ndev)) { ret = aq_nic_init(nic); if (ret)