Paul Menzel has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/34773 )
Change subject: soc/mediatek: dsi: Support sending MIPI init commands ......................................................................
Patch Set 11:
(8 comments)
https://review.coreboot.org/c/coreboot/+/34773/11/src/soc/mediatek/common/ds... File src/soc/mediatek/common/dsi.c:
https://review.coreboot.org/c/coreboot/+/34773/11/src/soc/mediatek/common/ds... PS11, Line 271: while (read32(&dsi0->dsi_intsta) & (1 << 31)) { 1u
https://review.coreboot.org/c/coreboot/+/34773/11/src/soc/mediatek/common/ds... PS11, Line 272: printk(BIOS_ERR, "%s wait dsi no busy\n", __func__); Please use more elaborate error messages.
https://review.coreboot.org/c/coreboot/+/34773/11/src/soc/mediatek/common/ds... PS11, Line 273: mdelay(20); 20 ms is quite a lot. Why that much?
Already use the stopwatch here?
https://review.coreboot.org/c/coreboot/+/34773/11/src/soc/mediatek/common/ds... PS11, Line 274: } Should their be an abort condition after a certain time to avoid an infinite loop?
https://review.coreboot.org/c/coreboot/+/34773/11/src/soc/mediatek/common/ds... PS11, Line 312: if (intsta_0 & CMD_DONE_INT_FLAG) The negative could be moved in the while condition.
https://review.coreboot.org/c/coreboot/+/34773/11/src/soc/mediatek/common/ds... PS11, Line 315: } while (!stopwatch_expired(&sw)); Please print out as a debug message, how long it took.
https://review.coreboot.org/c/coreboot/+/34773/11/src/soc/mediatek/common/ds... PS11, Line 318: printk(BIOS_ERR, "dsi send cmd time-out(400uS)\n"); Space before (, and spell: 400 us
dsi send cmd time-out (400 us)
Error level messages should be user understandable.
dsi snd cmd timed out after 400 us, panel probably won’t work
or something similar.
https://review.coreboot.org/c/coreboot/+/34773/11/src/soc/mediatek/common/ds... PS11, Line 368: printk(BIOS_ERR, "%s: Unknown cmd: %d, abort\n", … abort panel initialization?