Re: [PATCH] Change pci_raw_ops to pci_raw_read/write
From: Matthew Wilcox
Date: Sun Feb 10 2008 - 14:37:46 EST
On Sun, Feb 10, 2008 at 12:13:13PM -0700, Grant Grundler wrote:
> Just wondering...why don't we just pass "struct bus*" through to the
> raw_pci* ops?
> My thinking is if a PCI bus controller or bridge is discovered, then we should
> always create a matching "struct bus *".
ACPI may need to access PCI config space before we've done a PCI bus
walk. There's an opregion that AML may access that is for PCI config
space, and an apparently unrelated method might happen to contain such a
piece of AML.
> > --- a/arch/x86/kernel/quirks.c
> > +++ b/arch/x86/kernel/quirks.c
> > @@ -27,7 +27,7 @@ static void __devinit quirk_intel_irqbalance(struct pci_dev *dev)
> > pci_write_config_byte(dev, 0xf4, config|0x2);
> >
> > /* read xTPR register */
> > - raw_pci_ops->read(0, 0, 0x40, 0x4c, 2, &word);
> > + raw_pci_read(0, 0, 0x40, 0x4c, 2, &word);
>
> Why are we using raw_pci_read here instead of pci_read_config_dword()?
> If the pci_write_config_byte() above works, then I expect the read
> to work too.
I have no idea. I didn't want to change the semantics in this patch.
Presumably the original author would have an idea why they needed to do
this.
--
Intel are signing my paycheques ... these opinions are still mine
"Bill, look, we understand that you're interested in selling us this
operating system, but compare it to ours. We can't possibly take such
a retrograde step."
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/