Received: by 2002:a05:6a10:5594:0:0:0:0 with SMTP id ee20csp600196pxb; Mon, 25 Apr 2022 17:49:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzlgpC5LryBEI1gBzA8pk9r7+HGG4Cyk/hdKfFKw20Sz6y/784eZIue9wDLiOx2d9h4wTfe X-Received: by 2002:a17:907:3e1e:b0:6ef:ebf8:4059 with SMTP id hp30-20020a1709073e1e00b006efebf84059mr18933130ejc.657.1650934195843; Mon, 25 Apr 2022 17:49:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650934195; cv=none; d=google.com; s=arc-20160816; b=e6dGym2XWAA/kEWwMYBoknNntQG3r4GOGw+0M7B/B+q+Y/MLlJR1NtS4S1J76R6/yB Ul0dlVrqkYGD84Fk/MubF9Qd95qWBqgrO+Y4vj/sFSctibzVtJV7LY/HaHW/6RlN41Z4 Aphp66ewGlzKjhTBuq9TOyNs9Q9uu9R4lqy1VmOYuTuDVna022NvBl2zigT18WV+Nax9 xM5CwpZa/EZGNxXfLBW9v7HFPJfZzfbwI2yO+KJhN5WXWRaVUas0ZEaqt02zAk5xgt5X UpkR1obE5gva7WVi34/o/eq4tztaLWoxE1abotWg4Xkyqp51Rq8V8s2M7Hs/xBNdFgv9 GwqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=7qfaiS7UptGcLjv78D3MJ3R6HW7ht14Xm/IpQ4WlFks=; b=wlQn9fKhIMlmyW2Eqmc4XNT1lFEWK+vRmyubsRsSuMTnIhiykZX45pwM17eDdqqyhn 3V9Huxkn8Qn3n3rtZaIy1VcwElRDfsYKLKzYeMVFCcIA4/nIW29ee2ZCfMeC8b9w3aki 3U8SXDi/hk+Y0I6EC17oFNFjsjRoGqQZopxf05J+CxU+LkV7tOigs6PWp3s/KMSheUKP ZiF9YcN/XzYcDgIaR6yiE1UZbHZC0eisTCOKqQqiQhZvflrrLtbuu5reOctaIFmskRYs SE8qi4TUuAKB+S1yak5XCnLRY4seqYSHqiqp9iHwu5amH5TxPSvHT+cGn+jA8gOu2cUO oT5Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=MmhFoO2V; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v16-20020a50f090000000b00425e9f310d3si3769430edl.609.2022.04.25.17.49.32; Mon, 25 Apr 2022 17:49:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=MmhFoO2V; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237076AbiDYXOy (ORCPT + 67 others); Mon, 25 Apr 2022 19:14:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53890 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236623AbiDYXOy (ORCPT ); Mon, 25 Apr 2022 19:14:54 -0400 Received: from mail-pj1-x1035.google.com (mail-pj1-x1035.google.com [IPv6:2607:f8b0:4864:20::1035]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0A6264614D for ; Mon, 25 Apr 2022 16:11:48 -0700 (PDT) Received: by mail-pj1-x1035.google.com with SMTP id iq2-20020a17090afb4200b001d93cf33ae9so662185pjb.5 for ; Mon, 25 Apr 2022 16:11:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=7qfaiS7UptGcLjv78D3MJ3R6HW7ht14Xm/IpQ4WlFks=; b=MmhFoO2V8w9wi8xpsU1YJ3SIL+O1UDp6+GMDMyeQp/HYO0bw9etoHhAaDiQhGx+kCo 9/zrw47FA6hWwth8/g/FVpkVz2aRxuLT2fHCJhSEgPH4TXyXv9Rhv+jTf2zyAbGQTK2X lgZ8uSIrgQAY/M9WgRVxk0xSYXDZ7ttngcP3Q= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=7qfaiS7UptGcLjv78D3MJ3R6HW7ht14Xm/IpQ4WlFks=; b=HfTUp7c/RPb1SKmm/QoBRxHMEVAwP1UpGzBZpVlSTrkffpBFVk6UggGqrvGgmLuUp+ 40eOHvY5yYgm5BCOVvrGoV4JKNfUwwWez4CitT9AEZ3vhjIqnxZ38pShomxU7J/bucWY p+WYbxeAffuTJn/KTyDUa7ubFs/7AVioPgma4u4eATonX1QJt6vn89xodOtnlvkLYj00 SRNB0G9TQxgd3mkysae9zsoPW0fLVWcqCD+7yAND+2wy7qfPV1iXEctk3DVSot7OZGJP RRZhSlS8AMNTPZcgYo/SJNVYlanCEC0NscMWqPAG/M6KVXASpTP615VkWhmCWrFpLo3I P/9g== X-Gm-Message-State: AOAM530CUcpngwmini96LCVbiWHJVinCzS71Wm/yIQNZfDJplX11UqMK +9EMSs4nk2o5B5nk8rYDhsnfxw== X-Received: by 2002:a17:90a:a82:b0:1c9:ef95:486 with SMTP id 2-20020a17090a0a8200b001c9ef950486mr34213615pjw.93.1650928307416; Mon, 25 Apr 2022 16:11:47 -0700 (PDT) Received: from google.com ([2620:15c:202:201:84c6:2d6d:c16:1a1b]) by smtp.gmail.com with ESMTPSA id f4-20020aa782c4000000b00505da6251ebsm12495302pfn.154.2022.04.25.16.11.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Apr 2022 16:11:46 -0700 (PDT) Date: Mon, 25 Apr 2022 16:11:44 -0700 From: Brian Norris To: Abhishek Kumar Cc: kvalo@kernel.org, linux-kernel@vger.kernel.org, linux-wireless@vger.kernel.org, ath10k@lists.infradead.org, netdev@vger.kernel.org, Wen Gong , "David S. Miller" , Jakub Kicinski , Paolo Abeni Subject: Re: [PATCH] ath10k: skip ath10k_halt during suspend for driver state RESTARTING Message-ID: References: <20220425021442.1.I650b809482e1af8d0156ed88b5dc2677a0711d46@changeid> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220425021442.1.I650b809482e1af8d0156ed88b5dc2677a0711d46@changeid> X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On Mon, Apr 25, 2022 at 02:15:20AM +0000, Abhishek Kumar wrote: > --- a/drivers/net/wireless/ath/ath10k/mac.c > +++ b/drivers/net/wireless/ath/ath10k/mac.c > @@ -5345,8 +5345,22 @@ static void ath10k_stop(struct ieee80211_hw *hw) > > mutex_lock(&ar->conf_mutex); > if (ar->state != ATH10K_STATE_OFF) { > - if (!ar->hw_rfkill_on) > - ath10k_halt(ar); > + if (!ar->hw_rfkill_on) { > + /* If the current driver state is RESTARTING but not yet > + * fully RESTARTED because of incoming suspend event, > + * then ath11k_halt is already called via s/ath11k/ath10k/ I know ath11k is the hot new thing, but this is ath10k ;) > + * ath10k_core_restart and should not be called here. s/ath10k/ath11k/ > + */ > + if (ar->state != ATH10K_STATE_RESTARTING) > + ath10k_halt(ar); > + else > + /* Suspending here, because when in RESTARTING > + * state, ath11k_core_stop skips s/ath10k/ath11k/ > + * ath10k_wait_for_suspend. > + */ > + ath10k_wait_for_suspend(ar, > + WMI_PDEV_SUSPEND_AND_DISABLE_INTR); > + } > ar->state = ATH10K_STATE_OFF; > } > mutex_unlock(&ar->conf_mutex); Otherwise, I believe this is the right solution to the problem pointed out in the commit message: Reviewed-by: Brian Norris