Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 278938
b: refs/heads/master
c: d3126c5
h: refs/heads/master
v: v3
  • Loading branch information
Arend van Spriel authored and John W. Linville committed Dec 13, 2011
1 parent f439f44 commit fb694b9
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: dd5f13b8a4b5f86e645e7e6662075004d116d5ad
refs/heads/master: d3126c52eb7f3239b45481facc4078b08ed1027c
14 changes: 7 additions & 7 deletions trunk/drivers/net/wireless/brcm80211/brcmsmac/aiutils.c
Original file line number Diff line number Diff line change
Expand Up @@ -884,7 +884,7 @@ uint ai_coreidx(struct si_pub *sih)
}

/* return index of coreid or BADIDX if not found */
uint ai_findcoreidx(struct si_pub *sih, uint coreid, uint coreunit)
struct bcma_device *ai_findcore(struct si_pub *sih, u16 coreid, u16 coreunit)
{
struct bcma_device *core;
struct si_info *sii;
Expand All @@ -897,11 +897,11 @@ uint ai_findcoreidx(struct si_pub *sih, uint coreid, uint coreunit)
list_for_each_entry(core, &sii->icbus->cores, list)
if (core->id.id == coreid) {
if (found == coreunit)
return core->core_index;
return core;
found++;
}

return BADIDX;
return NULL;
}

/*
Expand All @@ -912,13 +912,13 @@ uint ai_findcoreidx(struct si_pub *sih, uint coreid, uint coreunit)
*/
void __iomem *ai_setcore(struct si_pub *sih, uint coreid, uint coreunit)
{
uint idx;
struct bcma_device *core;

idx = ai_findcoreidx(sih, coreid, coreunit);
if (idx >= SI_MAXCORES)
core = ai_findcore(sih, coreid, coreunit);
if (core == NULL)
return NULL;

return ai_setcoreidx(sih, idx);
return ai_setcoreidx(sih, core->core_index);
}

/* Turn off interrupt as required by ai_setcore, before switch core */
Expand Down
2 changes: 2 additions & 0 deletions trunk/drivers/net/wireless/brcm80211/brcmsmac/aiutils.h
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,8 @@ struct si_info {


/* AMBA Interconnect exported externs */
extern struct bcma_device *ai_findcore(struct si_pub *sih,
u16 coreid, u16 coreunit);
extern uint ai_coreidx(struct si_pub *sih);
extern uint ai_corerev(struct si_pub *sih);
extern u32 ai_core_cflags(struct bcma_device *core, u32 mask, u32 val);
Expand Down

0 comments on commit fb694b9

Please sign in to comment.