Re: [PATCH] staging: brcm80211: use kzalloc()

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

 



Signed-off-by: Thomas Meyer<thomas@xxxxxxxx>

Acked-by: Roland Vossen <rvossen@xxxxxxxxxxxx>

---

diff -u -p a/drivers/staging/brcm80211/brcmfmac/dhd_sdio.c b/drivers/staging/brcm80211/brcmfmac/dhd_sdio.c
--- a/drivers/staging/brcm80211/brcmfmac/dhd_sdio.c 2011-07-28 15:32:17.863253745 +0200
+++ b/drivers/staging/brcm80211/brcmfmac/dhd_sdio.c 2011-08-01 20:25:55.608031978 +0200
@@ -6326,14 +6326,12 @@ brcmf_sdbrcm_chip_attach(struct brcmf_bu
  	BRCMF_TRACE(("%s: Enter\n", __func__));

  	/* alloc chip_info_t */
-	ci = kmalloc(sizeof(struct chip_info), GFP_ATOMIC);
+	ci = kzalloc(sizeof(struct chip_info), GFP_ATOMIC);
  	if (NULL == ci) {
  		BRCMF_ERROR(("%s: malloc failed!\n", __func__));
  		return -ENOMEM;
  	}

-	memset((unsigned char *)ci, 0, sizeof(struct chip_info));
-
  	/* bus/core/clk setup for register access */
  	/* Try forcing SDIO core to do ALPAvail request only */
  	clkset = SBSDIO_FORCE_HW_CLKREQ_OFF | SBSDIO_ALP_AVAIL_REQ;



_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel



_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/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