Search Linux Wireless

Re: [RFC/RFT] ssb: Avoid system hang when SPROM read fails

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

 



On Sun, Apr 25, 2010 at 05:30:28PM -0500, Larry Finger wrote:
> In kernel Bugzilla #15825, the OP reports a case of intermittent reading
> of the SPROM. If such reads fail, the box hangs. Thanks to careful testing
> by bugzillakernelorg@xxxxxxxxxx has shown that the first read of the
> SPROM returns 0xFFFF with the hang happening on the next read.
> 
> The source of the read failure is still under investigation; however,
> this patch does avoid the system hang.
> 
> Signed-off-by: Larry Finger <Larry.Finger@xxxxxxxxxxxx>
> ---
> 
> John,
> 
> Does this patch avoid the system hang on your box?
> 
> Larry
> ---
> 
> ===================================================================
> --- wireless-testing.orig/drivers/ssb/pci.c
> +++ wireless-testing/drivers/ssb/pci.c
> @@ -253,6 +253,11 @@ static int sprom_do_read(struct ssb_bus
>  {
>  	int i;
>  
> +	/* Check if SPROM can be read */
> +	if (ioread16(bus->mmio + SSB_SPROM_BASE) == 0xFFFF) {
> +		ssb_printk(KERN_ERR PFX "Unable to read SPROM\n");
> +		return -ENODEV;
> +	}
>  	for (i = 0; i < bus->sprom_size; i++)
>  		sprom[i] = ioread16(bus->mmio + SSB_SPROM_BASE + (i * 2));
>  

Well, the "good" news is that I hit the "Unable to read SPROM" case.
The bad news is that the box still hangs after the -ENODEV.  I have
not yet tracked-down the exact location of the current hang.

John

P.S.  Sorry about the 'radio silence' -- I've been distracted with
some other things.  Also, the box in question originally belonged
to someone else who had configured it in a way that was less than
friendly to kernel development.  I finally reinstalled it...
-- 
John W. Linville		Someday the world will need a hero, and you
linville@xxxxxxxxxxxxx			might be all we have.  Be ready.
--
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 Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux