Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp3494195pxx; Mon, 2 Nov 2020 10:18:52 -0800 (PST) X-Google-Smtp-Source: ABdhPJxP13cVx14QT8GJJ4Ao39IWXmxcS+I2IJ02lyWecFllyaR6qSLsmlhRQGJr8bI05l6vnVy3 X-Received: by 2002:a17:906:35da:: with SMTP id p26mr5023261ejb.256.1604341132516; Mon, 02 Nov 2020 10:18:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604341132; cv=none; d=google.com; s=arc-20160816; b=vI5UV34nqsqSdWSnbyjKXev2zx3Anim0JJ89KNQNggUlzAdMgX+HrejHrzCd5qXqye 3ZiOxqCwEymfMYJi53pnc6+w3Kj9Bq+eUDWs29Ed/dCfIGGwxbQiifGNB0a9FYJllngL fNSgOt41GTF+vQhB3lDmP1sd+9GZd0nKV1riPG6bRV5G4Gpr8bebJ1/fzD1zIaYlIxB3 ST6e7fD81luRAIIgcs94fJVsuovt/lzY0vCjAUfafRr9CZpcD7IKKJglMZFSy6WpHvHk KhfH4oujPA63IqqOk3TUVcIq6oo8JcAOJbyksJUEtkMMJGgbcbdqeK20DNciu6JuHFWu 1zBA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:date:message-id:user-agent:cc:to:references :in-reply-to:from:subject:content-transfer-encoding:mime-version :dmarc-filter:sender:dkim-signature; bh=nS7fTYel1RkJvIVetfpxWCWaUmGRrDbjg87RLUX+kic=; b=kaOUOx+abyiFdRsKJAKBSzc8klI+fYzri6iLRUmM181A+15/+Q5tcmRiuclbZ9WGUJ bI1HyheI7ZCr1D9exYpuZEDEv3QmazuBz1E6Vm7oP9lEMCVPbVn4srSpAGEbKQ42+PVv J+Odrraz5587/TCQ/IcqOvVB+7ot0VGgSIcv+hfUESUqQ6T4a9o/HlPfVi4kLryqfP6S dg268MJhs60JgvMnoFhP1fwEdZh+cLqV+H2CwqOWfFS+JYhnd1UQ684nWUE/zL7LTaV0 ISmoEfwiaZLwtOj9jb5tcoY2nCmGgk/+wmooxi8+PLjeidrxV6ZoTuXB/sTW3YU7Yso7 P04Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mg.codeaurora.org header.s=smtp header.b=p+Yc6Whu; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w10si3688934ejn.670.2020.11.02.10.18.27; Mon, 02 Nov 2020 10:18:52 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless-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=@mg.codeaurora.org header.s=smtp header.b=p+Yc6Whu; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726342AbgKBSRa (ORCPT + 99 others); Mon, 2 Nov 2020 13:17:30 -0500 Received: from z5.mailgun.us ([104.130.96.5]:61646 "EHLO z5.mailgun.us" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726055AbgKBSRW (ORCPT ); Mon, 2 Nov 2020 13:17:22 -0500 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1604341042; h=Date: Message-Id: Cc: To: References: In-Reply-To: From: Subject: Content-Transfer-Encoding: MIME-Version: Content-Type: Sender; bh=nS7fTYel1RkJvIVetfpxWCWaUmGRrDbjg87RLUX+kic=; b=p+Yc6WhuzgUdrHe/1JDdZE3pqG9UP2FKRefKajcJ0v8yPOXcsWAiWprRTjfUdKTJnZJSE/zm zwnz51WHkDFrns5XJUgD+1kPKmXJddvfj9LPV/AT1Go7jtLplW0mgQjXNYW0vNl5mlIFoz8I dXq/en0cA/pohdUmDqbs1g2ZnWk= X-Mailgun-Sending-Ip: 104.130.96.5 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-n04.prod.us-west-2.postgun.com with SMTP id 5fa04d15978460d05b8ef3c6 (version=TLS1.2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256); Mon, 02 Nov 2020 18:16:53 GMT Sender: kvalo=codeaurora.org@mg.codeaurora.org Received: by smtp.codeaurora.org (Postfix, from userid 1001) id 8A854C433F0; Mon, 2 Nov 2020 18:16:53 +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=-1.0 required=2.0 tests=ALL_TRUSTED,BAYES_00, MISSING_DATE,MISSING_MID,SPF_FAIL 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 EFC12C433C6; Mon, 2 Nov 2020 18:16:49 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org EFC12C433C6 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=fail smtp.mailfrom=kvalo@codeaurora.org Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: Re: rtw88: fix fw_fifo_addr check From: Kalle Valo In-Reply-To: <20201011155438.15892-1-trix@redhat.com> References: <20201011155438.15892-1-trix@redhat.com> To: trix@redhat.com Cc: yhchuang@realtek.com, davem@davemloft.net, kuba@kernel.org, natechancellor@gmail.com, ndesaulniers@google.com, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, clang-built-linux@googlegroups.com, Tom Rix User-Agent: pwcli/0.1.0-git (https://github.com/kvalo/pwcli/) Python/3.5.2 Message-Id: <20201102181653.8A854C433F0@smtp.codeaurora.org> Date: Mon, 2 Nov 2020 18:16:53 +0000 (UTC) Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org trix@redhat.com wrote: > From: Tom Rix > > The clang build reports this warning > > fw.c:1485:21: warning: address of array 'rtwdev->chip->fw_fifo_addr' > will always evaluate to 'true' > if (!rtwdev->chip->fw_fifo_addr) { > > fw_fifo_addr is an array in rtw_chip_info so it is always > nonzero. A better check is if the first element of the array is > nonzero. In the cases where fw_fifo_addr is initialized by rtw88b > and rtw88c, the first array element is 0x780. > > Fixes: 0fbc2f0f34cc ("rtw88: add dump firmware fifo support") > Signed-off-by: Tom Rix > Reviewed-by: Nathan Chancellor > Acked-by: Tzu-En Huang Patch applied to wireless-drivers.git, thanks. ddcd945e556e rtw88: fix fw_fifo_addr check -- https://patchwork.kernel.org/project/linux-wireless/patch/20201011155438.15892-1-trix@redhat.com/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches