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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 588F0C433F5 for ; Wed, 4 May 2022 04:02:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235390AbiEDEGT (ORCPT ); Wed, 4 May 2022 00:06:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59696 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229379AbiEDEGR (ORCPT ); Wed, 4 May 2022 00:06:17 -0400 Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8998D1A393; Tue, 3 May 2022 21:02:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1651636962; x=1683172962; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=OyN5mceNj+AWcDecdxPU2pdvxMVgMY1EeS2aRZyWFTo=; b=jwgqUN4KVo6PnYUzz0eelkMCJMUin3uoTiJ4+G6Ghwn7Itgrmin44NXz rN39WdD89R8QOsqcB59G8XsMhPcT3Irg5sF+VIvctFYHaYOeEb+3alBbq at9P0aUhaR95JLyu33LiIPmKVM8pBBUrnMReAxzEq65y4WpZQB3TmaI+7 aaNS5zz+OIMovmj2PUyysee2a6NQxEF1efN+DnMwz+eAxkhXBpceruSwo YyacOLGBqKNVc8qM9ucHBwiikwA9BWaj61fkeAb912c1t7s/bl0GHy91s 2n7VQoKLzYK43VN2VqfuG1YMMVfChDajQ0ZmkAFFDQL3AUaUJnbCte5Qu A==; X-IronPort-AV: E=McAfee;i="6400,9594,10336"; a="255118862" X-IronPort-AV: E=Sophos;i="5.91,196,1647327600"; d="scan'208";a="255118862" Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 May 2022 21:02:41 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.91,196,1647327600"; d="scan'208";a="734215663" Received: from lkp-server01.sh.intel.com (HELO 5056e131ad90) ([10.239.97.150]) by orsmga005.jf.intel.com with ESMTP; 03 May 2022 21:02:38 -0700 Received: from kbuild by 5056e131ad90 with local (Exim 4.95) (envelope-from ) id 1nm6Dk-000B32-Md; Wed, 04 May 2022 04:02:36 +0000 Date: Wed, 4 May 2022 12:01:56 +0800 From: kernel test robot To: Serge Semin , Jingoo Han , Gustavo Pimentel , Bjorn Helgaas , Lorenzo Pieralisi , Rob Herring , Krzysztof =?utf-8?Q?Wilczy=C5=84ski?= , Kishon Vijay Abraham I Cc: llvm@lists.linux.dev, kbuild-all@lists.01.org, Serge Semin , Alexey Malahov , Pavel Parkhomenko , Frank Li , Manivannan Sadhasivam , linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 03/13] PCI: dwc: Add unroll iATU space support to the regions disable method Message-ID: <202205041128.dPzBiZsY-lkp@intel.com> References: <20220503212300.30105-4-Sergey.Semin@baikalelectronics.ru> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220503212300.30105-4-Sergey.Semin@baikalelectronics.ru> Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org Hi Serge, I love your patch! Perhaps something to improve: [auto build test WARNING on helgaas-pci/next] [also build test WARNING on v5.18-rc5 next-20220503] [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] url: https://github.com/intel-lab-lkp/linux/commits/Serge-Semin/PCI-dwc-Various-fixes-and-cleanups/20220504-052648 base: https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git next config: riscv-randconfig-r003-20220501 (https://download.01.org/0day-ci/archive/20220504/202205041128.dPzBiZsY-lkp@intel.com/config) compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project 363b3a645a1e30011cc8da624f13dac5fd915628) 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 riscv cross compiling tool for clang build # apt-get install binutils-riscv64-linux-gnu # https://github.com/intel-lab-lkp/linux/commit/b7ab9c3904c4948a2bdb0ed9bf5ca5e38c9ac52c git remote add linux-review https://github.com/intel-lab-lkp/linux git fetch --no-tags linux-review Serge-Semin/PCI-dwc-Various-fixes-and-cleanups/20220504-052648 git checkout b7ab9c3904c4948a2bdb0ed9bf5ca5e38c9ac52c # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=riscv SHELL=/bin/bash drivers/pci/controller/dwc/ If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All warnings (new ones prefixed by >>): In file included from drivers/pci/controller/dwc/pcie-designware.c:16: In file included from drivers/pci/controller/dwc/../../pci.h:5: In file included from include/linux/pci.h:38: In file included from include/linux/interrupt.h:11: In file included from include/linux/hardirq.h:11: In file included from ./arch/riscv/include/generated/asm/hardirq.h:1: In file included from include/asm-generic/hardirq.h:17: In file included from include/linux/irq.h:20: In file included from include/linux/io.h:13: In file included from arch/riscv/include/asm/io.h:136: include/asm-generic/io.h:464:31: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] val = __raw_readb(PCI_IOBASE + addr); ~~~~~~~~~~ ^ include/asm-generic/io.h:477:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] val = __le16_to_cpu((__le16 __force)__raw_readw(PCI_IOBASE + addr)); ~~~~~~~~~~ ^ include/uapi/linux/byteorder/little_endian.h:37:51: note: expanded from macro '__le16_to_cpu' #define __le16_to_cpu(x) ((__force __u16)(__le16)(x)) ^ In file included from drivers/pci/controller/dwc/pcie-designware.c:16: In file included from drivers/pci/controller/dwc/../../pci.h:5: In file included from include/linux/pci.h:38: In file included from include/linux/interrupt.h:11: In file included from include/linux/hardirq.h:11: In file included from ./arch/riscv/include/generated/asm/hardirq.h:1: In file included from include/asm-generic/hardirq.h:17: In file included from include/linux/irq.h:20: In file included from include/linux/io.h:13: In file included from arch/riscv/include/asm/io.h:136: include/asm-generic/io.h:490:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] val = __le32_to_cpu((__le32 __force)__raw_readl(PCI_IOBASE + addr)); ~~~~~~~~~~ ^ include/uapi/linux/byteorder/little_endian.h:35:51: note: expanded from macro '__le32_to_cpu' #define __le32_to_cpu(x) ((__force __u32)(__le32)(x)) ^ In file included from drivers/pci/controller/dwc/pcie-designware.c:16: In file included from drivers/pci/controller/dwc/../../pci.h:5: In file included from include/linux/pci.h:38: In file included from include/linux/interrupt.h:11: In file included from include/linux/hardirq.h:11: In file included from ./arch/riscv/include/generated/asm/hardirq.h:1: In file included from include/asm-generic/hardirq.h:17: In file included from include/linux/irq.h:20: In file included from include/linux/io.h:13: In file included from arch/riscv/include/asm/io.h:136: include/asm-generic/io.h:501:33: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] __raw_writeb(value, PCI_IOBASE + addr); ~~~~~~~~~~ ^ include/asm-generic/io.h:511:59: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] __raw_writew((u16 __force)cpu_to_le16(value), PCI_IOBASE + addr); ~~~~~~~~~~ ^ include/asm-generic/io.h:521:59: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] __raw_writel((u32 __force)cpu_to_le32(value), PCI_IOBASE + addr); ~~~~~~~~~~ ^ include/asm-generic/io.h:1024:55: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] return (port > MMIO_UPPER_LIMIT) ? NULL : PCI_IOBASE + port; ~~~~~~~~~~ ^ >> drivers/pci/controller/dwc/pcie-designware.c:508:14: warning: result of comparison of constant 2147483648 with expression of type 'int' is always false [-Wtautological-constant-out-of-range-compare] if (region == PCIE_ATU_REGION_INBOUND) { ~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~ error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations error: A dwo section may not contain relocations fatal error: too many errors emitted, stopping now [-ferror-limit=] 8 warnings and 20 errors generated. vim +/int +508 drivers/pci/controller/dwc/pcie-designware.c 490 491 void dw_pcie_disable_atu(struct dw_pcie *pci, int index, 492 enum dw_pcie_region_type type) 493 { 494 int region; 495 496 switch (type) { 497 case DW_PCIE_REGION_INBOUND: 498 region = PCIE_ATU_REGION_INBOUND; 499 break; 500 case DW_PCIE_REGION_OUTBOUND: 501 region = PCIE_ATU_REGION_OUTBOUND; 502 break; 503 default: 504 return; 505 } 506 507 if (pci->iatu_unroll_enabled) { > 508 if (region == PCIE_ATU_REGION_INBOUND) { 509 dw_pcie_writel_ib_unroll(pci, index, PCIE_ATU_UNR_REGION_CTRL2, 510 ~(u32)PCIE_ATU_ENABLE); 511 } else { 512 dw_pcie_writel_ob_unroll(pci, index, PCIE_ATU_UNR_REGION_CTRL2, 513 ~(u32)PCIE_ATU_ENABLE); 514 } 515 } else { 516 dw_pcie_writel_dbi(pci, PCIE_ATU_VIEWPORT, region | index); 517 dw_pcie_writel_dbi(pci, PCIE_ATU_CR2, ~(u32)PCIE_ATU_ENABLE); 518 } 519 } 520 -- 0-DAY CI Kernel Test Service https://01.org/lkp