[libvirt] [PATCH v2] conf: Add new module node_device_util

Michal Privoznik mprivozn at redhat.com
Mon Nov 12 14:25:02 UTC 2018


On 11/12/2018 12:56 PM, Erik Skultety wrote:
> There's a lot of stuff going on in src/conf/nodedev_conf which is
> sometimes not directly related to config and we're not really consistent
> with putting only parser/formatter related stuff here, e.g. like we do
> for domains. So, let's start simply by adding a new module
> node_device_util containing some of the helpers. Unfortunately, even
> though these helpers tend to open a secondary driver connection and would
> be much therefore better suited as a nodedev driver module, we can't do
> that without pulling headers from the driver into conf/ and that's wrong
> because we want conf/ to stay driver-agnostic.
> 
> Signed-off-by: Erik Skultety <eskultet at redhat.com>
> ---
>  src/conf/Makefile.inc.am             |   2 +
>  src/conf/node_device_conf.c          | 199 -----------------------
>  src/conf/node_device_conf.h          |  11 --
>  src/conf/node_device_util.c          | 229 +++++++++++++++++++++++++++
>  src/conf/node_device_util.h          |  35 ++++
>  src/conf/virstorageobj.c             |   1 +
>  src/libvirt_private.syms             |   7 +-
>  src/node_device/node_device_driver.c |   1 +
>  src/storage/storage_backend_scsi.c   |   1 +
>  9 files changed, 273 insertions(+), 213 deletions(-)
>  create mode 100644 src/conf/node_device_util.c
>  create mode 100644 src/conf/node_device_util.h

ACK

Michal




More information about the libvir-list mailing list