1 --- a/drivers/ssb/driver_pcicore.c
2 +++ b/drivers/ssb/driver_pcicore.c
3 @@ -476,30 +476,6 @@ static void ssb_pcie_mdio_write(struct s
4 pcicore_write32(pc, mdio_control, 0);
7 -static void ssb_broadcast_value(struct ssb_device *dev,
8 - u32 address, u32 data)
10 - /* This is used for both, PCI and ChipCommon core, so be careful. */
11 - BUILD_BUG_ON(SSB_PCICORE_BCAST_ADDR != SSB_CHIPCO_BCAST_ADDR);
12 - BUILD_BUG_ON(SSB_PCICORE_BCAST_DATA != SSB_CHIPCO_BCAST_DATA);
14 - ssb_write32(dev, SSB_PCICORE_BCAST_ADDR, address);
15 - ssb_read32(dev, SSB_PCICORE_BCAST_ADDR); /* flush */
16 - ssb_write32(dev, SSB_PCICORE_BCAST_DATA, data);
17 - ssb_read32(dev, SSB_PCICORE_BCAST_DATA); /* flush */
20 -static void ssb_commit_settings(struct ssb_bus *bus)
22 - struct ssb_device *dev;
24 - dev = bus->chipco.dev ? bus->chipco.dev : bus->pcicore.dev;
27 - /* This forces an update of the cached registers. */
28 - ssb_broadcast_value(dev, 0xFD8, 0);
31 int ssb_pcicore_dev_irqvecs_enable(struct ssb_pcicore *pc,
32 struct ssb_device *dev)
34 --- a/drivers/ssb/main.c
35 +++ b/drivers/ssb/main.c
36 @@ -1406,6 +1406,31 @@ error:
38 EXPORT_SYMBOL(ssb_bus_powerup);
40 +static void ssb_broadcast_value(struct ssb_device *dev,
41 + u32 address, u32 data)
43 + /* This is used for both, PCI and ChipCommon core, so be careful. */
44 + BUILD_BUG_ON(SSB_PCICORE_BCAST_ADDR != SSB_CHIPCO_BCAST_ADDR);
45 + BUILD_BUG_ON(SSB_PCICORE_BCAST_DATA != SSB_CHIPCO_BCAST_DATA);
47 + ssb_write32(dev, SSB_PCICORE_BCAST_ADDR, address);
48 + ssb_read32(dev, SSB_PCICORE_BCAST_ADDR); /* flush */
49 + ssb_write32(dev, SSB_PCICORE_BCAST_DATA, data);
50 + ssb_read32(dev, SSB_PCICORE_BCAST_DATA); /* flush */
53 +void ssb_commit_settings(struct ssb_bus *bus)
55 + struct ssb_device *dev;
57 + dev = bus->chipco.dev ? bus->chipco.dev : bus->pcicore.dev;
60 + /* This forces an update of the cached registers. */
61 + ssb_broadcast_value(dev, 0xFD8, 0);
63 +EXPORT_SYMBOL(ssb_commit_settings);
65 u32 ssb_admatch_base(u32 adm)
68 --- a/include/linux/ssb/ssb.h
69 +++ b/include/linux/ssb/ssb.h
70 @@ -675,6 +675,7 @@ extern int ssb_bus_may_powerdown(struct
71 * Otherwise static always-on powercontrol will be used. */
72 extern int ssb_bus_powerup(struct ssb_bus *bus, bool dynamic_pctl);
74 +extern void ssb_commit_settings(struct ssb_bus *bus);
76 /* Various helper functions */
77 extern u32 ssb_admatch_base(u32 adm);