Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3944010ybb; Mon, 23 Mar 2020 10:31:34 -0700 (PDT) X-Google-Smtp-Source: ADFU+vtOq0lIyvKd2J2EPZnISNBW21zvcSTr/GDOazH3k81P2sSVPfe5w/VQUxI6/DMC05DrWC1b X-Received: by 2002:a05:6808:4e:: with SMTP id v14mr366053oic.70.1584984693840; Mon, 23 Mar 2020 10:31:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584984693; cv=none; d=google.com; s=arc-20160816; b=opXOfz5ADMJf9LoAqc5FsAdxKXE9VKIILc9UZM3rkyHUA/shp6QzgCPfl3ZPOL5R01 u81ow1U6WqpnBha8Fa0mQZz0zjRRbynNLoO0UsNlnRANek8qiImABEd1eMI9SRXEWvEY JeKM204VPUgauQhvLcxnDaPmIV+IXIG96uCGnl6gtjOIxoQ3EATgy6umB5xTX1JTPm5T rYDqDDC5sgniX5qxi4mrj8R0+Me4ybLnSBPJDOxn83vLSg73DTp//PPAyWw8FM7Ln/Ht TM6B/K4qbkPDIQtuwpLWdzgAnNoGsiHnExw/L43jGFi/H0lsIHGXsJPboYeVxQquINN0 T6UQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:message-id:user-agent:cc:to :references:in-reply-to:from:subject:content-transfer-encoding :mime-version:dmarc-filter:dkim-signature; bh=beW3neEbD2l7ePHYdP9+6I+i4KNemNKMexcFJx/fAqw=; b=PFU2jJo3GnHIWIlObWjx1hAjtvchsLwBqrhNOiYKHyeXAF++eBLRxVISyICNa2X2YW 8Ktb7ZOeroII+SKPcfdFr6FBFwqliOfZHXxrnl79OAE/L9b/DJDBZkuz0+HLDDGnGtAq jDFR/IhGfINU2hY7ofoJJK4If7ULI9aR5ngp71eZVn6O7ZC8txeENSg4vnHlxOWI9wrk mI1hUySKOzYLv9TdczNRQD2/ZWlSHCOCKqBbYKBntTa1t/s0B8D41/fbpa5tAOtdXHyI l3socrBD80q9RnBwd4G8c5y7jtoszzU37Uita5ArSoZfdnZx430oYS0FTQQ+6BpRVbrB zYkw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@mg.codeaurora.org header.s=smtp header.b=jcLlQ8aI; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y123si8147514oia.141.2020.03.23.10.31.19; Mon, 23 Mar 2020 10:31:33 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@mg.codeaurora.org header.s=smtp header.b=jcLlQ8aI; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727763AbgCWRah (ORCPT + 99 others); Mon, 23 Mar 2020 13:30:37 -0400 Received: from mail26.static.mailgun.info ([104.130.122.26]:41098 "EHLO mail26.static.mailgun.info" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727372AbgCWRah (ORCPT ); Mon, 23 Mar 2020 13:30:37 -0400 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1584984636; h=Date: Message-Id: Cc: To: References: In-Reply-To: From: Subject: Content-Transfer-Encoding: MIME-Version: Content-Type: Sender; bh=beW3neEbD2l7ePHYdP9+6I+i4KNemNKMexcFJx/fAqw=; b=jcLlQ8aIxOpGlI8Ewl0SLvbiW9kOM39i2+ykm4NzaMfvtYQFxBQTHFrgUSz+O7tgEqGj3QpY whG+amyJYYo4KEGBe8l245HiAlbQ5+x2oM0ngIRvPeUftIV4gt4drkMdV2GpKtJPkHTSUL93 VMFoF/EtgIgKN+/XisAaAA6d7qU= X-Mailgun-Sending-Ip: 104.130.122.26 X-Mailgun-Sid: WyI3YTAwOSIsICJsaW51eC13aXJlbGVzc0B2Z2VyLmtlcm5lbC5vcmciLCAiYmU5ZTRhIl0= Received: from smtp.codeaurora.org (ec2-35-166-182-171.us-west-2.compute.amazonaws.com [35.166.182.171]) by mxa.mailgun.org with ESMTP id 5e78f236.7f6574652110-smtp-out-n02; Mon, 23 Mar 2020 17:30:30 -0000 (UTC) Received: by smtp.codeaurora.org (Postfix, from userid 1001) id C8C57C433D2; Mon, 23 Mar 2020 17:30:30 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-caf-mail-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=0.5 required=2.0 tests=ALL_TRUSTED,MISSING_DATE, MISSING_MID,SPF_NONE,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from potku.adurom.net (88-114-240-156.elisa-laajakaista.fi [88.114.240.156]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: kvalo) by smtp.codeaurora.org (Postfix) with ESMTPSA id 73B07C432C2; Mon, 23 Mar 2020 17:30:29 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 73B07C432C2 Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; spf=none smtp.mailfrom=kvalo@codeaurora.org Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: Re: [PATCH 1/5] rtw88: don't hold all IRQs disabled for PS operations From: Kalle Valo In-Reply-To: <20200312080852.16684-2-yhchuang@realtek.com> References: <20200312080852.16684-2-yhchuang@realtek.com> To: Cc: , User-Agent: pwcli/0.0.0-git (https://github.com/kvalo/pwcli/) Python/2.7.12 Message-Id: <20200323173030.C8C57C433D2@smtp.codeaurora.org> Date: Mon, 23 Mar 2020 17:30:30 +0000 (UTC) Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org wrote: > From: Brian Norris > > This driver generally only needs to ensure that > (a) it doesn't try to process TX interrupts at the same time as > power-save operations (and similar) > (b) the device interrupt gets disabled while we're still handling the > last set of interrupts > > For (a), all the operations (e.g., PS transitions, packet handling) > happens in non-atomic contexts (e.g., threaded IRQ). > > For (b), we only need mutual exclusion for brief sections (i.e., while > we're actually manipulating the interrupt mask/status). > > So, we can introduce a separate lock for handling (b), disabling IRQs > while we do it. For (a), we can demote the locking to BH only, now that > (b) (the only steps done in atomic context) and that has its own lock. > > This helps reduce the amount of time this driver spends with IRQs off. > Notably, transitioning out of power-save modes can take >3 milliseconds, > and this transition is done under the protection of 'irq_lock'. > > Signed-off-by: Brian Norris > Signed-off-by: Yan-Hsuan Chuang 5 patches applied to wireless-drivers-next.git, thanks. 57fb39e24775 rtw88: don't hold all IRQs disabled for PS operations da14a0409e3f rtw88: extract alloc rsvd_page and h2c skb routines 895c096dab36 rtw88: associate reserved pages with each vif a5697a65ecd1 rtw88: pci: define a mask for TX/RX BD indexes aaab5d0e6737 rtw88: kick off TX packets once for higher efficiency -- https://patchwork.kernel.org/patch/11433447/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches