From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 72912C433E7 for ; Tue, 1 Sep 2020 12:38:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 4C1C2206CD for ; Tue, 1 Sep 2020 12:38:02 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=mg.codeaurora.org header.i=@mg.codeaurora.org header.b="XcLS7x1E" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728054AbgIAMhl (ORCPT ); Tue, 1 Sep 2020 08:37:41 -0400 Received: from m43-7.mailgun.net ([69.72.43.7]:30441 "EHLO m43-7.mailgun.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728220AbgIAMhA (ORCPT ); Tue, 1 Sep 2020 08:37:00 -0400 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1598963819; h=Content-Type: MIME-Version: Message-ID: In-Reply-To: Date: References: Subject: Cc: To: From: Sender; bh=6ggmUpFUZi20zjrVfQ8keaKSiZwjYpcqjxlqq5XSN3A=; b=XcLS7x1EhOWZBLadXB4xzcDsK25xHiP/Bj7P9lwiNJBfOCvetyUM3dk33npGSOcc0+gDcyBM x+g8IhW2a+3z/QMbiQNFBSB4lA/KWyILMTDkMNzt9yVcqfxvtbJyebt22+NkndI+qWn2t63j 6ZXvD0h3djCaGkbLX0V6JmrpZsk= X-Mailgun-Sending-Ip: 69.72.43.7 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 smtp-out-n02.prod.us-east-1.postgun.com with SMTP id 5f4e3b2e54e87432bef9dea1 (version=TLS1.2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256); Tue, 01 Sep 2020 12:14:38 GMT Received: by smtp.codeaurora.org (Postfix, from userid 1001) id C4F71C433A0; Tue, 1 Sep 2020 12:14:37 +0000 (UTC) Received: from potku.adurom.net (88-114-240-156.elisa-laajakaista.fi [88.114.240.156]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: kvalo) by smtp.codeaurora.org (Postfix) with ESMTPSA id 01D67C433C6; Tue, 1 Sep 2020 12:14:32 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 01D67C433C6 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 From: Kalle Valo To: Doug Anderson Cc: Sai Prakash Ranjan , linux-arm-msm , Brian Norris , linux-wireless , LKML , ath10k , Rakesh Pillai , netdev , Jakub Kicinski , "David S. Miller" , Abhishek Kumar Subject: Re: [PATCH v2 1/2] ath10k: Keep track of which interrupts fired, don't poll them References: <20200709082024.v2.1.I4d2f85ffa06f38532631e864a3125691ef5ffe06@changeid> <20200826145011.C4E48C43387@smtp.codeaurora.org> Date: Tue, 01 Sep 2020 15:14:31 +0300 In-Reply-To: (Doug Anderson's message of "Wed, 26 Aug 2020 07:59:52 -0700") Message-ID: <87blip66e0.fsf@codeaurora.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Doug Anderson writes: > On Wed, Aug 26, 2020 at 7:51 AM Kalle Valo wrote: >> >> Douglas Anderson wrote: >> >> > If we have a per CE (Copy Engine) IRQ then we have no summary >> > register. Right now the code generates a summary register by >> > iterating over all copy engines and seeing if they have an interrupt >> > pending. >> > >> > This has a problem. Specifically if _none_ if the Copy Engines have >> > an interrupt pending then they might go into low power mode and >> > reading from their address space will cause a full system crash. This >> > was seen to happen when two interrupts went off at nearly the same >> > time. Both were handled by a single call of ath10k_snoc_napi_poll() >> > but, because there were two interrupts handled and thus two calls to >> > napi_schedule() there was still a second call to >> > ath10k_snoc_napi_poll() which ran with no interrupts pending. >> > >> > Instead of iterating over all the copy engines, let's just keep track >> > of the IRQs that fire. Then we can effectively generate our own >> > summary without ever needing to read the Copy Engines. >> > >> > Tested-on: WCN3990 SNOC WLAN.HL.3.2.2-00490-QCAHLSWMTPL-1 >> > >> > Signed-off-by: Douglas Anderson >> > Reviewed-by: Rakesh Pillai >> > Reviewed-by: Brian Norris >> > Signed-off-by: Kalle Valo >> >> My main concern of this patch is that there's no info how it works on other >> hardware families. For example, QCA9984 is very different from WCN3990. The >> best would be if someone can provide a Tested-on tags for other hardware (even >> some of them). > > I simply don't have access to any other Atheros hardware. Hopefully > others on this thread do, though? I have the hardware but in practise no time to do the testing :/ > ...but, if nothing else, I believe code inspection shows that the only > places that are affected by the changes here are: > > * Wifi devices that use "snoc.c". The only compatible string listed > in "snoc.c" is wcn3990. > > * Wifi devices that set "per_ce_irq" to true. The only place in the > table where this is set to true is wcn3990. > > While it is certainly possible that I messed up and somehow affected > other WiFi devices, the common bits of code in "ce.c" and "ce.h" are > fairly easy to validate so hopefully they look OK? Basically I would like to see some evidence in the commit log that _all_ hardware families are taken into account to avoid any regressions, be it testing or at least thorough review. I see way too many patches where people are working just on one hardware/firmware combo and not giving a single thought how it would work on other hardware. But I applied the three patches now, let's hope they are ok. At least I was not able to find any problems during review, but of course real testing would be better than just review. -- https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from m43-7.mailgun.net ([69.72.43.7]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kD5BP-00028O-53 for ath10k@lists.infradead.org; Tue, 01 Sep 2020 12:14:40 +0000 From: Kalle Valo Subject: Re: [PATCH v2 1/2] ath10k: Keep track of which interrupts fired, don't poll them References: <20200709082024.v2.1.I4d2f85ffa06f38532631e864a3125691ef5ffe06@changeid> <20200826145011.C4E48C43387@smtp.codeaurora.org> Date: Tue, 01 Sep 2020 15:14:31 +0300 In-Reply-To: (Doug Anderson's message of "Wed, 26 Aug 2020 07:59:52 -0700") Message-ID: <87blip66e0.fsf@codeaurora.org> MIME-Version: 1.0 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "ath10k" Errors-To: ath10k-bounces+kvalo=adurom.com@lists.infradead.org To: Doug Anderson Cc: Sai Prakash Ranjan , linux-arm-msm , Brian Norris , linux-wireless , LKML , ath10k , Rakesh Pillai , netdev , Jakub Kicinski , "David S. Miller" , Abhishek Kumar Doug Anderson writes: > On Wed, Aug 26, 2020 at 7:51 AM Kalle Valo wrote: >> >> Douglas Anderson wrote: >> >> > If we have a per CE (Copy Engine) IRQ then we have no summary >> > register. Right now the code generates a summary register by >> > iterating over all copy engines and seeing if they have an interrupt >> > pending. >> > >> > This has a problem. Specifically if _none_ if the Copy Engines have >> > an interrupt pending then they might go into low power mode and >> > reading from their address space will cause a full system crash. This >> > was seen to happen when two interrupts went off at nearly the same >> > time. Both were handled by a single call of ath10k_snoc_napi_poll() >> > but, because there were two interrupts handled and thus two calls to >> > napi_schedule() there was still a second call to >> > ath10k_snoc_napi_poll() which ran with no interrupts pending. >> > >> > Instead of iterating over all the copy engines, let's just keep track >> > of the IRQs that fire. Then we can effectively generate our own >> > summary without ever needing to read the Copy Engines. >> > >> > Tested-on: WCN3990 SNOC WLAN.HL.3.2.2-00490-QCAHLSWMTPL-1 >> > >> > Signed-off-by: Douglas Anderson >> > Reviewed-by: Rakesh Pillai >> > Reviewed-by: Brian Norris >> > Signed-off-by: Kalle Valo >> >> My main concern of this patch is that there's no info how it works on other >> hardware families. For example, QCA9984 is very different from WCN3990. The >> best would be if someone can provide a Tested-on tags for other hardware (even >> some of them). > > I simply don't have access to any other Atheros hardware. Hopefully > others on this thread do, though? I have the hardware but in practise no time to do the testing :/ > ...but, if nothing else, I believe code inspection shows that the only > places that are affected by the changes here are: > > * Wifi devices that use "snoc.c". The only compatible string listed > in "snoc.c" is wcn3990. > > * Wifi devices that set "per_ce_irq" to true. The only place in the > table where this is set to true is wcn3990. > > While it is certainly possible that I messed up and somehow affected > other WiFi devices, the common bits of code in "ce.c" and "ce.h" are > fairly easy to validate so hopefully they look OK? Basically I would like to see some evidence in the commit log that _all_ hardware families are taken into account to avoid any regressions, be it testing or at least thorough review. I see way too many patches where people are working just on one hardware/firmware combo and not giving a single thought how it would work on other hardware. But I applied the three patches now, let's hope they are ok. At least I was not able to find any problems during review, but of course real testing would be better than just review. -- https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches _______________________________________________ ath10k mailing list ath10k@lists.infradead.org http://lists.infradead.org/mailman/listinfo/ath10k