diff options
author | Kevin O'Connor <kevin@koconnor.net> | 2010-01-03 15:14:11 -0500 |
---|---|---|
committer | Kevin O'Connor <kevin@koconnor.net> | 2010-01-03 15:14:11 -0500 |
commit | b5bb9db8425b3b463e634874e3a201a354d55ac7 (patch) | |
tree | c3fd5d03b9fdccbf16d31c5b327c86457c167f55 /src/pci.h | |
parent | 8918989ec2b60a38305d3c91d7ab600db0eb7593 (diff) | |
download | seabios-b5bb9db8425b3b463e634874e3a201a354d55ac7.tar.gz |
mptable: Reset pinmask on new bus or device.
Fix small possibility of bus changing without device changing.
Diffstat (limited to 'src/pci.h')
-rw-r--r-- | src/pci.h | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -9,6 +9,9 @@ static inline u8 pci_bdf_to_bus(u16 bdf) { static inline u8 pci_bdf_to_devfn(u16 bdf) { return bdf & 0xff; } +static inline u16 pci_bdf_to_busdev(u16 bdf) { + return bdf & ~0x07; +} static inline u8 pci_bdf_to_dev(u16 bdf) { return (bdf >> 3) & 0x1f; } |