summaryrefslogtreecommitdiffstats
path: root/drivers/staging/hv/hv.c
diff options
context:
space:
mode:
authorK. Y. Srinivasan2011-06-07 00:50:09 +0200
committerGreg Kroah-Hartman2011-06-07 22:46:06 +0200
commit39594abcd47da2f587804dff2fedbd7ada4670d0 (patch)
tree0546cd24c6afb0e375df301504e91e43a7506107 /drivers/staging/hv/hv.c
parentStaging: hv: vmbus: Cleanup error handling in vmbus_bus_init() (diff)
downloadkernel-qcow2-linux-39594abcd47da2f587804dff2fedbd7ada4670d0.tar.gz
kernel-qcow2-linux-39594abcd47da2f587804dff2fedbd7ada4670d0.tar.xz
kernel-qcow2-linux-39594abcd47da2f587804dff2fedbd7ada4670d0.zip
Staging: hv: vmbus: Cleanup error codes in hv.c
Cleanup error codes in hv.c. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Abhishek Kane <v-abkane@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/hv/hv.c')
-rw-r--r--drivers/staging/hv/hv.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/hv/hv.c b/drivers/staging/hv/hv.c
index a2cc0911de58..824f81679ae8 100644
--- a/drivers/staging/hv/hv.c
+++ b/drivers/staging/hv/hv.c
@@ -277,11 +277,11 @@ u16 hv_post_message(union hv_connection_id connection_id,
unsigned long addr;
if (payload_size > HV_MESSAGE_PAYLOAD_BYTE_COUNT)
- return -1;
+ return -EMSGSIZE;
addr = (unsigned long)kmalloc(sizeof(struct aligned_input), GFP_ATOMIC);
if (!addr)
- return -1;
+ return -ENOMEM;
aligned_msg = (struct hv_input_post_message *)
(ALIGN(addr, HV_HYPERCALL_PARAM_ALIGN));