예제 #1
0
static void mainboard_init(device_t dev)
{
	soc_configure_pads(padcfgs, ARRAY_SIZE(padcfgs));
	soc_configure_funits(funitcfgs, ARRAY_SIZE(funitcfgs));

	setup_ec_spi();
	setup_usb();

	setup_audio();
	i2c_init(I2C1_BUS);		/* for max98090 codec */
}
예제 #2
0
static void mainboard_init(device_t dev)
{
    set_clock_sources();

    clock_external_output(1); /* For external MAX98090 audio codec. */

    /*
     * Confirmed by NVIDIA hardware team, we need to take ALL audio devices
     * conntected to AHUB (AUDIO, APBIF, I2S, DAM, AMX, ADX, SPDIF, AFC) out
     * of reset and clock-enabled, otherwise reading AHUB devices (In our
     * case, I2S/APBIF/AUDIO<XBAR>) will hang.
     *
     * Note that CLK_H_MEM (MC) and CLK_H_EMC should be already either
     * initialized by BootROM, or in romstage SDRAM initialization.
     */
    clock_enable_clear_reset(CLK_L_GPIO | CLK_L_I2C1 | CLK_L_SDMMC4 |
                             CLK_L_I2S0 | CLK_L_I2S1 | CLK_L_I2S2 |
                             CLK_L_SPDIF | CLK_L_USBD | CLK_L_DISP1 |
                             CLK_L_HOST1X | CLK_L_PWM,

                             CLK_H_I2C2 | CLK_H_PMC | CLK_H_USB3,

                             CLK_U_CSITE | CLK_U_SDMMC3,

                             CLK_V_I2C4 | CLK_V_EXTPERIPH1 | CLK_V_APBIF |
                             CLK_V_AUDIO | CLK_V_I2S3 | CLK_V_I2S4 |
                             CLK_V_DAM0 | CLK_V_DAM1 | CLK_V_DAM2,

                             CLK_W_DVFS | CLK_W_AMX0 | CLK_W_ADX0,

                             CLK_X_DPAUX | CLK_X_SOR0 | CLK_X_AMX1 |
                             CLK_X_ADX1 | CLK_X_AFC0 | CLK_X_AFC1 |
                             CLK_X_AFC2 | CLK_X_AFC3 | CLK_X_AFC4 |
                             CLK_X_AFC5);

    usb_setup_utmip((void*)TEGRA_USBD_BASE);
    /* USB2 is the camera, we don't need it in firmware */
    usb_setup_utmip((void*)TEGRA_USB3_BASE);

    setup_pinmux();

    i2c_init(0);
    i2c_init(1);
    i2c_init(3);

    setup_kernel_info();
    clock_init_arm_generic_timer();
    setup_ec_spi();
#if CONFIG_ELOG
    elog_init();
    elog_add_boot_reason();
#endif
}
예제 #3
0
static void mainboard_init(device_t dev)
{
	set_clock_sources();

	clock_external_output(1); /* For external MAX98090 audio codec. */

	/*
	 * Confirmed by NVIDIA hardware team, we need to take ALL audio devices
	 * conntected to AHUB (AUDIO, APBIF, I2S, DAM, AMX, ADX, SPDIF, AFC) out
	 * of reset and clock-enabled, otherwise reading AHUB devices (In our
	 * case, I2S/APBIF/AUDIO<XBAR>) will hang.
	 */
	clock_enable_clear_reset(CLK_L_GPIO | CLK_L_I2C1 | CLK_L_SDMMC4 |
				 CLK_L_I2S0 | CLK_L_I2S1 | CLK_L_I2S2 |
				 CLK_L_SPDIF | CLK_L_USBD | CLK_L_DISP1 |
				 CLK_L_HOST1X | CLK_L_PWM,

				 CLK_H_EMC | CLK_H_I2C2 | CLK_H_PMC |
				 CLK_H_MEM | CLK_H_USB2 | CLK_H_USB3,

				 CLK_U_CSITE | CLK_U_SDMMC3,

				 CLK_V_I2C4 | CLK_V_EXTPERIPH1 | CLK_V_APBIF |
				 CLK_V_AUDIO | CLK_V_I2S3 | CLK_V_I2S4 |
				 CLK_V_DAM0 | CLK_V_DAM1 | CLK_V_DAM2,

				 CLK_W_DVFS | CLK_W_AMX0 | CLK_W_ADX0,

				 CLK_X_DPAUX | CLK_X_SOR0 | CLK_X_AMX1 |
				 CLK_X_ADX1 | CLK_X_AFC0 | CLK_X_AFC1 |
				 CLK_X_AFC2 | CLK_X_AFC3 | CLK_X_AFC4 |
				 CLK_X_AFC5);

	usb_setup_utmip((void*)TEGRA_USBD_BASE);
	usb_setup_utmip((void*)TEGRA_USB2_BASE);
	usb_setup_utmip((void*)TEGRA_USB3_BASE);

	setup_pinmux();

	i2c_init(0);
	i2c_init(1);
	i2c_init(3);

	setup_kernel_info();
	clock_init_arm_generic_timer();
	setup_ec_spi();
}