projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7a09876
)
staging: hv: remove ASSERT() and return -EINVAL in NetVsc.c
author
Bill Pemberton
<wfp5p@virginia.edu>
Wed, 5 May 2010 19:27:56 +0000
(15:27 -0400)
committer
Greg Kroah-Hartman
<gregkh@suse.de>
Tue, 11 May 2010 18:36:15 +0000
(11:36 -0700)
return -EINVAL instead of calling ASSERT()
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
Cc: Hank Janssen <hjanssen@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/hv/NetVsc.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/staging/hv/NetVsc.c
b/drivers/staging/hv/NetVsc.c
index ddde39136b6ea92d9c5c8da06a068e238611a549..f852984950a808c7e8d33d96ace834243e4b329a 100644
(file)
--- a/
drivers/staging/hv/NetVsc.c
+++ b/
drivers/staging/hv/NetVsc.c
@@
-354,7
+354,11
@@
static int NetVscInitializeSendBufferWithNetVsp(struct hv_device *Device)
DPRINT_EXIT(NETVSC);
return -1;
}
- ASSERT(netDevice->SendBufferSize > 0);
+ if (netDevice->SendBufferSize <= 0) {
+ ret = -EINVAL;
+ goto Cleanup;
+ }
+
/* page-size grandularity */
/* ASSERT((netDevice->SendBufferSize & (PAGE_SIZE - 1)) == 0); */