xenbus: avoid uninitialized variable warning
PATCH 1/1 xenbus: avoid uninitialized variable warning
Older compilers don't recognize that "v" can't be used uninitialized; other code using hvm_get_parameter() zeros the value too, so follow suit here.
Signed-off-by Jan Beulich <[email protected]>
--- drivers/xen/xenbus/xenbus_probe.c | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-)
drivers/xen/xenbus/xenbus_probe.c +1 -1
@@ -742,7 +742,7 @@ static int xenbus_resume_cb(struct notifint err =0 ;if (xen_hvm_domain ()) { -uint64_t v; +uint64_t v =0 ; err =hvm_get_parameter (HVM_PARAM_STORE_EVTCHN , &v);if (!err && v)
David Vrabel
AppliedQuoted 3 lines · Jan Beulich
Older compilers don't recognize that "v" can't be used uninitialized; other code using
hvm_get_parameter()zeros the value too, so follow suit here.
Applied to for-linus-4.2, thanks.
David