Messages in this thread | | | Date | Sat, 20 Nov 2004 19:55:36 -0600 | From | Brian King <> | Subject | Re: [PATCH 1/2] pci: Block config access during BIST |
| |
Benjamin Herrenschmidt wrote: >>It still doesn't address Greg's issue about making this apply to the >>pci_bus_* functions as well, but I'm not sure of a good way to do that >>due to the reasons given earlier. > > > Looks good to me, I don't sure we actually have to deal with pci_bus_* > functions, do we ? When are they called ?
For what we are trying to solve, which is blocking userspace config accesses, I don't think we do. Greg - are you ok with this?
>>+void pci_block_config_access(struct pci_dev *dev) >>+{ >>+ unsigned long flags; >>+ >>+ spin_lock_irqsave(&pci_lock, flags); >>+ dev->block_cfg_access = 1; >>+ spin_unlock_irqrestore(&pci_lock, flags); >>+} > > > Shouldn't we save the config space here ?
I thought about that when coding this up and thought it would be better to simply have the function do what it advertises and no more. Seems strange that a function called pci_block_config_access would go and do a bunch of pci config accesses, but we can certainly add it if you like.
-Brian
-- Brian King eServer Storage I/O IBM Linux Technology Center
- 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/
| |