From patchwork Tue Feb 3 01:37:24 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kevin Hao X-Patchwork-Id: 435677 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [103.22.144.68]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 6FEB51401D0 for ; Tue, 3 Feb 2015 12:38:22 +1100 (AEDT) Received: from ozlabs.org (ozlabs.org [103.22.144.67]) by lists.ozlabs.org (Postfix) with ESMTP id 5E82A1A0FF2 for ; Tue, 3 Feb 2015 12:38:22 +1100 (AEDT) X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Received: from mail-yh0-x235.google.com (mail-yh0-x235.google.com [IPv6:2607:f8b0:4002:c01::235]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id BE9621A0010 for ; Tue, 3 Feb 2015 12:37:40 +1100 (AEDT) Received: by mail-yh0-f53.google.com with SMTP id v1so17381805yhn.12 for ; Mon, 02 Feb 2015 17:37:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=FnJz1Sivf42oUmev7bwWsURzP0jlOBo4UvNXuiDb7N0=; b=AZn46QGkO8XzZKNGerh5o+NxU0sO6A1Qt/qKBsld5D4fa7jIzej1umEw07FopsY1uU QzblCAp1Dr68rWGXGLMwmy1y9tzqmSCjgr1wQWr2/y9i+KYWu63iKZJxwIKJR6WaLnDC 3/D4Cv1rXw5cwkbMe1Q7HemEo6NRrtjgguH8TklQ94tK+9zezyEkrm0RjCcyt2DKO6ga BpVsr35wxYKchHFq6uxezvEzeMY5AaNFzUh0bKByzAu0iyyulzZZsVWxrIOcxZ8+rudy r2SAu4zLxmLTVESutxm5lClJGqrOVQlPGbljuB2jPsAmE83JoP16vRAxBycPW8sXTvgP zU5Q== X-Received: by 10.236.221.134 with SMTP id r6mr9028279yhp.137.1422927457821; Mon, 02 Feb 2015 17:37:37 -0800 (PST) Received: from pek-khao-d1.corp.ad.wrs.com ([106.120.101.38]) by mx.google.com with ESMTPSA id p29sm13361025yhp.36.2015.02.02.17.37.35 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 02 Feb 2015 17:37:37 -0800 (PST) From: Kevin Hao To: Bjorn Helgaas Subject: [PATCH v2 01/15] PCI: Add pci_device_to_OF_node() stub for !CONFIG_OF Date: Tue, 3 Feb 2015 09:37:24 +0800 Message-Id: <1422927444-31292-1-git-send-email-haokexin@gmail.com> X-Mailer: git-send-email 1.9.3 In-Reply-To: <1422923108.4625.2.camel@ellerman.id.au> References: <1422923108.4625.2.camel@ellerman.id.au> Cc: linuxppc-dev@lists.ozlabs.org, linux-pci@vger.kernel.org X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" Add a stub for pci_device_to_OF_node() so drivers don't need to use #ifdef CONFIG_OF around calls to it. Signed-off-by: Kevin Hao Acked-by: Bjorn Helgaas --- Hi Bjorn, Here is the revised version with the update of the subject and commit log in case that you want to take it for 3.20. Otherwise we will merge this version to powerpc tree during the 3.21 cycle. include/linux/pci.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/linux/pci.h b/include/linux/pci.h index 8323cbf93913..421eb6a9e600 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -1863,6 +1863,8 @@ static inline void pci_set_of_node(struct pci_dev *dev) { } static inline void pci_release_of_node(struct pci_dev *dev) { } static inline void pci_set_bus_of_node(struct pci_bus *bus) { } static inline void pci_release_bus_of_node(struct pci_bus *bus) { } +static inline struct device_node * +pci_device_to_OF_node(const struct pci_dev *pdev) { return NULL; } #endif /* CONFIG_OF */ #ifdef CONFIG_EEH