Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp5653355ybi; Tue, 4 Jun 2019 09:52:27 -0700 (PDT) X-Google-Smtp-Source: APXvYqwNOvNeqPGqNYao8QNQ7E4z67FpGU0/Zp4P9ZhUAi0N2KFgRJuH7s3CFS/7+hGm88FmEnK/ X-Received: by 2002:a17:902:8c83:: with SMTP id t3mr12422589plo.93.1559667147462; Tue, 04 Jun 2019 09:52:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559667147; cv=none; d=google.com; s=arc-20160816; b=mKxPrqGR/ZQL1OHZKm52PZAyfbW6OzdanBmRir6MbC4sP2UoiAvcw+OJ6Tvkuco9+m T4yg0rMEXQLRvxcg5GwLukcwbDJ3IhNDMqmmpmlkG3HPi9ZQ/ACMzAFbouQeHTW801Zq oJLJm6yyPOnsC6bCXIEV1VtTdYM0iVnvL1am/sIckpn/LV3nxdoRviRzlq88aeoyqIoj i4SiyuydxZv6ynEjb9ZzMkWGZYZVLyOkMFAkRY2HN8RozFH3PHX4YPeOH+Dvza7KC4rL HDMUPNGR83Xspkh+t2yfEWIFZxMm15Vyyl5NTk92/06DL9xYEGq563lQLH3Z6hR420L+ Q7+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :subject:user-agent:references:in-reply-to:message-id:date:cc:to :from:dkim-signature; bh=htJGxlotLvs1Z4U6dZKpFxplNjTIfrsnnYtpYuTDheU=; b=xYVX4YVs5kP1xb+GBBuA1TD1GHCNwHa0aN5UB1aj3oiB1zIw1ijD7NEDttoaeo6G7E gZEwnqvKEInzjOiCDqTo/HidhZng2LlOFkDNVHop3qDVBzSJ6sf0dlxSSO2ol7TIi8AD DtP7E3dSe12gaiNY3jVkqMR5JDdxO3hMRE+i7bds6uVx59RC7A3gaNqz2ogPclEJryyC wU1aZzj30WysBLjDQ/MAY3V2pon8I/2JWbcPHE82CsmH+vsRT+Oqpy4vFtuY283a3ILA cRzqJrcK1l4diM8hewFf3285AwhDr4msplEbgPZEEzBE/Bwd3g3FEu6b10LAh8vKknlp THcg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@broadcom.com header.s=google header.b=R65lslW4; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadcom.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 36si14597989pgn.174.2019.06.04.09.52.10; Tue, 04 Jun 2019 09:52:27 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@broadcom.com header.s=google header.b=R65lslW4; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadcom.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727966AbfFDQtG (ORCPT + 99 others); Tue, 4 Jun 2019 12:49:06 -0400 Received: from mail-ed1-f68.google.com ([209.85.208.68]:37864 "EHLO mail-ed1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727813AbfFDQtF (ORCPT ); Tue, 4 Jun 2019 12:49:05 -0400 Received: by mail-ed1-f68.google.com with SMTP id w13so1384678eds.4 for ; Tue, 04 Jun 2019 09:49:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:date:message-id:in-reply-to:references:user-agent :subject:mime-version:content-transfer-encoding; bh=htJGxlotLvs1Z4U6dZKpFxplNjTIfrsnnYtpYuTDheU=; b=R65lslW41TgbT3+HYxMMjdC1uaQkK3+KBb3U0Ny04v00ZXQz0M5njpJO0tzBd/YuNW RxIApA/5BN6eLgog0OTyD225kmO2K54y61DD+jOoUglq8uH3oRxCm/TWybHsmKXMFkWn c/6tNH9A+v0XZFWm5dCH8txy2CUadmZk/a7Gk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:date:message-id:in-reply-to :references:user-agent:subject:mime-version :content-transfer-encoding; bh=htJGxlotLvs1Z4U6dZKpFxplNjTIfrsnnYtpYuTDheU=; b=cLknR2KSJR0J7EGl/6ZVNjRIqDqK7rcPqwrXHc1aosL3K0Wspyf/yNGm/I46KoPj4o Ai4GX24tC1vXVtDxTmB0KJoFcV1v2ZE8+uEDhcsp/eSOmqftPDS5XaGEV9EhGkipsqtX VUp+jmBvwhFFD59mGHmcqffyT5mx10U0ZF9MW21B4sqQQrFJmMGwoUuK+P1l5aolQHZh 4zNkVmPS4JvOH/Bx2Tk3/UGfMvYNTSG93GNimFZZKNQPV/GYxBopHM5dByN6W4n/pXp3 rx8ZtMF1jAKHaWhpl2Qh421dADuA3wBYNHIhNXbhpPovTSGE8sWcM6D3XSYR6u3Hhu47 L6nw== X-Gm-Message-State: APjAAAWaQOth2Z8MpxLWaPU9jBPpXdYMNJLfGbVtghMYQQB1C3DCykyG fk1aZ4d0d9UOjVa2YCK1r1HS0Q== X-Received: by 2002:a17:906:d7ab:: with SMTP id pk11mr11277278ejb.216.1559666943273; Tue, 04 Jun 2019 09:49:03 -0700 (PDT) Received: from [192.168.178.17] (f140230.upc-f.chello.nl. [80.56.140.230]) by smtp.gmail.com with ESMTPSA id e45sm4818556edb.12.2019.06.04.09.48.58 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 04 Jun 2019 09:49:02 -0700 (PDT) From: Arend Van Spriel To: Doug Anderson , Wright Feng CC: Kalle Valo , Madhan Mohan R , Ulf Hansson , LKML , Hante Meuleman , "David S. Miller" , netdev , "Chi-Hsien Lin" , Brian Norris , "linux-wireless" , YueHaibing , Adrian Hunter , "open list:ARM/Rockchip SoC..." , , Matthias Kaehlcke , Naveen Gupta , "brcm80211-dev-list" , Double Lo , Franky Lin Date: Tue, 04 Jun 2019 18:48:57 +0200 Message-ID: <16b2364c8c0.2764.9b12b7fc0a3841636cfb5e919b41b954@broadcom.com> In-Reply-To: References: <20190517225420.176893-2-dianders@chromium.org> <20190528121833.7D3A460A00@smtp.codeaurora.org> <16aff33f3e0.2764.9b12b7fc0a3841636cfb5e919b41b954@broadcom.com> <16aff358a20.2764.9b12b7fc0a3841636cfb5e919b41b954@broadcom.com> <40587a64-490b-8b1e-8a11-1e1aebdab2f3@cypress.com> User-Agent: AquaMail/1.20.0-1451 (build: 102000001) Subject: Re: [PATCH 1/3] brcmfmac: re-enable command decode in sdio_aos for BRCM 4354 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="UTF-8" Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On June 4, 2019 6:01:26 PM Doug Anderson wrote: > Hi, > > On Mon, Jun 3, 2019 at 8:20 PM Wright Feng wrote: >> >> On 2019/5/29 上午 12:11, Arend Van Spriel wrote: >> > On May 28, 2019 6:09:21 PM Arend Van Spriel >> > wrote: >> > >> >> On May 28, 2019 5:52:10 PM Doug Anderson wrote: >> >> >> >>> Hi, >> >>> >> >>> On Tue, May 28, 2019 at 5:18 AM Kalle Valo wrote: >> >>>> >> >>>> Douglas Anderson wrote: >> >>>> >> >>>> > In commit 29f6589140a1 ("brcmfmac: disable command decode in >> >>>> > sdio_aos") we disabled something called "command decode in sdio_aos" >> >>>> > for a whole bunch of Broadcom SDIO WiFi parts. >> >>>> > >> >>>> > After that patch landed I find that my kernel log on >> >>>> > rk3288-veyron-minnie and rk3288-veyron-speedy is filled with: >> >>>> > brcmfmac: brcmf_sdio_bus_sleep: error while changing bus sleep >> >>>> state -110 >> >>>> > >> >>>> > This seems to happen every time the Broadcom WiFi transitions out of >> >>>> > sleep mode. Reverting the part of the commit that affects the >> >>>> WiFi on >> >>>> > my boards fixes the problem for me, so that's what this patch does. >> >>>> > >> >>>> > Note that, in general, the justification in the original commit >> >>>> seemed >> >>>> > a little weak. It looked like someone was testing on a SD card >> >>>> > controller that would sometimes die if there were CRC errors on the >> >>>> > bus. This used to happen back in early days of dw_mmc (the >> >>>> controller >> >>>> > on my boards), but we fixed it. Disabling a feature on all boards >> >>>> > just because one SD card controller is broken seems bad. ...so >> >>>> > instead of just this patch possibly the right thing to do is to fully >> >>>> > revert the original commit. >> >>>> > >> Since the commit 29f6589140a1 ("brcmfmac: disable command decode in >> sdio_aos") causes the regression on other SD card controller, it is >> better to revert it as you mentioned. >> Actually, without the commit, we hit MMC timeout(-110) and hanged >> instead of CRC error in our test. > > Any chance I can convince you to provide some official tags like > Reviewed-by or Tested-by on the revert? > >> Would you please share the analysis of >> dw_mmc issue which you fixed? We'd like to compare whether we got the >> same issue. > > I'm not sure there's any single magic commit I can point to. When I > started working on dw_mmc it was terrible at handling error cases and > would often crash / hang / stop all future communication upon certain > classes or efforts. There were dozens of problems we've had to fix > over the years. These problems showed up when we started supporting > HS200 / UHS since the tuning phase really stress the error handling of > the host controller. > > I searched and by the time we were supporting Broadcom SDIO cards the > error handling was already pretty good. ...but if we hadn't already > made the error handling more robust for UHS tuning then we would have > definitely hit these types of problems. The only problem I remember > having to solve in dw_mmc that was unique to Broadcom was commit > 0bdbd0e88cf6 ("mmc: dw_mmc: Don't start commands while busy"). Any > chance that could be what you're hitting? That is indeed an issue I recall resulting in -110 errors. > What host controller are you having problems with? Knowing that will be a good start. Regards, Arend