static void chipdisablepme(struct bcm4xxx *ch) { bcmenetregs_t *regs; regs = ch->regs; AND_REG(ch->osh, ®s->devcontrol, ~DC_PM); si_core_cflags(ch->sih, SICF_PME_EN, 0); }
static void chipenablepme(struct bcm4xxx *ch) { bcmenetregs_t *regs; regs = ch->regs; /* enable chip wakeup pattern matching */ OR_REG(ch->osh, ®s->devcontrol, DC_PM); /* enable sonics bus PME */ si_core_cflags(ch->sih, SICF_PME_EN, SICF_PME_EN); }
/* Run bist on current core. Caller needs to take care of core-specific bist hazards */ int si_corebist(si_t *sih) { uint32 cflags; int result = 0; /* Read core control flags */ cflags = si_core_cflags(sih, 0, 0); /* Set bist & fgc */ si_core_cflags(sih, 0, (SICF_BIST_EN | SICF_FGC)); /* Wait for bist done */ SPINWAIT(((si_core_sflags(sih, 0, 0) & SISF_BIST_DONE) == 0), 100000); if (si_core_sflags(sih, 0, 0) & SISF_BIST_ERROR) result = BCME_ERROR; /* Reset core control flags */ si_core_cflags(sih, 0xffff, cflags); return result; }