From: Colin Ngam <cngam@sgi.com> To: Matthew Wilcox <matthew@wil.cx> Cc: Grant Grundler <iod00d@hp.com>, Jesse Barnes <jbarnes@engr.sgi.com>, Patrick Gefre <pfg@sgi.com>, "Luck, Tony" <tony.luck@intel.com>, linux-kernel@vger.kernel.org, linux-ia64@vger.kernel.org Subject: Re: [PATCH] 2.6 SGI Altix I/O code reorganization Date: Wed, 06 Oct 2004 15:55:59 -0500 [thread overview] Message-ID: <41645BDE.E9732310@sgi.com> (raw) In-Reply-To: 20041006210525.GI16153@parcelfarce.linux.theplanet.co.uk Matthew Wilcox wrote: > On Wed, Oct 06, 2004 at 01:48:32PM -0700, Grant Grundler wrote: > > Agreed. I'm not real clear on why drivers/acpi didn't do that. > > But apperently ACPI supports many methods to PCI or PCI-Like (can you > > guess I'm not clear on this?) config space. raw_pci_ops supports > > multiple methods in i386. ia64 only happens to use one so far. > > It seems right for SN2 to use this mechanism if it needs a different > > method. > > > > Willy tried to explain this to me yesterday and I thought I understood > > most of it...apperently that was a transient moment of clarity. :^/ > > Let's try it again, by email this time. > > Fundamentally, there is a huge impedence mismatch between how the ACPI > interpreter wants to access PCI configuration space, and how Linux wants > to access PCI configuration space. Linux always has at least a pci_bus > around, if not a pci_dev. So we can use dev->bus->ops to abstract the > architecture-specific implementation of "how do I get to configuration > space for this bus?" > > ACPI doesn't have a pci_bus. It just passes around a struct of { domain, > bus, dev, function } and expects the OS-specific code to determine what > to do with it. The original hacky code constructed a fake pci_dev on the > stack and called the regular methods. This broke ia64 because we needed > something else to be valid (I forget what), so as part of the grand "get > ia64 fully merged upstream" effort, I redesigned the OS-specific code. > > Fortunately, neither i386 nor ia64 actually need the feature Linux has > to have a per-bus pci_ops -- it's always the same. I think powerpc is > the only architecture that needs it. So I introduced a pci_raw_ops that > both ACPI and a generic pci_root_ops could call. > > The part I didn't seem to be able to get across to you yesterday was > that pci_root_ops is not just used for the PCI root bridge, it's used > for accessing every PCI device underneath that root bridge. Hi Guys, Therefore, would it be perfectly fine if we remove the static from pci_root_ops so that we can use it outside of pci/pci.c?? I can include this in a follow-on patch. Thanks. colin > > > -- > "Next the statesmen will invent cheap lies, putting the blame upon > the nation that is attacked, and every man will be glad of those > conscience-soothing falsities, and will diligently study them, and refuse > to examine any refutations of them; and thus he will by and by convince > himself that the war is just, and will thank God for the better sleep > he enjoys after this process of grotesque self-deception." -- Mark Twain
WARNING: multiple messages have this Message-ID (diff)
From: Colin Ngam <cngam@sgi.com> To: Matthew Wilcox <matthew@wil.cx> Cc: Grant Grundler <iod00d@hp.com>, Jesse Barnes <jbarnes@engr.sgi.com>, Patrick Gefre <pfg@sgi.com>, "Luck, Tony" <tony.luck@intel.com>, linux-kernel@vger.kernel.org, linux-ia64@vger.kernel.org Subject: Re: [PATCH] 2.6 SGI Altix I/O code reorganization Date: Wed, 06 Oct 2004 20:55:59 +0000 [thread overview] Message-ID: <41645BDE.E9732310@sgi.com> (raw) In-Reply-To: 20041006210525.GI16153@parcelfarce.linux.theplanet.co.uk Matthew Wilcox wrote: > On Wed, Oct 06, 2004 at 01:48:32PM -0700, Grant Grundler wrote: > > Agreed. I'm not real clear on why drivers/acpi didn't do that. > > But apperently ACPI supports many methods to PCI or PCI-Like (can you > > guess I'm not clear on this?) config space. raw_pci_ops supports > > multiple methods in i386. ia64 only happens to use one so far. > > It seems right for SN2 to use this mechanism if it needs a different > > method. > > > > Willy tried to explain this to me yesterday and I thought I understood > > most of it...apperently that was a transient moment of clarity. :^/ > > Let's try it again, by email this time. > > Fundamentally, there is a huge impedence mismatch between how the ACPI > interpreter wants to access PCI configuration space, and how Linux wants > to access PCI configuration space. Linux always has at least a pci_bus > around, if not a pci_dev. So we can use dev->bus->ops to abstract the > architecture-specific implementation of "how do I get to configuration > space for this bus?" > > ACPI doesn't have a pci_bus. It just passes around a struct of { domain, > bus, dev, function } and expects the OS-specific code to determine what > to do with it. The original hacky code constructed a fake pci_dev on the > stack and called the regular methods. This broke ia64 because we needed > something else to be valid (I forget what), so as part of the grand "get > ia64 fully merged upstream" effort, I redesigned the OS-specific code. > > Fortunately, neither i386 nor ia64 actually need the feature Linux has > to have a per-bus pci_ops -- it's always the same. I think powerpc is > the only architecture that needs it. So I introduced a pci_raw_ops that > both ACPI and a generic pci_root_ops could call. > > The part I didn't seem to be able to get across to you yesterday was > that pci_root_ops is not just used for the PCI root bridge, it's used > for accessing every PCI device underneath that root bridge. Hi Guys, Therefore, would it be perfectly fine if we remove the static from pci_root_ops so that we can use it outside of pci/pci.c?? I can include this in a follow-on patch. Thanks. colin > > > -- > "Next the statesmen will invent cheap lies, putting the blame upon > the nation that is attacked, and every man will be glad of those > conscience-soothing falsities, and will diligently study them, and refuse > to examine any refutations of them; and thus he will by and by convince > himself that the war is just, and will thank God for the better sleep > he enjoys after this process of grotesque self-deception." -- Mark Twain
next prev parent reply other threads:[~2004-10-06 21:16 UTC|newest] Thread overview: 82+ messages / expand[flat|nested] mbox.gz Atom feed top 2004-10-05 20:34 [PATCH] 2.6 SGI Altix I/O code reorganization Luck, Tony 2004-10-05 20:34 ` Luck, Tony 2004-10-06 15:32 ` Patrick Gefre 2004-10-06 15:32 ` Patrick Gefre 2004-10-06 18:57 ` Grant Grundler 2004-10-06 18:57 ` Grant Grundler 2004-10-06 19:09 ` Colin Ngam 2004-10-06 19:09 ` Colin Ngam 2004-10-06 19:54 ` Grant Grundler 2004-10-06 19:54 ` Grant Grundler 2004-10-06 19:54 ` Colin Ngam 2004-10-06 19:54 ` Colin Ngam 2004-10-06 20:10 ` Patrick Gefre 2004-10-06 20:10 ` Patrick Gefre 2004-10-06 20:44 ` Jesse Barnes 2004-10-06 20:44 ` Jesse Barnes 2004-10-07 15:02 ` Patrick Gefre 2004-10-07 15:02 ` Patrick Gefre 2004-10-07 16:52 ` Jesse Barnes 2004-10-07 16:52 ` Jesse Barnes 2004-10-06 20:27 ` Jesse Barnes 2004-10-06 20:27 ` Jesse Barnes 2004-10-06 20:21 ` Colin Ngam 2004-10-06 20:21 ` Colin Ngam 2004-10-06 20:33 ` Matthew Wilcox 2004-10-06 20:33 ` Matthew Wilcox 2004-10-06 20:48 ` Grant Grundler 2004-10-06 20:48 ` Grant Grundler 2004-10-06 21:05 ` Matthew Wilcox 2004-10-06 21:05 ` Matthew Wilcox 2004-10-06 20:55 ` Colin Ngam [this message] 2004-10-06 20:55 ` Colin Ngam 2004-10-08 15:16 ` Colin Ngam 2004-10-08 15:16 ` Colin Ngam 2004-10-08 16:37 ` Jesse Barnes 2004-10-08 16:37 ` Jesse Barnes 2004-10-09 22:20 ` Grant Grundler 2004-10-09 22:20 ` Grant Grundler [not found] ` <4169A508.84FB19C7@sgi.com> 2004-10-11 14:03 ` Patrick Gefre 2004-10-11 14:03 ` Patrick Gefre 2004-10-08 22:37 ` Colin Ngam 2004-10-08 22:37 ` Colin Ngam -- strict thread matches above, loose matches on Subject: below -- 2004-10-11 20:49 Luck, Tony 2004-10-11 20:49 ` Luck, Tony 2004-10-07 17:06 Luck, Tony 2004-10-07 17:06 ` Luck, Tony 2004-10-07 17:22 ` Jesse Barnes 2004-10-07 17:22 ` Jesse Barnes 2004-10-07 18:59 ` Jes Sorensen 2004-10-07 18:59 ` Jes Sorensen 2004-10-05 19:16 Luck, Tony 2004-10-05 19:16 ` Luck, Tony 2004-10-05 19:35 ` Patrick Gefre 2004-10-05 19:35 ` Patrick Gefre 2004-10-05 5:13 Luck, Tony 2004-10-05 5:13 ` Luck, Tony 2004-10-05 15:43 ` Jesse Barnes 2004-10-05 15:43 ` Jesse Barnes 2004-10-05 16:22 ` Grant Grundler 2004-10-05 16:22 ` Grant Grundler 2004-10-05 17:45 ` Matthew Wilcox 2004-10-05 17:45 ` Matthew Wilcox 2004-10-05 19:00 ` Colin Ngam 2004-10-05 19:00 ` Colin Ngam 2004-10-05 19:10 ` Grant Grundler 2004-10-05 19:10 ` Grant Grundler 2004-10-05 19:15 ` Matthew Wilcox 2004-10-05 19:15 ` Matthew Wilcox 2004-10-05 18:20 ` Patrick Gefre 2004-10-05 18:20 ` Patrick Gefre 2004-10-05 18:34 ` Jesse Barnes 2004-10-05 18:34 ` Jesse Barnes 2004-10-04 21:57 Pat Gefre 2004-10-04 21:57 ` Pat Gefre 2004-10-05 15:48 ` Christoph Hellwig 2004-10-05 15:48 ` Christoph Hellwig 2004-10-05 18:26 ` Patrick Gefre 2004-10-05 18:26 ` Patrick Gefre 2004-10-05 23:30 ` Patrick Gefre 2004-10-05 23:30 ` Patrick Gefre 2004-10-05 15:50 ` Christoph Hellwig 2004-10-05 15:50 ` Christoph Hellwig
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=41645BDE.E9732310@sgi.com \ --to=cngam@sgi.com \ --cc=iod00d@hp.com \ --cc=jbarnes@engr.sgi.com \ --cc=linux-ia64@vger.kernel.org \ --cc=linux-kernel@vger.kernel.org \ --cc=matthew@wil.cx \ --cc=pfg@sgi.com \ --cc=tony.luck@intel.com \ /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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.