Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 247227
b: refs/heads/master
c: af335a6
h: refs/heads/master
i:
  247225: 8c9c349
  247223: 2078295
v: v3
  • Loading branch information
Rafał Miłecki authored and John W. Linville committed Apr 28, 2011
1 parent 6e34dc0 commit 5dc5576
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5890a3ca34aae94dd736557ad8cb898ac2802aa0
refs/heads/master: af335a6cbc3dfcba64ad31561c0da563d1c43a2d
12 changes: 12 additions & 0 deletions trunk/drivers/ssb/driver_pcicore.c
Original file line number Diff line number Diff line change
Expand Up @@ -414,6 +414,16 @@ static int pcicore_is_in_hostmode(struct ssb_pcicore *pc)
* Workarounds.
**************************************************/

static void ssb_pcicore_fix_sprom_core_index(struct ssb_pcicore *pc)
{
u16 tmp = pcicore_read16(pc, SSB_PCICORE_SPROM(0));
if (((tmp & 0xF000) >> 12) != pc->dev->core_index) {
tmp &= ~0xF000;
tmp |= (pc->dev->core_index << 12);
pcicore_write16(pc, SSB_PCICORE_SPROM(0), tmp);
}
}

static u8 ssb_pcicore_polarity_workaround(struct ssb_pcicore *pc)
{
return (ssb_pcie_read(pc, 0x204) & 0x10) ? 0xC0 : 0x80;
Expand Down Expand Up @@ -521,6 +531,8 @@ void ssb_pcicore_init(struct ssb_pcicore *pc)
if (!ssb_device_is_enabled(dev))
ssb_device_enable(dev, 0);

ssb_pcicore_fix_sprom_core_index(pc);

#ifdef CONFIG_SSB_PCICORE_HOSTMODE
pc->hostmode = pcicore_is_in_hostmode(pc);
if (pc->hostmode)
Expand Down

0 comments on commit 5dc5576

Please sign in to comment.