| Message ID | 20261002113319.6652-2-ilpo.jarvinen@linux.intel.com |
|---|---|
| State | New |
| Headers | show |
| Series | PCI: Resource placement algorithm fixes | expand |
> Free space ranges are (part of) assigned ranges. Since new resources > have IORESOURCE_UNSET, the flag gets copied also to full_avail.flags, > which hampers printing them with %pR. > > Clear IORESOURCE_UNSET for the free space indicator resource. > > Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Sashiko has reviewed this patch and found no issues. It looks great!
diff --git a/kernel/resource.c b/kernel/resource.c index e60539a55541..17e7fccd859c 100644 --- a/kernel/resource.c +++ b/kernel/resource.c @@ -731,6 +731,7 @@ static int __find_resource_space(struct resource *root, struct resource *old, resource_alignf alignf = constraint->alignf; full_avail.start = root->start; + full_avail.flags &= ~IORESOURCE_UNSET; /* * Skip past an allocated resource that starts at 0, since the assignment * of this->start - 1 to full_avail->end below would cause an underflow.