Page MenuHomeFreeBSD

iommu_gas: eliminate unneeded wrappers
ClosedPublic

Authored by alc on Jun 14 2022, 6:56 PM.
Tags
None
Referenced Files
F84302279: D35487.id106928.diff
Wed, May 22, 1:16 AM
F84283849: D35487.id106999.diff
Tue, May 21, 8:42 PM
F84264962: D35487.id.diff
Tue, May 21, 3:52 PM
Unknown Object (File)
Wed, May 15, 4:02 PM
Unknown Object (File)
Fri, May 10, 11:11 AM
Unknown Object (File)
Fri, May 10, 11:11 AM
Unknown Object (File)
Fri, May 10, 6:48 AM
Unknown Object (File)
Fri, May 10, 6:20 AM
Subscribers

Details

Summary

Eliminate trivial wrappers for several iommu_gas functions. These wrappers serve no functional purpose.

Test Plan

Tested with netperf on amd64. On arm64, a kernel with the IOMMU option compiles.

Diff Detail

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

Event Timeline

alc requested review of this revision.Jun 14 2022, 6:56 PM
alc created this revision.

The idea of these wrappers was to abstract function names, i.e. make them looking generic by removing name "gas". I'm not sure what "gas" stands for, but there is no such thing on arm64.

so with this I can use iommu_map() in my ARM Komeda display controller driver (part of cheribsd), not confusing anyone with 'gas'

sys/dev/drm/komeda/komeda_plane.c:      error = iommu_map(iodom,
In D35487#804780, @br wrote:

The idea of these wrappers was to abstract function names, i.e. make them looking generic by removing name "gas". I'm not sure what "gas" stands for, but there is no such thing on arm64.

I believe that it stood for "guest address space".

I also considered renaming iommu_gas_map, etc. to iommu_map, etc., but that entailed more changes. Nonetheless, I would be happy to take that approach.

In D35487#804790, @alc wrote:
In D35487#804780, @br wrote:

The idea of these wrappers was to abstract function names, i.e. make them looking generic by removing name "gas". I'm not sure what "gas" stands for, but there is no such thing on arm64.

I believe that it stood for "guest address space".

I also considered renaming iommu_gas_map, etc. to iommu_map, etc., but that entailed more changes. Nonetheless, I would be happy to take that approach.

as you wish, I am more or less fine with 'guest address space' since it is not amd64-specific. But the approach would be good.

This revision is now accepted and ready to land.Jun 14 2022, 8:08 PM
This revision was automatically updated to reflect the committed changes.