Linux-PCI Archive on lore.kernel.org
 help / color / Atom feed
From: kernel test robot <lkp@intel.com>
To: Rajat Jain <rajatja@google.com>,
	David Woodhouse <dwmw2@infradead.org>,
	Lu Baolu <baolu.lu@linux.intel.com>,
	Joerg Roedel <joro@8bytes.org>,
	Bjorn Helgaas <helgaas@kernel.org>,
	"Rafael J. Wysocki" <rjw@rjwysocki.net>,
	Len Brown <lenb@kernel.org>,
	iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org,
	linux-pci@vger.kernel.org, linux-acpi@vger.kernel.org
Cc: kbuild-all@lists.01.org, clang-built-linux@googlegroups.com
Subject: Re: [PATCH v3 4/4] PCI/ACS: Enable PCI_ACS_TB for untrusted/external-facing devices
Date: Tue, 7 Jul 2020 19:49:12 +0800
Message-ID: <202007071945.QsYzRlDy%lkp@intel.com> (raw)
In-Reply-To: <20200707045418.3517076-4-rajatja@google.com>


[-- Attachment #1: Type: text/plain, Size: 2926 bytes --]

Hi Rajat,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on pci/next]
[also build test WARNING on iommu/next pm/linux-next v5.8-rc4 next-20200707]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use  as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Rajat-Jain/PCI-Move-pci_enable_acs-and-its-dependencies-up-in-pci-c/20200707-125604
base:   https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git next
config: arm-randconfig-r012-20200707 (attached as .config)
compiler: clang version 11.0.0 (https://github.com/llvm/llvm-project 02946de3802d3bc65bc9f2eb9b8d4969b5a7add8)
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
        # 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 <lkp@intel.com>

All warnings (new ones prefixed by >>):

>> drivers/pci/pci.c:883:3: warning: add explicit braces to avoid dangling else [-Wdangling-else]
                   else
                   ^
   1 warning generated.
--
>> drivers/pci/quirks.c:4987:3: warning: add explicit braces to avoid dangling else [-Wdangling-else]
                   else
                   ^
   1 warning generated.

vim +883 drivers/pci/pci.c

   849	
   850	/**
   851	 * pci_std_enable_acs - enable ACS on devices using standard ACS capabilities
   852	 * @dev: the PCI device
   853	 */
   854	static void pci_std_enable_acs(struct pci_dev *dev)
   855	{
   856		int pos;
   857		u16 cap;
   858		u16 ctrl;
   859	
   860		pos = dev->acs_cap;
   861		if (!pos)
   862			return;
   863	
   864		pci_read_config_word(dev, pos + PCI_ACS_CAP, &cap);
   865		pci_read_config_word(dev, pos + PCI_ACS_CTRL, &ctrl);
   866	
   867		/* Source Validation */
   868		ctrl |= (cap & PCI_ACS_SV);
   869	
   870		/* P2P Request Redirect */
   871		ctrl |= (cap & PCI_ACS_RR);
   872	
   873		/* P2P Completion Redirect */
   874		ctrl |= (cap & PCI_ACS_CR);
   875	
   876		/* Upstream Forwarding */
   877		ctrl |= (cap & PCI_ACS_UF);
   878	
   879		/* Enable Translation Blocking for external devices */
   880		if (dev->external_facing || dev->untrusted)
   881			if (cap & PCI_ACS_TB)
   882				ctrl |= PCI_ACS_TB;
 > 883			else
   884				pci_warn(dev, "ACS: No Trans Blocking on ext dev\n");
   885	
   886		pci_write_config_word(dev, pos + PCI_ACS_CTRL, ctrl);
   887	}
   888	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 29197 bytes --]

      reply index

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-07  4:54 [PATCH v3 1/4] PCI: Move pci_enable_acs() and its dependencies up in pci.c Rajat Jain
2020-07-07  4:54 ` [PATCH v3 2/4] PCI: Keep the ACS capability offset in device Rajat Jain
2020-07-07  4:54 ` [PATCH v3 3/4] PCI: Treat "external-facing" devices as internal Rajat Jain
2020-07-07  4:54 ` [PATCH v3 4/4] PCI/ACS: Enable PCI_ACS_TB for untrusted/external-facing devices Rajat Jain
2020-07-07 11:49   ` kernel test robot [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202007071945.QsYzRlDy%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=baolu.lu@linux.intel.com \
    --cc=clang-built-linux@googlegroups.com \
    --cc=dwmw2@infradead.org \
    --cc=helgaas@kernel.org \
    --cc=iommu@lists.linux-foundation.org \
    --cc=joro@8bytes.org \
    --cc=kbuild-all@lists.01.org \
    --cc=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=rajatja@google.com \
    --cc=rjw@rjwysocki.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Linux-PCI Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-pci/0 linux-pci/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-pci linux-pci/ https://lore.kernel.org/linux-pci \
		linux-pci@vger.kernel.org
	public-inbox-index linux-pci

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-pci


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git