From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 66AA9C433DB for ; Tue, 30 Mar 2021 09:55:35 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id F253B619A6 for ; Tue, 30 Mar 2021 09:55:34 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org F253B619A6 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 72B6E6B0071; Tue, 30 Mar 2021 05:55:34 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 6DB506B007D; Tue, 30 Mar 2021 05:55:34 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 5C9B56B0080; Tue, 30 Mar 2021 05:55:34 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0068.hostedemail.com [216.40.44.68]) by kanga.kvack.org (Postfix) with ESMTP id 44C2E6B0071 for ; Tue, 30 Mar 2021 05:55:34 -0400 (EDT) Received: from smtpin19.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 06DA512E7 for ; Tue, 30 Mar 2021 09:55:34 +0000 (UTC) X-FDA: 77976083388.19.4E05929 Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by imf17.hostedemail.com (Postfix) with ESMTP id 535A040002C2 for ; Tue, 30 Mar 2021 09:55:31 +0000 (UTC) IronPort-SDR: xn8jm1O5W9f6M/rnJpXcCnbqHzCiDzkVW9VqN5RbjZjRPUjaPKP+lNdCrRVbZJgtxECk8720AP j/MDZuVZumfg== X-IronPort-AV: E=McAfee;i="6000,8403,9938"; a="211941585" X-IronPort-AV: E=Sophos;i="5.81,290,1610438400"; d="scan'208";a="211941585" Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 Mar 2021 02:55:31 -0700 IronPort-SDR: CtTw2AIyDrwrtRYVqWj9XC+Qf3R//G1r4d8HruKFZxtIpSJVm+Xkg/jZSN+xla31GLhtKpZaaB LCcyI11PSjBQ== X-IronPort-AV: E=Sophos;i="5.81,290,1610438400"; d="scan'208";a="393552488" Received: from smile.fi.intel.com (HELO smile) ([10.237.68.40]) by orsmga002-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 Mar 2021 02:55:29 -0700 Received: from andy by smile with local (Exim 4.94) (envelope-from ) id 1lRB5q-00HII7-RL; Tue, 30 Mar 2021 12:55:26 +0300 Date: Tue, 30 Mar 2021 12:55:26 +0300 From: Andy Shevchenko To: Bartosz Golaszewski Cc: kernel test robot , kbuild-all@lists.01.org, clang-built-linux@googlegroups.com, Linux Memory Management List , Linus Walleij Subject: Re: [linux-next:master 7313/8469] drivers/gpio/gpio-sim.c:388:34: warning: unused variable 'gpio_sim_of_match' Message-ID: References: <202103301259.dhlOOcXV-lkp@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-Stat-Signature: ndq8hpqkhd3s3ngbaou5iqnu9tnbxg4r X-Rspamd-Server: rspam04 X-Rspamd-Queue-Id: 535A040002C2 Received-SPF: none (linux.intel.com>: No applicable sender policy available) receiver=imf17; identity=mailfrom; envelope-from=""; helo=mga01.intel.com; client-ip=192.55.52.88 X-HE-DKIM-Result: none/none X-HE-Tag: 1617098131-422920 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Tue, Mar 30, 2021 at 11:26:17AM +0200, Bartosz Golaszewski wrote: > On Tue, Mar 30, 2021 at 11:11 AM Andy Shevchenko > wrote: > > On Tue, Mar 30, 2021 at 12:15:04PM +0800, kernel test robot wrote: > > > tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master > > > head: 9d49ed9ca93b8c564033c1d6808017bc9052b5db > > > commit: 3f0279eb9e3767f37939358a42054c226503233a [7313/8469] gpio: sim: new testing module > > > config: arm-randconfig-r001-20210330 (attached as .config) > > > compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 482283042f795ecc27838a3b2f76b5494991401c) > > > reproduce (this is a W=1 build): > > > wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross > > > chmod +x ~/bin/make.cross > > > # install arm cross compiling tool for clang build > > > # apt-get install binutils-arm-linux-gnueabi > > > # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=3f0279eb9e3767f37939358a42054c226503233a > > > git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git > > > git fetch --no-tags linux-next master > > > git checkout 3f0279eb9e3767f37939358a42054c226503233a > > > # save the attached .config to linux build tree > > > COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm > > > > > > If you fix the issue, kindly add following tag as appropriate > > > Reported-by: kernel test robot > > > > > > All warnings (new ones prefixed by >>): > > > > > > >> drivers/gpio/gpio-sim.c:388:34: warning: unused variable 'gpio_sim_of_match' [-Wunused-const-variable] > > > static const struct of_device_id gpio_sim_of_match[] = { > > > ^ > > > 1 warning generated. > > > > of_match_ptr() should be removed AFAIU the case. > > > > I'm not using it though... Other drivers do the same thing as I did > here. Can this be a false positive? Ah, you simply missed to add it to the platform driver structure. No, it's not false positive. > > > vim +/gpio_sim_of_match +388 drivers/gpio/gpio-sim.c > > > > > > 387 > > > > 388 static const struct of_device_id gpio_sim_of_match[] = { > > > 389 { .compatible = "gpio-simulator" }, > > > 390 { } > > > 391 }; > > > 392 MODULE_DEVICE_TABLE(of, gpio_sim_of_match); -- With Best Regards, Andy Shevchenko