pci: Range check address conversions
When converting between PCI bus and physical addresses, include a length parameter that can be used to check that the entire range fits within one of the PCI regions. This prevents an address being returned that might be only partially valid for the range it is going to be used for. Where the range check is not wanted, passing a length of 0 will have the same behaviour as before this change. Signed-off-by:Andrew Scull <ascull@google.com> Reviewed-by:
Bin Meng <bmeng.cn@gmail.com>
Loading
Please register or sign in to comment