13 #include <linux/export.h>
50 for (i = 0; i < 200; i++) {
70 if (pc->
core->id.rev >= 10) {
72 bcma_pcie_mdio_set_phy(pc, device);
88 for (i = 0; i < max_retries; i++) {
101 static void bcma_pcie_mdio_write(
struct bcma_drv_pci *pc,
u8 device,
104 int max_retries = 10;
113 if (pc->
core->id.rev >= 10) {
115 bcma_pcie_mdio_set_phy(pc, device);
131 for (i = 0; i < max_retries; i++) {
144 static u8 bcma_pcicore_polarity_workaround(
struct bcma_drv_pci *pc)
156 static void bcma_pcicore_serdes_workaround(
struct bcma_drv_pci *pc)
162 bcma_pcicore_polarity_workaround(pc));
168 tmp & ~BCMA_CORE_PCI_PLL_CTRL_FREQDET_EN);
171 static void bcma_core_pci_fixcfg(
struct bcma_drv_pci *pc)
184 (val16 & ~BCMA_CORE_PCI_SPROM_PI_MASK);
191 static void bcma_core_pci_config_fixup(
struct bcma_drv_pci *pc)
212 bcma_core_pci_fixcfg(pc);
213 bcma_pcicore_serdes_workaround(pc);
214 bcma_core_pci_config_fixup(pc);
222 #ifdef CONFIG_BCMA_DRIVER_PCI_HOSTMODE
229 bcma_core_pci_clientmode_init(pc);
246 pdev = pc->
core->bus->host_pci;