From 558710fce12b8f87c85311190ff5c12f72982576 Mon Sep 17 00:00:00 2001 From: yongari Date: Wed, 10 Oct 2012 02:35:10 +0000 Subject: Do not force PCIe 1.0a mode in device reset on BCM5717 and newer controllers. BCM5785 does not require PCI 1.0a mode as well during reset. --- sys/dev/bge/if_bge.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'sys/dev/bge') diff --git a/sys/dev/bge/if_bge.c b/sys/dev/bge/if_bge.c index 8989059..bfa0769 100644 --- a/sys/dev/bge/if_bge.c +++ b/sys/dev/bge/if_bge.c @@ -3604,8 +3604,11 @@ bge_reset(struct bge_softc *sc) /* XXX: Broadcom Linux driver. */ if (sc->bge_flags & BGE_FLAG_PCIE) { - if (CSR_READ_4(sc, 0x7E2C) == 0x60) /* PCIE 1.0 */ - CSR_WRITE_4(sc, 0x7E2C, 0x20); + if (sc->bge_asicrev != BGE_ASICREV_BCM5785 && + (sc->bge_flags & BGE_FLAG_5717_PLUS) == 0) { + if (CSR_READ_4(sc, 0x7E2C) == 0x60) /* PCIE 1.0 */ + CSR_WRITE_4(sc, 0x7E2C, 0x20); + } if (sc->bge_chipid != BGE_CHIPID_BCM5750_A0) { /* Prevent PCIE link training during global reset */ CSR_WRITE_4(sc, BGE_MISC_CFG, 1 << 29); -- cgit v1.1