Page MenuHomeFreeBSD

bhyve: Cast away const when fetching a config nvlist
ClosedPublic

Authored by markj on Nov 6 2022, 7:37 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Oct 21, 5:20 PM
Unknown Object (File)
Sep 17 2024, 11:31 PM
Unknown Object (File)
Sep 17 2024, 8:16 PM
Unknown Object (File)
Sep 17 2024, 7:30 PM
Unknown Object (File)
Sep 17 2024, 12:54 AM
Unknown Object (File)
Sep 16 2024, 9:56 PM
Unknown Object (File)
Sep 13 2024, 6:30 PM
Unknown Object (File)
Sep 8 2024, 5:24 PM
Subscribers

Details

Summary

Silence a warning from the compiler about "const" being discarded. The
warning is correct: nvlist values are supposed to be immutable.
However, fixing this properly will require some contortions on behalf of
consumers who look up a subtree of the config and modify it. Per a
discussion on freebsd-virtualization@, the solution will probably be to
outright replace the use of nvlists for VM configuration, but until that
happens let's document the problem and silence the warning.

No functional change intended.

Diff Detail

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