Lines Matching defs:cc
74 static void bcma_sflash_cmd(struct bcma_drv_cc *cc, u32 opcode)
77 bcma_cc_write32(cc, BCMA_CC_FLASHCTL,
80 if (!(bcma_cc_read32(cc, BCMA_CC_FLASHCTL) &
85 bcma_err(cc->core->bus, "SFLASH control command failed (timeout)!\n");
89 int bcma_sflash_init(struct bcma_drv_cc *cc)
91 struct bcma_bus *bus = cc->core->bus;
92 struct bcma_sflash *sflash = &cc->sflash;
96 switch (cc->capabilities & BCMA_CC_CAP_FLASHT) {
98 bcma_sflash_cmd(cc, BCMA_CC_FLASHCTL_ST_DP);
100 bcma_cc_write32(cc, BCMA_CC_FLASHADDR, 0);
101 bcma_sflash_cmd(cc, BCMA_CC_FLASHCTL_ST_RES);
102 id = bcma_cc_read32(cc, BCMA_CC_FLASHDATA);
104 bcma_cc_write32(cc, BCMA_CC_FLASHADDR, 1);
105 bcma_sflash_cmd(cc, BCMA_CC_FLASHCTL_ST_RES);
106 id2 = bcma_cc_read32(cc, BCMA_CC_FLASHDATA);
131 bcma_sflash_cmd(cc, BCMA_CC_FLASHCTL_AT_STATUS);
132 id = bcma_cc_read32(cc, BCMA_CC_FLASHDATA) & 0x3c;