Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp1321965pxk; Fri, 25 Sep 2020 11:35:32 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwAONuMXNIsvLAO1gW6DDYga2jNRutrjJ09RN58m0WXysrOq7w4KX1n2D9UleVnjRnrZcpp X-Received: by 2002:a17:906:556:: with SMTP id k22mr3963244eja.369.1601058932427; Fri, 25 Sep 2020 11:35:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601058932; cv=none; d=google.com; s=arc-20160816; b=vdJErZZft+gl6hWP4aGcASA0LI/rktmbGXspCptz3XpPhDNl0e3xpGJYPbzmjmCKmx 359633TT2JVeIn2nnyJTxbG27ZxctBW0EhjFDLSd6rS+A1iWcy8kcallmKBUY6H2mVxH DZLnsc4j/lbN5rAyVWhf+S6kpburNDO2XxAyVajHN8W2eL9y/brFfDE7VuUa37LrMsl6 B4VB/PUsV2UGjX8pURkGRJDevflGjK/nxoPFCP7xk7Auew360ncDUjKG5TcwFY/StY2K PDsmMCmEypeafzJesQGo4Iu3kC5c88orcvAHrO/dgdgYBvNrQa+JapnIHnMmJ34yz4el y/ag== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=6wr5b8CFYdqzzo6Xedl1l6pleUPcSYgGVWdKtDphUtU=; b=rV7nLCf1oTMCEl2ndyRZUVPWylA2UV1nHuPQM0GP3K3Ul8QBLk5AUnQlv2UsD1Fq/U +PciP9wlw0s1boWPwJnivnAqxTkOamHLyBdqFfxZmudhKnlFJLu3IB2yq5N6AbFld1h3 FPgI4zyKhcwnLii08nEi/KZ2JwQEW77wBuQDBpI6qzg+fTtNVt5nnYELsmIYa5qIZYdn aDAfXI+tllOdWO0j7VH3bB9DNF5aHlFHOQV5Y8+CPaLnCeKqs3f88U0+GwKKMPZ3mzzS 3lqAP6Wa3qb4EG2iel2uCRySWGy2i+3jckxxTxd9JztwjG3ZMlZ1iKq62s+zYW5YxR+m JVow== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IHDkMpVx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cw15si2341269edb.299.2020.09.25.11.35.08; Fri, 25 Sep 2020 11:35:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IHDkMpVx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729993AbgIYSdN (ORCPT + 99 others); Fri, 25 Sep 2020 14:33:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35346 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729770AbgIYSdL (ORCPT ); Fri, 25 Sep 2020 14:33:11 -0400 Received: from mail-wm1-x343.google.com (mail-wm1-x343.google.com [IPv6:2a00:1450:4864:20::343]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7F631C0613CE for ; Fri, 25 Sep 2020 11:33:11 -0700 (PDT) Received: by mail-wm1-x343.google.com with SMTP id x23so4034016wmi.3 for ; Fri, 25 Sep 2020 11:33:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=6wr5b8CFYdqzzo6Xedl1l6pleUPcSYgGVWdKtDphUtU=; b=IHDkMpVxwv/dF8C95VxnNNlR2HFW37aiZNZWFsIwEJEURZGGBHDbEuaG5yMtGs7Sce ZKGVnSDDFZaRvuTicpWkk1reDSLon0PS7d+uwgJuIcfROO482TDn2DixCWyPFCHN/4PX munK4n6yIq0pv7+ouU4T87VyALlYwRm319Ucu3a+XT/bbXEYiG6eJaGHi5BCbHkE5eWy fAwZiF2ecRHcQAJopNydaYIFLByoRdZSMIvmBj1kWYofEmArWiPbhuKsmuLFwZm9GIFp ZGRsbSkTfS1igKgJRB9c71NM4mQ2PO/r994MgJmTUzJCJFFgIF6BHPmzvA7bdlI6jvTY 82Cw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=6wr5b8CFYdqzzo6Xedl1l6pleUPcSYgGVWdKtDphUtU=; b=nk1UMCCRzCth/+46PtK6z2ztTUIR7B1u8nB9fdjqfr9Nanq0tR3goKAJXrWJlx1UyR d8rRkqWpvikB71+or2x1n1c2nWTy+snthJsPmeKDyF1xGwRViuhAbRJ7vnxvFfHGhAt5 RWu8bU4yr5mHaI+DZFSxFYyUJdFQdAftOG1j8LJLAwd191PEVjiyKd2NnFfz9Q58lwpp tnMfcCl0E+t3u1S1/2Ef1oaIBjO484jryg/fCUEbvJ3wdvtBrllEB/7kwGYC9vGGqfUl DW2hpCz5WpSBVbgvtinRffmPDNRkEJAe3u7pW9nIrWnwoy2MYGtxCwBZ1wMdeRozCil3 bMhA== X-Gm-Message-State: AOAM530CHdkF32Hno2sCuIxFT0G1VrYk1hBpyRuPJKsNOwJWnMIBvvgu 5oGyi4N5gI+X5G0hBvcDlw932rs7YXZqV3ZFcNigfw== X-Received: by 2002:a7b:c38f:: with SMTP id s15mr4603352wmj.16.1601058790123; Fri, 25 Sep 2020 11:33:10 -0700 (PDT) MIME-Version: 1.0 References: <1600328501-8832-1-git-send-email-amit.pundir@linaro.org> <87d02bnnll.fsf@codeaurora.org> <20200925152739.GE2510@yoga> In-Reply-To: <20200925152739.GE2510@yoga> From: Amit Pundir Date: Sat, 26 Sep 2020 00:02:33 +0530 Message-ID: Subject: Re: [PATCH] ath10k: qmi: Skip host capability request for Xiaomi Poco F1 To: Bjorn Andersson Cc: Kalle Valo , David S Miller , Jakub Kicinski , Jeffrey Hugo , netdev@vger.kernel.org, linux-wireless@vger.kernel.org, Konrad Dybcio , ath10k , lkml , John Stultz , Sumit Semwal Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 25 Sep 2020 at 20:57, Bjorn Andersson wrote: > > On Thu 24 Sep 11:31 CDT 2020, Kalle Valo wrote: > > > Amit Pundir writes: > > > > > Workaround to get WiFi working on Xiaomi Poco F1 (sdm845) > > > phone. We get a non-fatal QMI_ERR_MALFORMED_MSG_V01 error > > > message in ath10k_qmi_host_cap_send_sync(), but we can still > > > bring up WiFi services successfully on AOSP if we ignore it. > > > > > > We suspect either the host cap is not implemented or there > > > may be firmware specific issues. Firmware version is > > > QC_IMAGE_VERSION_STRING=WLAN.HL.2.0.c3-00257-QCAHLSWMTPLZ-1 > > > > > > qcom,snoc-host-cap-8bit-quirk didn't help. If I use this > > > quirk, then the host capability request does get accepted, > > > but we run into fatal "msa info req rejected" error and > > > WiFi interface doesn't come up. > > > > > > Attempts are being made to debug the failure reasons but no > > > luck so far. Hence this device specific workaround instead > > > of checking for QMI_ERR_MALFORMED_MSG_V01 error message. > > > Tried ath10k/WCN3990/hw1.0/wlanmdsp.mbn from the upstream > > > linux-firmware project but it didn't help and neither did > > > building board-2.bin file from stock bdwlan* files. > > > > > > This workaround will be removed once we have a viable fix. > > > Thanks to postmarketOS guys for catching this. > > > > > > Signed-off-by: Amit Pundir > > > > Bjorn, is this ok to take? > > > > As I wrote in the answer to Amit I think we should introduce a generic > quirk to skip host_cap instead. > > So if you pick this up (which is an ok short term workaround) I think we > should revert it once we have a generic mechanism. Hi Bjorn, just sent out a generic skip quirk for review. Regards, Amit Pundir > > Regards, > Bjorn > > > > --- a/drivers/net/wireless/ath/ath10k/qmi.c > > > +++ b/drivers/net/wireless/ath/ath10k/qmi.c > > > @@ -651,7 +651,8 @@ static int ath10k_qmi_host_cap_send_sync(struct ath10k_qmi *qmi) > > > > > > /* older FW didn't support this request, which is not fatal */ > > > if (resp.resp.result != QMI_RESULT_SUCCESS_V01 && > > > - resp.resp.error != QMI_ERR_NOT_SUPPORTED_V01) { > > > + resp.resp.error != QMI_ERR_NOT_SUPPORTED_V01 && > > > + !of_machine_is_compatible("xiaomi,beryllium")) { /* Xiaomi Poco F1 workaround */ > > > ath10k_err(ar, "host capability request rejected: %d\n", resp.resp.error); > > > > ath10k-check complained about a too long line, so in the pending branch > > I moved the comment before the if statement. > > > > -- > > https://patchwork.kernel.org/project/linux-wireless/list/ > > > > https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches