[PATCH 21/21] staging: brcm80211: remove usage of struct osl_info from util sources

Arend van Spriel arend at broadcom.com
Fri Feb 25 14:20:01 UTC 2011


On Fri, 25 Feb 2011 14:17:03 +0100, Dan Carpenter <error27 at gmail.com>  
wrote:

> On Fri, Feb 25, 2011 at 11:31:40AM +0100, Arend van Spriel wrote:
>> Most of the util source files do not need the osl_info anymore due
>> to previous patches so usage of it has been removed.
>>
>> @@ -1907,15 +1901,17 @@ static int initvars_srom_pci(si_t *sih, void  
>> *curmap, char **vars, uint *count)
>>  	}
>>  #if defined(BCMNVRAMR)
>>  	/* Use OTP if SPROM not available */
>> -	else if ((err = otp_read_pci(osh, sih, srom, SROM_MAX)) == 0) {
>> -		/* OTP only contain SROM rev8/rev9 for now */
>> -		sromrev = srom[SROM4_CRCREV] & 0xff;
>> -	}
>> -#endif
>>  	else {
>> -		err = 1;
>> -		BS_ERROR(("Neither SPROM nor OTP has valid image\n"));
>> +		err = otp_read_pci(sih, srom, SROM_MAX);
>> +		if (err == 0)
>> +			/* OTP only contain SROM rev8/rev9 for now */
>> +			sromrev = srom[SROM4_CRCREV] & 0xff;
>> +		else {
>> +			err = 1;
>> +			BS_ERROR(("Neither SPROM nor OTP has valid image\n"));
>> +		}
>>  	}
>> +#endif
>
> In the original code, if si_is_sprom_available() returns false and
> BCMNVRAMR is not defined, then err is set to 1, but in the new code
> it's 0.
>
>
> regards,
> dan carpenter
>
Hmmm,

Given the dependencies of these patches I probably should resend the whole  
series.

Gr. AvS
-- 
"The most merciful thing in the world, I think, is the inability of the  
human
mind to correlate all its contents." - "The Call of Cthulhu"




More information about the devel mailing list