Changeset 1445
- Timestamp:
- 09/17/11 23:21:42 (8 months ago)
- File:
-
- 1 edited
-
trunk/ichspi.c (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ichspi.c
r1444 r1445 571 571 * it didn't stick. 572 572 */ 573 static void ich_set_bbar( uint32_t min_addr)573 static void ich_set_bbar(int ich_generation, uint32_t min_addr) 574 574 { 575 575 int bbar_off; 576 switch (spi_programmer->type) { 577 case SPI_CONTROLLER_ICH7: 578 case SPI_CONTROLLER_VIA: 576 switch (ich_generation) { 577 case 7: 579 578 bbar_off = 0x50; 580 579 break; 581 case SPI_CONTROLLER_ICH9: 580 case 8: 581 msg_perr("BBAR offset is unknown on ICH8!\n"); 582 return; 583 default: /* Future version might behave the same */ 582 584 bbar_off = ICH9_REG_BBAR; 583 585 break; 584 default:585 msg_perr("Unknown chipset for BBAR setting!\n");586 return;587 586 } 588 587 … … 601 600 */ 602 601 if (ichspi_bbar != min_addr) 603 msg_perr("Setting BBAR failed!\n"); 602 msg_perr("Setting BBAR to 0x%08x failed! New value: 0x%08x.\n", 603 min_addr, ichspi_bbar); 604 604 } 605 605 … … 670 670 curopcodes_done = &O_ST_M25P; 671 671 rc = program_opcodes(curopcodes_done, 1); 672 /* Technically not part of opcode init, but it allows opcodes673 * to run without transaction errors by setting the lowest674 * allowed address to zero.675 */676 ich_set_bbar(0);677 672 } 678 673 … … 1271 1266 ichspi_lock = 1; 1272 1267 } 1268 ich_set_bbar(ich_generation, 0); 1273 1269 ich_init_opcodes(); 1274 1270 break; … … 1352 1348 tmp = mmio_readl(ich_spibar + ICH9_REG_FPB); 1353 1349 msg_pdbg("0xD0: 0x%08x (FPB)\n", tmp); 1350 ich_set_bbar(ich_generation, 0); 1354 1351 } 1355 1352 … … 1440 1437 } 1441 1438 1439 ich_set_bbar(7, 0); 1442 1440 ich_init_opcodes(); 1443 1441
Note: See TracChangeset
for help on using the changeset viewer.
