[patch 4/6] staging: gdm72xx: zero out padding

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



We pad the start of this buffer with 256 bytes of padding.   It's not
clear to me exactly what's going on or how it's used but let's zero it
out.

Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>

diff --git a/drivers/staging/gdm72xx/usb_boot.c b/drivers/staging/gdm72xx/usb_boot.c
index 3082987..4431a80 100644
--- a/drivers/staging/gdm72xx/usb_boot.c
+++ b/drivers/staging/gdm72xx/usb_boot.c
@@ -286,7 +286,7 @@ static int em_download_image(struct usb_device *usbdev, const char *img_name,
 		return ret;
 	}
 
-	buf = kmalloc(DOWNLOAD_CHUCK + pad_size, GFP_KERNEL);
+	buf = kzalloc(DOWNLOAD_CHUCK + pad_size, GFP_KERNEL);
 	if (!buf) {
 		release_firmware(firm);
 		return -ENOMEM;
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux