Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit fa216bf4 authored by Yinghai Lu's avatar Yinghai Lu Committed by Bjorn Helgaas
Browse files

PCI: Turn on reallocation for unassigned resources with host bridge offset



Previously we did not turn on automatic PCI resource reallocation for
unassigned IOV resources behind a host bridge with address offset.  This
patch fixes that bug.

The intent was that "!r->start" would check for a BAR containing zero.  But
that check is incorrect for host bridges that apply an offset, because in
that case the resource address is not the same as the bus address.

This patch fixes that by converting the resource address back to a bus
address before checking for zero.

[bhelgaas: changelog]
Suggested-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: default avatarYinghai Lu <yinghai@kernel.org>
Signed-off-by: default avatarBjorn Helgaas <bhelgaas@google.com>
parent 223d96fc
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment