Texas Instruments cardbus bridge issue (PCI ID 104c:8031)
Vitaly Cherny
vitaly.cherny at gmail.com
Sun Oct 30 14:46:20 PST 2005
The work-around described below is a working solution for me. I've
tried plugging the 32-bit card into the slot, and it was picked up by
the kernel, which loaded the FreeBSD native Atheros drivers.
The card comes up, the kernel loads the right drivers, ifconfig ath0
scan shows nearby networks, and all the [ath|wlan]*.ko code works
great for me. Kernel messages further below. Other software (tcpdump
-i ath0 and packages out of the ports tree) works per documentation.
Thanks for your help, I sure owe you a beverage (;
On 10/29/05, M. Warner Losh <imp at bsdimp.com> wrote:
> I think that your problem is due to the way that FreeBSD numbers, or
> doesn't number PCI busses. You have the right symptom set: 16-bit
> cards work great, 32-bit cards not at all.
>
> Notice that the subordinate bus number == 5. There's no way to get
> the config cycles to the cardbus bus. FreeBSD needs to renumber the
> '5' there to some larger value The cbb bridge says:
>
> 0x10: 0xd0208000 0x020000a0 0x20070605 0xfffff000
>
> which says that the CardBus will be pci bus 6 and it can have 1 child
> pci bus 7.
>
> Try using pciconf to change pcib2's subordinate bus register to 7:
>
> pciconf -wb pci0:20:4 0x1a 7
After doing this, when I turn on the hw.[cbb|cardbus|pccard]*debug and
insert the card, I get the following kernel messages:
Status is 0x30000820
cbb0: card inserted: event=0x00000000, state=30000820
cardbus0: cardbus_attach_card, scan 1 slots
cardbus0: cardbus_detach_card
cbb0: cbb_cardbus_power_enable_socket ...
cbb0: cbb_power: 3V
cbb0: cbb_cardbus_reset entered ...
cbb0: will wail 20000us
cbb0: card present
TUPLE: LINKTARGET [3]: 43 49 53
Manufacturer ID: 71021200
TUPLE: Unknown(0x04) [6]: 03 01 00 00 00 00
TUPLE: Unknown(0x05) [14]: 41 b1 39 b5 1e 2d 4e 56 30 ff ff 02 e9 00
cardbus0: Opening BAR: type=MEM, bar=10, len=10000
CIS reading done
cardbus0: Non-prefetchable memory at d0210000-d021ffff
ath0: <Atheros 5212> mem 0xd0210000-0xd021ffff irq 17 at device 0.0 on cardbus0
ath0: Ethernet address: 00:11:95:ab:76:b4
ath0: mac 7.9 phy 4.5 radio 5.6
> This is, at best, a workaround until I can get the bus numbering code
> working. My laptops don't have this problem. Maybe I need to buy a
> new laptop. Maybe one with Express Card :-)
I'm happy to test your patches on my machine if that is helpful to you at all.
Regards,
Vitaly
More information about the freebsd-mobile
mailing list