Skip to content

Add CDISpecDirs to Info output#46004

Merged
thaJeztah merged 3 commits intomoby:masterfrom
elezar:add-cdi-spec-dirs-to-info
Aug 7, 2023
Merged

Add CDISpecDirs to Info output#46004
thaJeztah merged 3 commits intomoby:masterfrom
elezar:add-cdi-spec-dirs-to-info

Conversation

@elezar
Copy link
Copy Markdown
Contributor

@elezar elezar commented Jul 18, 2023

This PR makes the following changes:

  • An empty "cdi-spec-dirs" in the daemon config or specifying --cdi-spec-dir="" will disable CDI injection even if experimental mode is enabled.
  • The configured value for cdi-spec-dirs is added to the system info output. Note that an empty slice is explicitly output. This is a follow-up to the changes adding CDI support as per Add support for CDI devices under Linux #45134 (comment).

- What I did

Added the configured cdi-spec-dirs to the system info output.

- How I did it

  • Moved the initialisation to the default options to loadDaemonCliConfig to handle the case where the option is not set to an empty slice.
  • Updated the system.Info struct with a CDISpecDirs field that is filled from the config option when daemon.SystemInfo is called.

- How to verify it

The change includes unit tests to ensure that the applied setting is returned.

- Description for the changelog

  • Disable CDI device injection if cdi-spec-dirs is empty or set to a single empty string using the command line arguments.
  • Added CDISpecDirs to system info output.

- A picture of a cute animal (not mandatory but encouraged)

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants