Search Linux Wireless

Re: [PATCH 08/34] brcmfmac: Fix uninitialised variable

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

 



On 07/08/17 12:26, Arend van Spriel wrote:
> On 7/26/2017 10:25 PM, Ian Molton wrote:
>>     Unlikely to be a problem, but brcmf_sdiod_regrb() is
>> not symmetric with brcmf_sdiod_regrl() in this regard.
> 
> You are pretty keen on symmetry, but you could also remove the
> initialization in brcmf_sdiod_regrl(). As long as no -Wunitialized pops
> up that would have my preference.

Whilst the compiler does not complain, there are paths through
brcmf_sdiod_reg_read() that do not set *data, so I think it best to
initialise the value, but its not really very important. Code that isn't
checking the return value is asking for it anyway :)

In the later patches we could remove the initialisation, as IIRC the
Linux MMC IO functions do it for us and we don't avoid calling them in
that version of the code.

-Ian



[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