From patchwork Wed Feb 9 22:13:04 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: kernel test robot X-Patchwork-Id: 12740972 X-Patchwork-Delegate: kuba@kernel.org Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2CC0EC433EF for ; Wed, 9 Feb 2022 22:13:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235103AbiBIWNN (ORCPT ); Wed, 9 Feb 2022 17:13:13 -0500 Received: from gmail-smtp-in.l.google.com ([23.128.96.19]:35284 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235088AbiBIWNM (ORCPT ); Wed, 9 Feb 2022 17:13:12 -0500 Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 92D2EC0F8699; Wed, 9 Feb 2022 14:13:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1644444795; x=1675980795; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=unrXRUdzWi5D3/HjV3kwKy4i923Vtn2+Tei9MwW5b48=; b=GaUjs0ApXHRAtTajnNYZ7baj/JMq5yN4c9NvB6LhUXREhjYTGl5CejEH Jd3sbM7Hfc28JA32Vb719DmgYty0CxbmLbjzw20Zma2UgzGIdiiIYJWpn obr0kVIh2wPmdRjYSEcccwVfIdyNuYpcgw2E9biGzhYAoY8S13Y/aXdVY 8EAMMsZ2BbC2Yo6CodDiEg6mh7Bxh401wYfagSInb1Q6I8f5Ex3vJEeR9 gyydbc8vVbQsRiAPVjg8ao5LiYaVWkdTYUx/2sJLxu6tqCDJgoXGCeWoV 6ysqPWmMhyVWa//FAW6hqREJadUR5lKYVunraJvJ323/pWKRqvLs5LrYu Q==; X-IronPort-AV: E=McAfee;i="6200,9189,10253"; a="312644542" X-IronPort-AV: E=Sophos;i="5.88,356,1635231600"; d="scan'208";a="312644542" Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Feb 2022 14:13:15 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,356,1635231600"; d="scan'208";a="568418305" Received: from lkp-server01.sh.intel.com (HELO d95dc2dabeb1) ([10.239.97.150]) by orsmga001.jf.intel.com with ESMTP; 09 Feb 2022 14:13:12 -0800 Received: from kbuild by d95dc2dabeb1 with local (Exim 4.92) (envelope-from ) id 1nHvD6-0002Kt-74; Wed, 09 Feb 2022 22:13:12 +0000 Date: Thu, 10 Feb 2022 06:13:04 +0800 From: kernel test robot To: Ansuel Smith Cc: kbuild-all@lists.01.org, Linux Memory Management List , Andrew Lunn , Vivien Didelot , Florian Fainelli , Vladimir Oltean , Jakub Kicinski , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] net: dsa: qca8k: fix noderef.cocci warnings Message-ID: <20220209221304.GA17529@d2214a582157> References: <202202100634.l8CtrpzE-lkp@intel.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <202202100634.l8CtrpzE-lkp@intel.com> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org X-Patchwork-Delegate: kuba@kernel.org From: kernel test robot drivers/net/dsa/qca8k.c:422:37-43: ERROR: application of sizeof to pointer sizeof when applied to a pointer typed expression gives the size of the pointer Generated by: scripts/coccinelle/misc/noderef.cocci Fixes: 90386223f44e ("net: dsa: qca8k: add support for larger read/write size with mgmt Ethernet") CC: Ansuel Smith Reported-by: kernel test robot Signed-off-by: kernel test robot Reviewed-by: Florian Fainelli --- tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master head: 10207e3a840b47b5eae573486a88fb6e29884f77 commit: 90386223f44e2a751d7e9e9ac8f78ea33358a891 [2955/4656] net: dsa: qca8k: add support for larger read/write size with mgmt Ethernet :::::: branch date: 16 hours ago :::::: commit date: 7 days ago qca8k.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/net/dsa/qca8k.c +++ b/drivers/net/dsa/qca8k.c @@ -419,7 +419,7 @@ qca8k_regmap_read(void *ctx, uint32_t re u16 r1, r2, page; int ret; - if (!qca8k_read_eth(priv, reg, val, sizeof(val))) + if (!qca8k_read_eth(priv, reg, val, sizeof(*val))) return 0; qca8k_split_addr(reg, &r1, &r2, &page);