On 11/16/2009 02:21 AM, Oncaphillis wrote:
> On 11/16/2009 04:02 AM, Peter Stuge wrote:
>> Oncaphillis wrote:
>>> I poked around in the sbb code and found that ssb_do_read never
>>> returns:
>>>
>>> <snip>
>>> static int sprom_do_read(struct ssb_bus *bus, u16 *sprom)
>>
>> You wrote ssb_do_read above, this is sprom_do_read. Maybe they call
>> each other?
> 
> No I meant sprom_do_read... It was late yesterday
> 
>>
>>
>>> So I guess the mmio address is wrong. It is set to decimal
>>> -133791744 when it freezes. I don't know if that's a valid mmio
>>> address but it seems fishy.
>>
>> $ printf %x\\n -133791744 | sed 'sx.*\(.\{8\}\)x\1x'
>> f8068000
>>
>> Basically looks ok, but..
>>
>>
>>> 01:00.0 Network controller [0280]: Broadcom Corporation BCM4312 802.11b/g 
>>> [14e4:4315] (rev 01)
>> ..
>>>           Region 0: Memory at 57100000 (64-bit, non-prefetchable) [size=16K]
>>
>> It should be closer to this region.
> 
> That was my assumption too although I'm definitely not an expert on
> hardware IO and address space mapping and all of this

It should match. For instance, on my system, 'lspci -nnv' returns

04:00.0 Network controller [0280]: Broadcom Corporation BCM4312 802.11b/g
[14e4:4315] (rev 01)
        Subsystem: Hewlett-Packard Company BCM4312 802.11b/g Wireless LAN
Controller [103c:137c]
        Flags: bus master, fast devsel, latency 0, IRQ 20
        Memory at fc000000 (64-bit, non-prefetchable) [size=16K]

and when I run mmio dumps for b43, all the traced addresses are at 0xfc00XXXX.

I agree that the negative decimal converts to 0xF8068000. Could you please rerun
the test with the routine changed to

static int sprom_do_read(struct ssb_bus *bus, u16 *sprom)
{
        printk(KERN_INFO "In sprom_do_read with sprom address 0x%X\n",
                bus->mmio+SSB_SPROM_BASE);
        return 1;
}

The logic that reads the SPROM will fail, but it should not freeze the computer.

After you run the above, please post your dmesg output to see where the kernel
thinks memory should be and the output from the revised sprom_do_read().

Larry
_______________________________________________
Bcm43xx-dev mailing list
Bcm43xx-dev@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/bcm43xx-dev

Reply via email to