From: K. Y. Srinivasan Date: Thu, 25 Aug 2011 16:48:51 +0000 (-0700) Subject: Staging: hv: vmbus: Cleanup error handling in hv_init() X-Git-Tag: MMI-PSA29.97-13-9~18234^2^2~864^2~66 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5433e00334d3e20f8bff70845c7f44e00cdf2d14;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git Staging: hv: vmbus: Cleanup error handling in hv_init() Use standard Linux error codes. Signed-off-by: K. Y. Srinivasan Signed-off-by: Haiyang Zhang Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/hv/hv.c b/drivers/staging/hv/hv.c index d2b921bd7652..736794ef7872 100644 --- a/drivers/staging/hv/hv.c +++ b/drivers/staging/hv/hv.c @@ -151,7 +151,6 @@ static u64 do_hypercall(u64 control, void *input, void *output) */ int hv_init(void) { - int ret = 0; int max_leaf; union hv_x64_msr_hypercall_contents hypercall_msr; void *virtaddr = NULL; @@ -214,7 +213,7 @@ int hv_init(void) hv_context.signal_event_param->flag_number = 0; hv_context.signal_event_param->rsvdz = 0; - return ret; + return 0; cleanup: if (virtaddr) { @@ -225,8 +224,8 @@ cleanup: vfree(virtaddr); } - ret = -1; - return ret; + + return -ENOTSUPP; } /*