From patchwork Tue Apr 7 12:37:08 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Beregalov X-Patchwork-Id: 16805 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n37CaqrM023972 for ; Tue, 7 Apr 2009 12:37:28 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751714AbZDGMh1 (ORCPT ); Tue, 7 Apr 2009 08:37:27 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751618AbZDGMh1 (ORCPT ); Tue, 7 Apr 2009 08:37:27 -0400 Received: from rv-out-0506.google.com ([209.85.198.238]:21886 "EHLO rv-out-0506.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751159AbZDGMh0 (ORCPT ); Tue, 7 Apr 2009 08:37:26 -0400 Received: by rv-out-0506.google.com with SMTP id f9so2707235rvb.1 for ; Tue, 07 Apr 2009 05:37:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:date:from:to:subject :message-id:mime-version:content-type:content-disposition:user-agent; bh=2OhLLHY2hd5UHkGsWQpaGPob554xo7XA7pXZ2Z2Oa88=; b=w7yDW79tJGj3pNWmRn+yk4vef3xNus4NIOQ7KogLO5ESG3dmTGqXDv70jA/sgXvZ10 rpU9l0WwTTPPxsr+jCWGv03EkY6Br7bGrUckyYdaJLrCHX7TG3xXWVtgOD8BZvspS+2J VJeIkMXwU3LTJ08dWrESSIbBhVXRULzZUXlP4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:from:to:subject:message-id:mime-version:content-type :content-disposition:user-agent; b=dMke/sdluZv6NQZUe4tWd5YCxnFunC/30e+LcgOQLozFabIFOse4C11pqkYZzLF5qS mbsQC52MknLFQM9fdPHrzQIFb7xgQ7EMCmsIc7azn0mOvNhWM2xFkPMVGZCqu1bAFSu8 HrpT9Z9iiq2rGKkvTI35Ke2AKeycxBYHQTKXo= Received: by 10.140.247.13 with SMTP id u13mr12236rvh.288.1239107845313; Tue, 07 Apr 2009 05:37:25 -0700 (PDT) Received: from orion ([91.78.18.138]) by mx.google.com with ESMTPS id l31sm363879rvb.47.2009.04.07.05.37.21 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 07 Apr 2009 05:37:23 -0700 (PDT) Date: Tue, 7 Apr 2009 16:37:08 +0400 From: Alexander Beregalov To: linux-next@vger.kernel.org, linux-kernel@vger.kernel.org, andrew.patterson@hp.com, jbarnes@virtuousgeek.org, linux-pci@vger.kernel.org Subject: [PATCH next] pci: fix build error with !PCIE_ECRC Message-ID: <20090407123707.GA18687@orion> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.19 (2009-01-05) Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org Fix this build error: drivers/built-in.o: In function `pci_init_capabilities': drivers/pci/probe.c:989: undefined reference to `pcie_set_ecrc_checking' drivers/built-in.o: In function `pci_setup': drivers/pci/pci.c:2547: undefined reference to `pcie_ecrc_get_policy' Signed-off-by: Alexander Beregalov --- drivers/pci/pci.c | 2 ++ drivers/pci/pcie/Kconfig | 2 +- drivers/pci/probe.c | 2 ++ 3 files changed, 5 insertions(+), 1 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index f61b2cf..f1c393e 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c @@ -2543,8 +2543,10 @@ static int __init pci_setup(char *str) } else if (!strncmp(str, "resource_alignment=", 19)) { pci_set_resource_alignment_param(str + 19, strlen(str + 19)); +#ifdef CONFIG_PCIE_ECRC } else if (!strncmp(str, "ecrc=", 5)) { pcie_ecrc_get_policy(str + 5); +#endif } else { printk(KERN_ERR "PCI: Unknown option `%s'\n", str); diff --git a/drivers/pci/pcie/Kconfig b/drivers/pci/pcie/Kconfig index a79e52b..9d0e727 100644 --- a/drivers/pci/pcie/Kconfig +++ b/drivers/pci/pcie/Kconfig @@ -52,7 +52,7 @@ config PCIEASPM_DEBUG # config PCIE_ECRC bool "PCI Express ECRC support" - depends on PCI + depends on PCI && PCIEPORTBUS help Enables PCI Express ECRC (transaction layer end-to-end CRC checking) diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c index d5125a1..8d402a8 100644 --- a/drivers/pci/probe.c +++ b/drivers/pci/probe.c @@ -985,8 +985,10 @@ static void pci_init_capabilities(struct pci_dev *dev) /* Single Root I/O Virtualization */ pci_iov_init(dev); +#ifdef CONFIG_PCIE_ECRC /* PCIe end-to-end CRC checking */ pcie_set_ecrc_checking(dev); +#endif } void pci_device_add(struct pci_dev *dev, struct pci_bus *bus)