From mboxrd@z Thu Jan 1 00:00:00 1970 From: Benjamin Herrenschmidt Subject: Re: [PATCH v2 02/19] OpenRISC: Device tree Date: Mon, 04 Jul 2011 07:39:38 +1000 Message-ID: <1309729178.14501.264.camel@pasglop> References: <1309641352-18714-1-git-send-email-jonas@southpole.se> <1309641352-18714-3-git-send-email-jonas@southpole.se> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: devicetree-discuss-bounces+gldd-devicetree-discuss=m.gmane.org-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org Sender: devicetree-discuss-bounces+gldd-devicetree-discuss=m.gmane.org-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org To: Grant Likely Cc: linux-arch-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-Id: linux-arch.vger.kernel.org On Sun, 2011-07-03 at 14:51 -0600, Grant Likely wrote: > > + > > +#ifdef CONFIG_PCI > > +/* > > + * PCI <-> OF matching functions > > + * (XXX should these be here?) > > + */ > > +struct pci_bus; > > +struct pci_dev; > > +extern int pci_device_from_OF_node(struct device_node *node, > > + u8 *bus, u8 *devfn); > > +extern struct device_node *pci_busdev_to_OF_node(struct pci_bus > *bus, > > + int devfn); > > +extern struct device_node *pci_device_to_OF_node(struct pci_dev > *dev); > > +extern void pci_create_OF_bus_map(void); > > +#endif Don't copy these from powermac or microblaze. the OF_bus_map is something that should not spread :-) You get all you need of the above from generic code with my patches to PCI <-> OF matching, which should be in linux-next and are going to be merged in the next merge window. Cheers, Ben. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate.crashing.org ([63.228.1.57]:46709 "EHLO gate.crashing.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751627Ab1GCVj5 (ORCPT ); Sun, 3 Jul 2011 17:39:57 -0400 Subject: Re: [PATCH v2 02/19] OpenRISC: Device tree From: Benjamin Herrenschmidt In-Reply-To: References: <1309641352-18714-1-git-send-email-jonas@southpole.se> <1309641352-18714-3-git-send-email-jonas@southpole.se> Content-Type: text/plain; charset="UTF-8" Date: Mon, 04 Jul 2011 07:39:38 +1000 Message-ID: <1309729178.14501.264.camel@pasglop> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-arch-owner@vger.kernel.org List-ID: To: Grant Likely Cc: Jonas Bonn , linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, devicetree-discuss@lists.ozlabs.org Message-ID: <20110703213938.Wss5-Qq9VTUAoniWQgdDQsqgGwt7pSZ9dFesti0Jov4@z> On Sun, 2011-07-03 at 14:51 -0600, Grant Likely wrote: > > + > > +#ifdef CONFIG_PCI > > +/* > > + * PCI <-> OF matching functions > > + * (XXX should these be here?) > > + */ > > +struct pci_bus; > > +struct pci_dev; > > +extern int pci_device_from_OF_node(struct device_node *node, > > + u8 *bus, u8 *devfn); > > +extern struct device_node *pci_busdev_to_OF_node(struct pci_bus > *bus, > > + int devfn); > > +extern struct device_node *pci_device_to_OF_node(struct pci_dev > *dev); > > +extern void pci_create_OF_bus_map(void); > > +#endif Don't copy these from powermac or microblaze. the OF_bus_map is something that should not spread :-) You get all you need of the above from generic code with my patches to PCI <-> OF matching, which should be in linux-next and are going to be merged in the next merge window. Cheers, Ben.