debug("%s@%d: \n", __func__, __LINE__);
-// i2c_init_all();
-
for (i = 0; i < ARRAY_SIZE(tx6_mod_revs); i++) {
u8 i2c_addr = tx6_mod_revs[i].addr;
int ret = i2c_probe(i2c_addr);
debug("%s@%d: \n", __func__, __LINE__);
pmic_id = tx6_pmic_probe();
- if (pmic_id >= 0)
+ if (pmic_id >= 0 && pmic_id < ARRAY_SIZE(tx6_mod_revs))
pmic_addr = tx6_mod_revs[pmic_id].addr;
printf("Board: Ka-Ro TX6%s-%d%d%d%c\n",
return 0;
}
- ret = tx6_pmic_init(pmic_addr);
+ ret = tx6_pmic_init(pmic_addr, NULL, 0);
if (ret) {
printf("Failed to setup PMIC voltages: %d\n", ret);
hang();
};
#ifdef CONFIG_LCD
-static u16 tx6_cmap[256];
vidinfo_t panel_info = {
/* set to max. size supported by SoC */
.vl_col = 1920,
.vl_row = 1080,
.vl_bpix = LCD_COLOR32, /* Bits per pixel, 0: 1bpp, 1: 2bpp, 2: 4bpp, 3: 8bpp ... */
- .cmap = tx6_cmap,
};
static struct fb_videomode tx6_fb_modes[] = {
{
int ret = 0;
const char *baseboard;
-#if 1
- /* override secure_boot fuse */
- struct ocotp_regs *ocotp = (struct ocotp_regs *)OCOTP_BASE_ADDR;
- struct fuse_bank0_regs *fuse = (void *)ocotp->bank[0].fuse_regs;
-
- writel(0x12, &fuse->cfg5);
-#endif
debug("%s@%d: \n", __func__, __LINE__);