[PATCH 17/19] pci-assign: Replace exit() with hw_error()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is more appropriate and allows central handling.

Signed-off-by: Jan Kiszka <jan.kiszka@xxxxxxxxxxx>
---
 hw/kvm/pci-assign.c |   10 ++--------
 1 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/hw/kvm/pci-assign.c b/hw/kvm/pci-assign.c
index cfd859e..29a4671 100644
--- a/hw/kvm/pci-assign.c
+++ b/hw/kvm/pci-assign.c
@@ -358,10 +358,7 @@ again:
             goto again;
         }
 
-        fprintf(stderr, "%s: pread failed, ret = %zd errno = %d\n",
-                __func__, ret, errno);
-
-        exit(1);
+        hw_error("pci read failed, ret = %zd errno = %d\n", ret, errno);
     }
 
     return val;
@@ -385,10 +382,7 @@ again:
             goto again;
         }
 
-        fprintf(stderr, "%s: pwrite failed, ret = %zd errno = %d\n",
-                __func__, ret, errno);
-
-        exit(1);
+        hw_error("pci write failed, ret = %zd errno = %d\n", ret, errno);
     }
 }
 
-- 
1.7.3.4

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux