Re: [PATCH 2/5] util: introduce virHostCPUGetMicrocodeVersion

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

 



On Thu, Jan 04, 2018 at 04:27:45PM +0100, Jiri Denemark wrote:
On Thu, Jan 04, 2018 at 16:15:46 +0100, Peter Krempa wrote:
On Thu, Jan 04, 2018 at 15:58:09 +0100, Jiri Denemark wrote:
> +        char ebuf[1024];
> +        VIR_DEBUG("Failed to read microcode version from %s: %s",
> +                  CPUINFO_PATH, virStrerror(errno, ebuf, sizeof(ebuf)));

Formatting the error message into a debug message does not make much
sense. I'd just log 'errno' in raw since this function does not really
return any errors.
...
ACK with pointless error formatting removed.

It's not pointless. It makes the log useful without having to look at
/usr/include/asm-generic/errno-base.h. And it will only be done once in
libvirtd lifetime so it's not really wasting CPU cycles or something.


ACK including the error formatting. I see the point in it, CPU cycles
are cheaper than human cycles.

Jan

Jirka

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

Attachment: signature.asc
Description: Digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]
  Powered by Linux