pci: add helper functions to check ranges overlap.
add helper function to check ranges overlap suggested by
Michael S. Tsirkin <
[email protected]>.
His original suggestion was to use [first, last], however I chosen
to use offset, length pair, i.e. [offset, offset + length)
because pci configuration space related functions all uses offset and length
pair, so it helps to avoid to type constant twice.
Cc: Michael S. Tsirkin <[email protected]>
Signed-off-by: Isaku Yamahata <[email protected]>
Signed-off-by: Anthony Liguori <[email protected]>