Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp110069ybg; Mon, 8 Jun 2020 17:53:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw6bbL4tO88kcn323KzIUdmVpWSX/qjowcG5EmBlpQX23/a/hhU3sfhF00HAPb7ocro3Xum X-Received: by 2002:a17:906:6b8a:: with SMTP id l10mr21933935ejr.465.1591663992906; Mon, 08 Jun 2020 17:53:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591663992; cv=none; d=google.com; s=arc-20160816; b=x+5KWl4lZQJ318iQyBEaVKmeVZr/IX4UEmz0D4ns09hY1D71GmfTHjZjYxCGvWCpcy 94t7RUdEin9JySXRJQiG4F75T0sqTFSY2FwCBmpdxj3HbIY2JGnAgIyB6ODaUfgdoHna VuZ8lWpCajX0IgPh7nLFUGnMx8kLKVhekReoaEjS6RFJtxRmXjE/4IqWoraCmifUQwxm V0yvBX7JhpQN+GsnSmqw/xhlqwwVtJhcyCrp0FmgnzFDGtVcCdqZeBEyVWtxdIyfbN/O v/Ahp1OhKrq29mHgopEPfJ4II++XqxVTAqUXgMsAxGPuqM6HcipFuYHwKI+pntQYEtsQ chnA== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=cmeZXolWR6lid1Ysn7VfCTmG5sTfRURO+rvTtOO5Nqo=; b=qCyLVKecstivukrNARXGKypBLBnhvLIZwTGRr+1KdzoM1U4tKCN9VcT35pM8F5RySj FaunZZPuUp86XxIUR99byk8QjnrJ1L31TezL+1h94a3BMQlYPk04M/XVV2GZa3sPpv43 46LJh4v8zdkqIGWh+n/ICvLQrcaCLuZz3YHwrWwXi1FIVYX8HQzK1M6bSLSgekEgPaLn BT9FLlY4S5zG7ein+T7UMymnSqo83hu+f6sadUDOmPhO33g3t8rDPIQQtrw8ireIefNk Ic1semofzbPgqlVWBrpzC99hmx+zRNUAk37XQVc4ePkbjJohsq9i6P4U5Od0iipBjwIR fgAg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="vSKrxqq/"; 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e6si11075846edm.54.2020.06.08.17.52.50; Mon, 08 Jun 2020 17:53:12 -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=@kernel.org header.s=default header.b="vSKrxqq/"; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732059AbgFIAvF (ORCPT + 99 others); Mon, 8 Jun 2020 20:51:05 -0400 Received: from mail.kernel.org ([198.145.29.99]:56508 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728588AbgFHXKV (ORCPT ); Mon, 8 Jun 2020 19:10:21 -0400 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 92B29214D8; Mon, 8 Jun 2020 23:10:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1591657821; bh=CvFeTCugHHRONHTP2eRlFRtgrbQbpBoVKDgXt7fTF8s=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=vSKrxqq/jtcMevL97hTB6bCGq0S0X0UTz84n3hgMISpqJI9QK9T8dN6GEiCipIsMO dAgAaX0Rtd4vyT7R4BOJFxkH3RFpWqmdnOZJPnoyOjWne5oDZ1YjR09g/cw0NkkIVd krfl9aJZQryqEGd5JSCgSdcJfx6VE1jTP1v68uGI= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Lorenzo Bianconi , Felix Fietkau , Sasha Levin , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org Subject: [PATCH AUTOSEL 5.7 194/274] mt76: mt7615: fix mt7615_firmware_own for mt7663e Date: Mon, 8 Jun 2020 19:04:47 -0400 Message-Id: <20200608230607.3361041-194-sashal@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200608230607.3361041-1-sashal@kernel.org> References: <20200608230607.3361041-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Lorenzo Bianconi [ Upstream commit becdf0d5d7a46f5ed1f12405ffae4b04764fe27c ] Check the firmware-own configuration has been applied polling MT_CONN_HIF_ON_LPCTL register Fixes: f40ac0f3d3c0 ("mt76: mt7615: introduce mt7663e support") Signed-off-by: Lorenzo Bianconi Signed-off-by: Felix Fietkau Signed-off-by: Sasha Levin --- drivers/net/wireless/mediatek/mt76/mt7615/mcu.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c b/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c index a19fb0cb7794..0d56e0834bde 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c +++ b/drivers/net/wireless/mediatek/mt76/mt7615/mcu.c @@ -1550,9 +1550,8 @@ static int mt7615_firmware_own(struct mt7615_dev *dev) mt76_wr(dev, addr, MT_CFG_LPCR_HOST_FW_OWN); - if (is_mt7622(&dev->mt76) && - !mt76_poll_msec(dev, MT_CFG_LPCR_HOST, - MT_CFG_LPCR_HOST_FW_OWN, + if (!is_mt7615(&dev->mt76) && + !mt76_poll_msec(dev, addr, MT_CFG_LPCR_HOST_FW_OWN, MT_CFG_LPCR_HOST_FW_OWN, 3000)) { dev_err(dev->mt76.dev, "Timeout for firmware own\n"); return -EIO; -- 2.25.1