Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp246894pxf; Wed, 31 Mar 2021 02:16:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw0CMg3i4lDOT1ztOZnF1QUZOHBcJ9Dns/zGORbu/WBoJ2JQSyZmce8yvVSuKBQsS+5jIoH X-Received: by 2002:a17:906:938f:: with SMTP id l15mr2445010ejx.15.1617182168568; Wed, 31 Mar 2021 02:16:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1617182168; cv=none; d=google.com; s=arc-20160816; b=o7YsaspX4hheaWe2sBNyi6oDHxXUwCR88YjrxCeV16EwnOsSUFLcYl87qAYJu3+yX0 wK7gX/0cUStwOgAwH92GSKvcaokhFDWfivbMMFTTSXRVf7LENQDDsz8IyHPFmr7rbqpI 7YMdtDzNBeBY8HzrySBlbj0+JgOEP+slsn5R1fPH9rQr7DBcHQth8pVGIbY7QkRlNcwN hcIXMf6oAZbWPZ7HROAyxNPJ3SzQ3kRbqBP5AeYzX7Q0QlYxkkbwJYq391fl3ZTCob8a H5G0jGH7NuzfycLWu/qtMrG321SpHDt6f4fwsdp81S0OIJIlKnlJXIgrX76PH13ezJDV NNUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:subject:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:cc:to:from; bh=J7+ctOwdmPDuXgw0+LSFDNUhyIw7+I3FlyjuNhsgtdQ=; b=qFc9IyLTYlKE3zFSTP8bi3it4W3wCxedI6AYkEas09RobuRu/ngCZW/rgyzxM7LPVq sAi+N0ECnsfGwS9uA0JyW5JXV2YTwVk3gdtJ3PklJc5isNDwBYzToMS/pqtqjTx02LHu 92rOU1w1HzQQJR0SvjZoTORQcQYaKT7QBMELN7tS4TSQPP3iZQ96XXPmND8q08NbLc3S 63lrj1rftTFYN/LLtSZyK13Cni/J1+llSPXZwWlicFCA9+U62dfbkqq3OeMbD9JKeKBD tnD5f00JVSYdRxeCOpODU2RNy/RSK/in2EZRLWdTpvFMIvCsek2h7+J7p27dXvy/W1ii CEiA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i11si1531799edb.41.2021.03.31.02.15.45; Wed, 31 Mar 2021 02:16:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234621AbhCaJPE (ORCPT + 99 others); Wed, 31 Mar 2021 05:15:04 -0400 Received: from paleale.coelho.fi ([176.9.41.70]:43730 "EHLO farmhouse.coelho.fi" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S234675AbhCaJO4 (ORCPT ); Wed, 31 Mar 2021 05:14:56 -0400 Received: from 91-156-6-193.elisa-laajakaista.fi ([91.156.6.193] helo=kveik.ger.corp.intel.com) by farmhouse.coelho.fi with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1lRWw9-00087q-AM; Wed, 31 Mar 2021 12:14:54 +0300 From: Luca Coelho To: kvalo@codeaurora.org Cc: linux-wireless@vger.kernel.org Date: Wed, 31 Mar 2021 12:14:41 +0300 Message-Id: X-Mailer: git-send-email 2.31.0 In-Reply-To: <20210331091452.543321-1-luca@coelho.fi> References: <20210331091452.543321-1-luca@coelho.fi> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Checker-Version: SpamAssassin 3.4.5-pre1 (2020-06-20) on farmhouse.coelho.fi X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, TVD_RCVD_IP autolearn=ham autolearn_force=no version=3.4.5-pre1 Subject: [PATCH 01/12] iwlwifi: mvm: write queue_sync_state only for sync Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org From: Johannes Berg We use mvm->queue_sync_state to wait for synchronous queue sync messages, but if an async one happens inbetween we shouldn't clear mvm->queue_sync_state after sending the async one, that can run concurrently (at least from the CPU POV) with another synchronous queue sync. Signed-off-by: Johannes Berg Signed-off-by: Luca Coelho --- drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c b/drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c index 9ed6e2783cc4..fbd37a19b6e0 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c @@ -5177,9 +5177,10 @@ void iwl_mvm_sync_rx_queues_internal(struct iwl_mvm *mvm, } out: - mvm->queue_sync_state = 0; - if (notif->sync) + if (notif->sync) { + mvm->queue_sync_state = 0; mvm->queue_sync_cookie++; + } } static void iwl_mvm_sync_rx_queues(struct ieee80211_hw *hw) -- 2.31.0