Staging: hv: remove MIN and MAX usages
The kernel has the "correct" min() and max() functions, so use those.
Cc: Hank Janssen <hjanssen@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
diff --git a/drivers/staging/hv/storvsc_drv.c b/drivers/staging/hv/storvsc_drv.c
index 1a05134..3547c03 100644
--- a/drivers/staging/hv/storvsc_drv.c
+++ b/drivers/staging/hv/storvsc_drv.c
@@ -623,7 +623,7 @@
dest = bounce_addr + bounce_sgl[j].length;
destlen = PAGE_SIZE - bounce_sgl[j].length;
- copylen = MIN(srclen, destlen);
+ copylen = min(srclen, destlen);
memcpy((void*)dest, (void*)src, copylen);
total_copied += copylen;
@@ -698,7 +698,7 @@
src = bounce_addr + bounce_sgl[j].offset;
srclen = bounce_sgl[j].length - bounce_sgl[j].offset;
- copylen = MIN(srclen, destlen);
+ copylen = min(srclen, destlen);
memcpy((void*)dest, (void*)src, copylen);
total_copied += copylen;