Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932439AbaGASod (ORCPT ); Tue, 1 Jul 2014 14:44:33 -0400 Received: from fw-tnat.cambridge.arm.com ([217.140.96.21]:50154 "EHLO cam-smtp0.cambridge.arm.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S932389AbaGASoa (ORCPT ); Tue, 1 Jul 2014 14:44:30 -0400 From: Liviu Dudau To: linux-pci , Bjorn Helgaas , Catalin Marinas , Will Deacon , Benjamin Herrenschmidt , Arnd Bergmann , linaro-kernel , Tanmay Inamdar , Grant Likely , Sinan Kaya , Jingoo Han , Kukjin Kim , Suravee Suthikulanit Cc: LKML , Device Tree ML , LAKML Subject: [PATCH v8 7/9] pci: of: Parse and map the IRQ when adding the PCI device. Date: Tue, 1 Jul 2014 19:43:32 +0100 Message-Id: <1404240214-9804-8-git-send-email-Liviu.Dudau@arm.com> X-Mailer: git-send-email 2.0.0 In-Reply-To: <1404240214-9804-1-git-send-email-Liviu.Dudau@arm.com> References: <1404240214-9804-1-git-send-email-Liviu.Dudau@arm.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Enhance the default implementation of pcibios_add_device() to parse and map the IRQ of the device if a DT binding is available. Signed-off-by: Liviu Dudau --- drivers/pci/pci.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index 63a54a3..8e65dc3 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c @@ -17,6 +17,7 @@ #include #include #include +#include #include #include #include @@ -1453,6 +1454,9 @@ EXPORT_SYMBOL(pcim_pin_device); */ int __weak pcibios_add_device(struct pci_dev *dev) { +#ifdef CONFIG_OF + dev->irq = of_irq_parse_and_map_pci(dev, 0, 0); +#endif return 0; } -- 2.0.0 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/