]> xenbits.xensource.com Git - libvirt.git/commit
node_device_driver: Deduplicate mediated devices listing
authorMichal Privoznik <mprivozn@redhat.com>
Thu, 24 Aug 2023 08:23:55 +0000 (10:23 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Thu, 24 Aug 2023 11:46:50 +0000 (13:46 +0200)
commit035d5ed80c8b61a203a6f1b5dab6f9bad2fca50c
tree3c83bf762e9b8a3989086a14426ee7f18b7c81d3
parenta3f0c3852e26fc9caca164b33d033e105d553316
node_device_driver: Deduplicate mediated devices listing

We have virMdevctlListDefined() to list defined mdevs, and
virMdevctlListActive() to list active mdevs. Both have the same
body except for one boolean argument passed to
nodeDeviceGetMdevctlListCommand(). Join the two functions under
virMdevctlList() name and introduce @defined argument that is
then just passed to the cmd line builder function.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Kristina Hanicova <khanicov@redhat.com>
src/node_device/node_device_driver.c