Search Linux Wireless

Re: [PATCH] brcm80211: Initialize a variable before used.

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

 



Thanks Il. Removing the declaration and assignment line of val seems to be better since it's not used afterward. Do you want to send out a V2? Or I can do it.

Thanks,
Franky

On 05/07/2012 12:23 PM, Il Han wrote:
The variable val is used uninitialized.
It should be initialized before used.
Initialize it.

Signed-off-by: Il Han<corone.il.han@xxxxxxxxx>
---
  drivers/net/wireless/brcm80211/brcmsmac/aiutils.c |    2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/brcm80211/brcmsmac/aiutils.c b/drivers/net/wireless/brcm80211/brcmsmac/aiutils.c
index c93ea35..d67c5c4 100644
--- a/drivers/net/wireless/brcm80211/brcmsmac/aiutils.c
+++ b/drivers/net/wireless/brcm80211/brcmsmac/aiutils.c
@@ -1141,7 +1141,7 @@ u32 ai_gpiocontrol(struct si_pub *sih, u32 mask, u32 val, u8 priority)
  void ai_chipcontrl_epa4331(struct si_pub *sih, bool on)
  {
  	struct bcma_device *cc;
-	u32 val;
+	u32 val = 0;

  	cc = ai_findcore(sih, CC_CORE_ID, 0);



--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux