From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 42FA67B for ; Sat, 11 Mar 2023 16:15:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1678551359; x=1710087359; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=aHPHU16CD9i0eyQTn/doZEmUXEpScZhw8p2k0kirEyo=; b=VrF4YRqhRXrxgnUSeIoZ2Wd7UlgITknlFAXpwyK76C5UMm7OiUA3FmuR 4/t0jq3syLccoFeUW5r8lOSyMWimLNa8x+9+cIpW11qS8F3heluwImMW5 gJtlrd2IF/Nj7VKApMpnlkLbfg98bFpX5a4vXygzQtjVWl34VWDPF+ONl 7UesdXl3VXosT3nGhI671U3iig9AUT5qfW+UaNoZWd3W7RhSQY79oDZ39 jBrKFK7ZRt8Q520pE+CkJdhIej/F1VsObEcIUm37w+ywtpQf4q7ZiPoKy kv5Zuznu5LyE5+kCZbNrmiVRQhukYebPMiYvXlu/RHjnb2t9ZlUDKsBs5 A==; X-IronPort-AV: E=McAfee;i="6500,9779,10646"; a="423183216" X-IronPort-AV: E=Sophos;i="5.98,252,1673942400"; d="scan'208";a="423183216" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Mar 2023 08:15:58 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10646"; a="628146557" X-IronPort-AV: E=Sophos;i="5.98,252,1673942400"; d="scan'208";a="628146557" Received: from lkp-server01.sh.intel.com (HELO b613635ddfff) ([10.239.97.150]) by orsmga003.jf.intel.com with ESMTP; 11 Mar 2023 08:15:56 -0800 Received: from kbuild by b613635ddfff with local (Exim 4.96) (envelope-from ) id 1pb1sx-0004gP-38; Sat, 11 Mar 2023 16:15:55 +0000 Date: Sun, 12 Mar 2023 00:15:44 +0800 From: kernel test robot To: Rob Herring , Michal Simek Cc: oe-kbuild-all@lists.linux.dev, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] soc: xilinx: Use of_property_present() for testing DT property presence Message-ID: <202303120017.BIw01Y21-lkp@intel.com> References: <20230310144725.1545315-1-robh@kernel.org> Precedence: bulk X-Mailing-List: oe-kbuild-all@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230310144725.1545315-1-robh@kernel.org> Hi Rob, I love your patch! Yet something to improve: [auto build test ERROR on xilinx-xlnx/master] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Rob-Herring/soc-xilinx-Use-of_property_present-for-testing-DT-property-presence/20230310-225437 base: https://github.com/Xilinx/linux-xlnx master patch link: https://lore.kernel.org/r/20230310144725.1545315-1-robh%40kernel.org patch subject: [PATCH] soc: xilinx: Use of_property_present() for testing DT property presence config: arm64-allyesconfig (https://download.01.org/0day-ci/archive/20230312/202303120017.BIw01Y21-lkp@intel.com/config) compiler: aarch64-linux-gcc (GCC) 12.1.0 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 # https://github.com/intel-lab-lkp/linux/commit/7d21b118deba11d338baf0365e962a8889f3ac68 git remote add linux-review https://github.com/intel-lab-lkp/linux git fetch --no-tags linux-review Rob-Herring/soc-xilinx-Use-of_property_present-for-testing-DT-property-presence/20230310-225437 git checkout 7d21b118deba11d338baf0365e962a8889f3ac68 # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm64 olddefconfig COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm64 SHELL=/bin/bash drivers/soc/ If you fix the issue, kindly add following tag where applicable | Reported-by: kernel test robot | Link: https://lore.kernel.org/oe-kbuild-all/202303120017.BIw01Y21-lkp@intel.com/ All errors (new ones prefixed by >>): drivers/soc/xilinx/zynqmp_power.c: In function 'zynqmp_pm_probe': >> drivers/soc/xilinx/zynqmp_power.c:221:20: error: implicit declaration of function 'of_property_present'; did you mean 'fwnode_property_present'? [-Werror=implicit-function-declaration] 221 | } else if (of_property_present(pdev->dev.of_node, "mboxes")) { | ^~~~~~~~~~~~~~~~~~~ | fwnode_property_present cc1: some warnings being treated as errors vim +221 drivers/soc/xilinx/zynqmp_power.c 183 184 static int zynqmp_pm_probe(struct platform_device *pdev) 185 { 186 int ret, irq; 187 u32 pm_api_version; 188 struct mbox_client *client; 189 190 zynqmp_pm_get_api_version(&pm_api_version); 191 192 /* Check PM API version number */ 193 if (pm_api_version < ZYNQMP_PM_VERSION) 194 return -ENODEV; 195 196 /* 197 * First try to use Xilinx Event Manager by registering suspend_event_callback 198 * for suspend/shutdown event. 199 * If xlnx_register_event() returns -EACCES (Xilinx Event Manager 200 * is not available to use) or -ENODEV(Xilinx Event Manager not compiled), 201 * then use ipi-mailbox or interrupt method. 202 */ 203 ret = xlnx_register_event(PM_INIT_SUSPEND_CB, 0, 0, false, 204 suspend_event_callback, NULL); 205 if (!ret) { 206 zynqmp_pm_init_suspend_work = devm_kzalloc(&pdev->dev, 207 sizeof(struct zynqmp_pm_work_struct), 208 GFP_KERNEL); 209 if (!zynqmp_pm_init_suspend_work) { 210 xlnx_unregister_event(PM_INIT_SUSPEND_CB, 0, 0, 211 suspend_event_callback, NULL); 212 return -ENOMEM; 213 } 214 event_registered = true; 215 216 INIT_WORK(&zynqmp_pm_init_suspend_work->callback_work, 217 zynqmp_pm_init_suspend_work_fn); 218 } else if (ret != -EACCES && ret != -ENODEV) { 219 dev_err(&pdev->dev, "Failed to Register with Xilinx Event manager %d\n", ret); 220 return ret; > 221 } else if (of_property_present(pdev->dev.of_node, "mboxes")) { 222 zynqmp_pm_init_suspend_work = 223 devm_kzalloc(&pdev->dev, 224 sizeof(struct zynqmp_pm_work_struct), 225 GFP_KERNEL); 226 if (!zynqmp_pm_init_suspend_work) 227 return -ENOMEM; 228 229 INIT_WORK(&zynqmp_pm_init_suspend_work->callback_work, 230 zynqmp_pm_init_suspend_work_fn); 231 client = devm_kzalloc(&pdev->dev, sizeof(*client), GFP_KERNEL); 232 if (!client) 233 return -ENOMEM; 234 235 client->dev = &pdev->dev; 236 client->rx_callback = ipi_receive_callback; 237 238 rx_chan = mbox_request_channel_byname(client, "rx"); 239 if (IS_ERR(rx_chan)) { 240 dev_err(&pdev->dev, "Failed to request rx channel\n"); 241 return PTR_ERR(rx_chan); 242 } 243 } else if (of_property_present(pdev->dev.of_node, "interrupts")) { 244 irq = platform_get_irq(pdev, 0); 245 if (irq <= 0) 246 return -ENXIO; 247 248 ret = devm_request_threaded_irq(&pdev->dev, irq, NULL, 249 zynqmp_pm_isr, 250 IRQF_NO_SUSPEND | IRQF_ONESHOT, 251 dev_name(&pdev->dev), 252 &pdev->dev); 253 if (ret) { 254 dev_err(&pdev->dev, "devm_request_threaded_irq '%d' failed with %d\n", 255 irq, ret); 256 return ret; 257 } 258 } else { 259 dev_err(&pdev->dev, "Required property not found in DT node\n"); 260 return -ENOENT; 261 } 262 263 ret = sysfs_create_file(&pdev->dev.kobj, &dev_attr_suspend_mode.attr); 264 if (ret) { 265 if (event_registered) { 266 xlnx_unregister_event(PM_INIT_SUSPEND_CB, 0, 0, suspend_event_callback, 267 NULL); 268 event_registered = false; 269 } 270 dev_err(&pdev->dev, "unable to create sysfs interface\n"); 271 return ret; 272 } 273 274 return 0; 275 } 276 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests 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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 8A1E4C61DA4 for ; Sat, 11 Mar 2023 16:17:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=j+IewXIBiEz7vScTJm+XKjutMSiWIjvZdQJnM6VxRz8=; b=e+AFiRVjGNq77V LffUi9GMYST3r3JoD/PlD1KXUS6bZ7Kzb54uGjbBOL923FpuK3eKSTkqL4yfFAYoMk0gMfvLN0mbV dM/LUfSXb8S7kWfBpoJwRNoihg+SHBhMSWC2eIwlRiUe5HqsJaFkXCrkh4+gUfPpDxX1faL91SL1e 6tBww3Px0ENR2JJHGVVgV6FTE3cvUpFEPCWdGcCwgWAV0P6JT3/Uv9cPhYBzWoHWM9x5rtWcmKhiZ C6XW8kPGStN83DOs3eQEbnxSP2AWrqPW+KHRkcnguCUaNyRyok9ISdnneBZcfQ+++h8X5FNYnt4Af r767URdeKUKq3lTm1mSg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pb1t9-000s1B-TU; Sat, 11 Mar 2023 16:16:08 +0000 Received: from mga05.intel.com ([192.55.52.43]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pb1t4-000rzD-OV for linux-arm-kernel@lists.infradead.org; Sat, 11 Mar 2023 16:16:06 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1678551362; x=1710087362; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=aHPHU16CD9i0eyQTn/doZEmUXEpScZhw8p2k0kirEyo=; b=ZcclfeG/qFBFl94sWxV61J6K94HrxFnX5j2xurA6/uhVbY1pEXIEhnaE N7ZhUIfasqotkumixefWx0iCARl1IP32FA73aBiGI9J3QqZcvoPa1mI5c ZZHGy6XxcitStnvBgzr89XX94hv8kEzQQl5BUYh/d6K5f+XX9wiuEpVPS x5v81vfWjxql2OnXhNCvSP2gDrHnm0nB629eN2MYFBGGc3GNDdrpNmaAw FRG/kk8lr0oX6LQ9KwRrDQkDBItQLfYMjXIE3v37JwJ+EElEGXOsQmxpN 1Mga1Ec5eAGRuunM49oE8B/JthNVPuwpHTPQYeE/352fnqbEIxMPE0EN4 w==; X-IronPort-AV: E=McAfee;i="6500,9779,10646"; a="423183215" X-IronPort-AV: E=Sophos;i="5.98,252,1673942400"; d="scan'208";a="423183215" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Mar 2023 08:15:58 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10646"; a="628146557" X-IronPort-AV: E=Sophos;i="5.98,252,1673942400"; d="scan'208";a="628146557" Received: from lkp-server01.sh.intel.com (HELO b613635ddfff) ([10.239.97.150]) by orsmga003.jf.intel.com with ESMTP; 11 Mar 2023 08:15:56 -0800 Received: from kbuild by b613635ddfff with local (Exim 4.96) (envelope-from ) id 1pb1sx-0004gP-38; Sat, 11 Mar 2023 16:15:55 +0000 Date: Sun, 12 Mar 2023 00:15:44 +0800 From: kernel test robot To: Rob Herring , Michal Simek Cc: oe-kbuild-all@lists.linux.dev, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] soc: xilinx: Use of_property_present() for testing DT property presence Message-ID: <202303120017.BIw01Y21-lkp@intel.com> References: <20230310144725.1545315-1-robh@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20230310144725.1545315-1-robh@kernel.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230311_081602_866489_579525FA X-CRM114-Status: GOOD ( 16.57 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Rob, I love your patch! Yet something to improve: [auto build test ERROR on xilinx-xlnx/master] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Rob-Herring/soc-xilinx-Use-of_property_present-for-testing-DT-property-presence/20230310-225437 base: https://github.com/Xilinx/linux-xlnx master patch link: https://lore.kernel.org/r/20230310144725.1545315-1-robh%40kernel.org patch subject: [PATCH] soc: xilinx: Use of_property_present() for testing DT property presence config: arm64-allyesconfig (https://download.01.org/0day-ci/archive/20230312/202303120017.BIw01Y21-lkp@intel.com/config) compiler: aarch64-linux-gcc (GCC) 12.1.0 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 # https://github.com/intel-lab-lkp/linux/commit/7d21b118deba11d338baf0365e962a8889f3ac68 git remote add linux-review https://github.com/intel-lab-lkp/linux git fetch --no-tags linux-review Rob-Herring/soc-xilinx-Use-of_property_present-for-testing-DT-property-presence/20230310-225437 git checkout 7d21b118deba11d338baf0365e962a8889f3ac68 # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm64 olddefconfig COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm64 SHELL=/bin/bash drivers/soc/ If you fix the issue, kindly add following tag where applicable | Reported-by: kernel test robot | Link: https://lore.kernel.org/oe-kbuild-all/202303120017.BIw01Y21-lkp@intel.com/ All errors (new ones prefixed by >>): drivers/soc/xilinx/zynqmp_power.c: In function 'zynqmp_pm_probe': >> drivers/soc/xilinx/zynqmp_power.c:221:20: error: implicit declaration of function 'of_property_present'; did you mean 'fwnode_property_present'? [-Werror=implicit-function-declaration] 221 | } else if (of_property_present(pdev->dev.of_node, "mboxes")) { | ^~~~~~~~~~~~~~~~~~~ | fwnode_property_present cc1: some warnings being treated as errors vim +221 drivers/soc/xilinx/zynqmp_power.c 183 184 static int zynqmp_pm_probe(struct platform_device *pdev) 185 { 186 int ret, irq; 187 u32 pm_api_version; 188 struct mbox_client *client; 189 190 zynqmp_pm_get_api_version(&pm_api_version); 191 192 /* Check PM API version number */ 193 if (pm_api_version < ZYNQMP_PM_VERSION) 194 return -ENODEV; 195 196 /* 197 * First try to use Xilinx Event Manager by registering suspend_event_callback 198 * for suspend/shutdown event. 199 * If xlnx_register_event() returns -EACCES (Xilinx Event Manager 200 * is not available to use) or -ENODEV(Xilinx Event Manager not compiled), 201 * then use ipi-mailbox or interrupt method. 202 */ 203 ret = xlnx_register_event(PM_INIT_SUSPEND_CB, 0, 0, false, 204 suspend_event_callback, NULL); 205 if (!ret) { 206 zynqmp_pm_init_suspend_work = devm_kzalloc(&pdev->dev, 207 sizeof(struct zynqmp_pm_work_struct), 208 GFP_KERNEL); 209 if (!zynqmp_pm_init_suspend_work) { 210 xlnx_unregister_event(PM_INIT_SUSPEND_CB, 0, 0, 211 suspend_event_callback, NULL); 212 return -ENOMEM; 213 } 214 event_registered = true; 215 216 INIT_WORK(&zynqmp_pm_init_suspend_work->callback_work, 217 zynqmp_pm_init_suspend_work_fn); 218 } else if (ret != -EACCES && ret != -ENODEV) { 219 dev_err(&pdev->dev, "Failed to Register with Xilinx Event manager %d\n", ret); 220 return ret; > 221 } else if (of_property_present(pdev->dev.of_node, "mboxes")) { 222 zynqmp_pm_init_suspend_work = 223 devm_kzalloc(&pdev->dev, 224 sizeof(struct zynqmp_pm_work_struct), 225 GFP_KERNEL); 226 if (!zynqmp_pm_init_suspend_work) 227 return -ENOMEM; 228 229 INIT_WORK(&zynqmp_pm_init_suspend_work->callback_work, 230 zynqmp_pm_init_suspend_work_fn); 231 client = devm_kzalloc(&pdev->dev, sizeof(*client), GFP_KERNEL); 232 if (!client) 233 return -ENOMEM; 234 235 client->dev = &pdev->dev; 236 client->rx_callback = ipi_receive_callback; 237 238 rx_chan = mbox_request_channel_byname(client, "rx"); 239 if (IS_ERR(rx_chan)) { 240 dev_err(&pdev->dev, "Failed to request rx channel\n"); 241 return PTR_ERR(rx_chan); 242 } 243 } else if (of_property_present(pdev->dev.of_node, "interrupts")) { 244 irq = platform_get_irq(pdev, 0); 245 if (irq <= 0) 246 return -ENXIO; 247 248 ret = devm_request_threaded_irq(&pdev->dev, irq, NULL, 249 zynqmp_pm_isr, 250 IRQF_NO_SUSPEND | IRQF_ONESHOT, 251 dev_name(&pdev->dev), 252 &pdev->dev); 253 if (ret) { 254 dev_err(&pdev->dev, "devm_request_threaded_irq '%d' failed with %d\n", 255 irq, ret); 256 return ret; 257 } 258 } else { 259 dev_err(&pdev->dev, "Required property not found in DT node\n"); 260 return -ENOENT; 261 } 262 263 ret = sysfs_create_file(&pdev->dev.kobj, &dev_attr_suspend_mode.attr); 264 if (ret) { 265 if (event_registered) { 266 xlnx_unregister_event(PM_INIT_SUSPEND_CB, 0, 0, suspend_event_callback, 267 NULL); 268 event_registered = false; 269 } 270 dev_err(&pdev->dev, "unable to create sysfs interface\n"); 271 return ret; 272 } 273 274 return 0; 275 } 276 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel