diff options
| author | Bjorn Helgaas <bhelgaas@google.com> | 2024-11-25 13:40:55 -0600 |
|---|---|---|
| committer | Bjorn Helgaas <bhelgaas@google.com> | 2024-11-25 13:40:55 -0600 |
| commit | c03d361c2036f3289a45834fce8372864a4576b3 (patch) | |
| tree | 693b51230db36825f519ba5a3b7e340ff34dc3a5 /drivers/pci/pci.c | |
| parent | d985e2beb9cac53ff190883f2b7ae3085f0586f6 (diff) | |
| parent | 19f73e938df2b8edfa2e93e0280bd26fd4df5b92 (diff) | |
Merge branch 'pci/resource'
- Add resource_set_size() to set resource size when start has already been
set (Ilpo Järvinen)
- Add resource_set_range() helper to set both resource start and size (Ilpo
Järvinen)
- Use IS_ALIGNED() and resource_size() in quirk_s3_64M() instead of
open-coding them (Ilpo Järvinen)
- Add ALIGN_DOWN_IF_NONZERO() to avoid code duplication when distributing
resources across devices (Ilpo Järvinen)
- Improve pdev_sort_resources() warning message to be more specific (Ilpo
Järvinen)
* pci/resource:
PCI: Improve pdev_sort_resources() warning message
PCI: Add ALIGN_DOWN_IF_NONZERO() helper
PCI: Use align and resource helpers, and SZ_* in quirk_s3_64M()
PCI: Use resource_set_{range,size}() helpers
resource: Add resource set range and size helpers
Diffstat (limited to 'drivers/pci/pci.c')
| -rw-r--r-- | drivers/pci/pci.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index a16d74beaf58..880f7565acf3 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c @@ -6679,8 +6679,7 @@ static void pci_request_resource_alignment(struct pci_dev *dev, int bar, } else { r->flags &= ~IORESOURCE_SIZEALIGN; r->flags |= IORESOURCE_STARTALIGN; - r->start = align; - r->end = r->start + size - 1; + resource_set_range(r, align, size); } r->flags |= IORESOURCE_UNSET; } |
