mirror of
https://github.com/ipxe/ipxe
synced 2026-01-21 18:30:56 +03:00
[pci] Handle sizing of 64-bit BARs
Provide pci_bar_set() to handle setting the base address for a potentially 64-bit BAR, and rewrite pci_bar_size() to correctly handle sizing of 64-bit BARs. Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
@@ -314,6 +314,9 @@ struct pci_driver {
|
||||
extern void adjust_pci_device ( struct pci_device *pci );
|
||||
extern unsigned long pci_bar_start ( struct pci_device *pci,
|
||||
unsigned int reg );
|
||||
extern void pci_bar_set ( struct pci_device *pci, unsigned int reg,
|
||||
unsigned long start );
|
||||
extern unsigned long pci_bar_size ( struct pci_device *pci, unsigned int reg );
|
||||
extern int pci_read_config ( struct pci_device *pci );
|
||||
extern int pci_find_next ( struct pci_device *pci, uint32_t *busdevfn );
|
||||
extern int pci_find_driver ( struct pci_device *pci );
|
||||
@@ -322,7 +325,6 @@ extern void pci_remove ( struct pci_device *pci );
|
||||
extern int pci_find_capability ( struct pci_device *pci, int capability );
|
||||
extern int pci_find_next_capability ( struct pci_device *pci,
|
||||
int pos, int capability );
|
||||
extern unsigned long pci_bar_size ( struct pci_device *pci, unsigned int reg );
|
||||
extern void pci_reset ( struct pci_device *pci, unsigned int exp );
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user