Page MenuHomeFreeBSD

pci_host_generic: stop address translation in bus_alloc_resource
ClosedPublic

Authored by kevans on Sep 18 2022, 6:14 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Apr 19, 11:48 AM
Unknown Object (File)
Fri, Apr 12, 1:49 PM
Unknown Object (File)
Feb 8 2024, 6:04 PM
Unknown Object (File)
Jan 10 2024, 1:55 AM
Unknown Object (File)
Dec 27 2023, 5:12 PM
Unknown Object (File)
Dec 27 2023, 2:18 PM
Unknown Object (File)
Dec 19 2023, 8:26 PM
Unknown Object (File)
Dec 15 2023, 8:54 PM

Details

Summary

Translating the provided range prior to rman_reserve_resource(9) is
decidedly wrong; the caller may be trying to do a wildcard allocation,
for which the implementation is expected to DTRT and clamp the range to
what's actually feasible.

We don't use the resulting translation here anyways, so just remove it
entirely -- the rman in the default implementation is derived from
sc->ranges, so the translation should trivially succeed every time as
long as the reservation succeeded. If something has gone awry in a
derived driver, we'll detect it when we translate prior to activation,
so there's likely no diagnostic value in retaining the translation after
reservation either.

Noticed by: jhb

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable