On Mon, 27 Jan 2014, John Baldwin wrote:
> Author: jhb
> Date: Mon Jan 27 19:49:52 2014
> New Revision: 261216
> URL: http://svnweb.freebsd.org/changeset/base/261216
> 
> Log:
>   Explicitly enable I/O and memory decoding in the bridge's command register
>   when activating an I/O or memory window on the CardBus bridge.

This fixes some, but not all of my machines.  One in particular, a Toshiba 
M5 laptop, remains broken by r254263 even with this change.  Specificaly, 
the laptop does not notice when a card is inserted.

The attached minimal patch gets things working again, though I don't know 
if is the correct fix or if a more involved fix is required.

dmesg before and after that patch:

http://people.freebsd.org/~gavin/m5-dmesg-before.txt
http://people.freebsd.org/~gavin/m5-dmesg-after.txt

The only difference is the cbb register dump, the one bit that I am 
setting in the patch.

Thanks,

Gavin
Index: /usr/src/sys/dev/pccbb/pccbb_pci.c
===================================================================
--- /usr/src/sys/dev/pccbb/pccbb_pci.c  (revision 261352)
+++ /usr/src/sys/dev/pccbb/pccbb_pci.c  (working copy)
@@ -472,6 +472,7 @@
 
        /* Enable memory access */
        pci_enable_busmaster(sc->dev);
+       PCI_MASK_CONFIG(sc->dev, PCIR_COMMAND, | PCIM_CMD_PORTEN, 2);
 
        /* disable Legacy IO */
        switch (sc->chipset) {
_______________________________________________
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to