/* Print out which flash was booted from and if booting from the 2nd flash, swap flash chip selects to maintain consistent flash numbering/addresses.  */
static void flash_cs_fixup(void)
/* Print out which flash was booted from and if booting from the 2nd flash, swap flash chip selects to maintain consistent flash numbering/addresses.  */
static void flash_cs_fixup(void)
{
	int flash_sel;
	flash_sel = !((pca953x_get_val(CONFIG_SYS_I2C_PCA953X_ADDR0) &
			CONFIG_SYS_PCA953X_C0_FLASH_PASS_CS));
	printf("Flash: Executed from flash%d\n", flash_sel ? 2 : 1);
	if (flash_sel) {
		set_lbc_br(0, CONFIG_SYS_BR1_PRELIM);
		set_lbc_or(0, CONFIG_SYS_OR1_PRELIM);
		set_lbc_br(1, CONFIG_SYS_BR0_PRELIM);
		set_lbc_or(1, CONFIG_SYS_OR0_PRELIM);
	}
}