summaryrefslogtreecommitdiff
path: root/src/soc/mediatek
diff options
context:
space:
mode:
authorRuihai Zhou <zhouruihai@huaqin.corp-partner.google.com>2023-07-13 09:24:17 +0800
committerEric Lai <eric_lai@quanta.corp-partner.google.com>2023-07-14 03:11:53 +0000
commit7a66715ad486572cb84b77e87a56abbfde84cd3e (patch)
treee0dda33c15c8b46a5ee9c157663300fd4f8b396f /src/soc/mediatek
parentafcd48a2f16592f972f635783048024b2a06a771 (diff)
soc/mediatek/common/dsi: Add actual values to the log messages
Per the suggestion in CB:76218, print actual values to the error messages, which may be helpful for debugging. Signed-off-by: Ruihai Zhou <zhouruihai@huaqin.corp-partner.google.com> Change-Id: Id3a7a8c76b6ad15e7cf71225d8529f3e034935ea Reviewed-on: https://review.coreboot.org/c/coreboot/+/76442 Reviewed-by: cong yang <yangcong5@huaqin.corp-partner.google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com> Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Diffstat (limited to 'src/soc/mediatek')
-rw-r--r--src/soc/mediatek/common/dsi.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/soc/mediatek/common/dsi.c b/src/soc/mediatek/common/dsi.c
index 396d979c21..f72173e4ad 100644
--- a/src/soc/mediatek/common/dsi.c
+++ b/src/soc/mediatek/common/dsi.c
@@ -221,8 +221,9 @@ static void mtk_dsi_config_vdo_timing(u32 mode_flags, u32 format, u32 lanes,
hfp_byte -= d_phy * hfp / (hfp + hbp);
hbp_byte -= d_phy * hbp / (hfp + hbp);
} else {
- printk(BIOS_ERR, "HFP plus HBP is not greater than d_phy, "
- "the panel may not work properly.\n");
+ printk(BIOS_ERR, "HFP %u plus HBP %u is not greater than d_phy %u, "
+ "the panel may not work properly.\n", hfp * bytes_per_pixel,
+ hbp * bytes_per_pixel, d_phy);
}
if (mode_flags & MIPI_DSI_MODE_LINE_END) {
@@ -233,16 +234,16 @@ static void mtk_dsi_config_vdo_timing(u32 mode_flags, u32 format, u32 lanes,
}
if (hfp_byte + hbp_byte < MIN_HFP_BYTE + MIN_HBP_BYTE) {
- printk(BIOS_ERR, "Calculated hfp_byte and hbp_byte are too small, "
- "the panel may not work properly.\n");
+ printk(BIOS_ERR, "Calculated hfp_byte %d and hbp_byte %d are too small, "
+ "the panel may not work properly.\n", hfp_byte, hbp_byte);
} else if (hfp_byte < MIN_HFP_BYTE) {
- printk(BIOS_NOTICE, "Calculated hfp_byte is too small, "
- "adjust it to the minimum value.\n");
+ printk(BIOS_NOTICE, "Calculated hfp_byte %d is too small, "
+ "adjust it to the minimum value %d.\n", hfp_byte, MIN_HFP_BYTE);
hbp_byte -= MIN_HFP_BYTE - hfp_byte;
hfp_byte = MIN_HFP_BYTE;
} else if (hbp_byte < MIN_HBP_BYTE) {
- printk(BIOS_NOTICE, "Calculated hbp_byte is too small, "
- "adjust it to the minimum value.\n");
+ printk(BIOS_NOTICE, "Calculated hbp_byte %d is too small, "
+ "adjust it to the minimum value %d.\n", hbp_byte, MIN_HBP_BYTE);
hfp_byte -= MIN_HBP_BYTE - hbp_byte;
hbp_byte = MIN_HBP_BYTE;
}