power: fix error messages
authorDaniel Mrzyglod <danielx.t.mrzyglod@intel.com>
Wed, 20 Apr 2016 14:39:30 +0000 (16:39 +0200)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Mon, 16 May 2016 12:17:41 +0000 (14:17 +0200)
commitf87a9ddc4af4dcb0c21132a5494b24049d41c19c
tree23f0fd7a9cf656e458ff9b88d72c8be2cbd49f87
parentc4936eee7a94ebe4caaa107591ca01a6b2f57491
power: fix error messages

Function strerror(errno) has built strings only for non-negative errno values.
for negative values of errno it describe error as "Unknown error -errno"
to be more descriptive i put string "channel not found" taken from header.

The negative argument will be interpreted as a very large unsigned value.

Coverity issue: 13266
Coverity issue: 13269
Fixes: 445c6528b55f ("power: common interface for guest and host")

Signed-off-by: Daniel Mrzyglod <danielx.t.mrzyglod@intel.com>
lib/librte_power/guest_channel.c
lib/librte_power/rte_power_kvm_vm.c