[U-Boot] [PATCH 10/13 v5] ARM: OMAP3: Add BeagleBoard
Jean-Christophe PLAGNIOL-VILLARD
plagnioj at jcrosoft.com
Sun Nov 9 15:57:05 CET 2008
> + * Description: Early hardware init.
> + *****************************************************************************/
> +int board_init(void)
> +{
> + DECLARE_GLOBAL_DATA_PTR;
> +
> + gpmc_init(); /* in SRAM or SDRAM, finish GPMC */
> + /* board id for Linux */
> + gd->bd->bi_arch_number = MACH_TYPE_OMAP3_BEAGLE;
> + /* boot param addr */
> + gd->bd->bi_boot_params = (OMAP34XX_SDRC_CS0 + 0x100);
> +
> + return 0;
> +}
> +
> +/******************************************************************************
> + * Routine: misc_init_r
> + * Description: Init ethernet (done here so udelay works)
> + *****************************************************************************/
> +int misc_init_r(void)
> +{
> +
> + unsigned char byte;
> +
> +#ifdef CONFIG_DRIVER_OMAP34XX_I2C
> + i2c_init(CONFIG_SYS_I2C_SPEED, CONFIG_SYS_I2C_SLAVE);
> +#endif
> + /* set vaux3 to 2.8V */
> + byte = 0x20;
> + i2c_write(0x4B, 0x7A, 1, &byte, 1);
> + byte = 0x03;
> + i2c_write(0x4B, 0x7D, 1, &byte, 1);
> +
> + /* set vpll2 to 1.8V */
> + byte = 0xE0;
> + i2c_write(0x4B, 0x8E, 1, &byte, 1);
> + byte = 0x05;
> + i2c_write(0x4B, 0x91, 1, &byte, 1);
> +
> + /* set VDAC to 1.8V */
> + byte = 0x20;
> + i2c_write(0x4B, 0x96, 1, &byte, 1);
> + byte = 0x03;
> + i2c_write(0x4B, 0x99, 1, &byte, 1);
> +
> + byte = 0x33;
> + i2c_write(0x4A, 0xEE, 1, &byte, 1);
please a comment to explain what you do by I2C
Best Reagers,
J.
More information about the U-Boot
mailing list