libvirt/src/node_device
Jonathon Jongsma dfa1e9b3eb nodedev: improve error message when destroying an inactive device
When trying to destroy a node device that is not active, we end up with
a confusing error message:

  # nodedev-destroy mdev_88a6b868_46bd_4015_8e5b_26107f82da38
  error: Failed to destroy node device 'mdev_88a6b868_46bd_4015_8e5b_26107f82da38'
  error: failed to access '/sys/bus/mdev/devices/88a6b868-46bd-4015-8e5b-26107f82da38/iommu_group': No such file or directory

With this patch, the error is more clear:

  # nodedev-destroy mdev_88a6b868_46bd_4015_8e5b_26107f82da38
  error: Failed to destroy node device 'mdev_88a6b868_46bd_4015_8e5b_26107f82da38'
  error: Requested operation is not valid: Device 'mdev_88a6b868_46bd_4015_8e5b_26107f82da38' is not active

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
Reviewed-by: Boris Fiuczynski <fiuczy@linux.ibm.com>
2021-07-01 16:34:03 +02:00
..
meson.build build: Remove unused 'conflicts' key from virt_daemon_unit 2021-02-10 09:30:41 -07:00
node_device_driver.c nodedev: improve error message when destroying an inactive device 2021-07-01 16:34:03 +02:00
node_device_driver.h nodedev: Remove GetMdevctl*Command() wrappers 2021-04-19 10:24:13 -05:00
node_device_udev.c node_device_udev: Also process ID_TYPE=cd/dvd in udevProcessStorage() 2021-06-02 10:12:49 +02:00
node_device_udev.h Revert "Also look for dmi information in /sys/class" 2020-10-02 13:56:46 +02:00
virtnodedevd.init.in configure: Provide OpenRC scripts for sub-daemons 2019-12-16 10:11:22 +01:00
virtnodedevd.service.in systemd: Move timeout from service files to sysconf files 2020-04-03 11:50:50 +02:00
virtnodedevd.sysconf systemd: Move timeout from service files to sysconf files 2020-04-03 11:50:50 +02:00