[Concept,09/27] video: Log each measured line with log_content()

Message ID 20260119204130.3972647-10-sjg@u-boot.org
State New
Headers
Series Expo debugging and textedit improvements (part E) |

Commit Message

Simon Glass Jan. 19, 2026, 8:41 p.m. UTC
  From: Simon Glass <simon.glass@canonical.com>

Change log_debug() to log_content() for line measurement logging and
add logging for the final line. This allows detailed line-by-line
measurement output to be enabled separately from debug logging.

Co-developed-by: Claude Opus 4.5 <noreply@anthropic.com>
Signed-off-by: Simon Glass <simon.glass@canonical.com>
---

 drivers/video/console_truetype.c | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)
  

Patch

diff --git a/drivers/video/console_truetype.c b/drivers/video/console_truetype.c
index f73fb3e6595..98356de2fd2 100644
--- a/drivers/video/console_truetype.c
+++ b/drivers/video/console_truetype.c
@@ -1075,9 +1075,10 @@  static int truetype_measure(struct udevice *dev, const char *name, uint size,
 			mline.len = (s - text) - start;
 			if (lines && !alist_add(lines, mline))
 				return log_msg_ret("ttm", -ENOMEM);
-			log_debug("line x1 %d y0 %d y1 %d start %d len %d text '%.*s'\n",
-				  mline.bbox.x1, mline.bbox.y0, mline.bbox.y1,
-				  mline.start, mline.len, mline.len, text + mline.start);
+			log_content("line x1 %d y0 %d y1 %d start %d len %d text '%.*s'\n",
+				    mline.bbox.x1, mline.bbox.y0, mline.bbox.y1,
+				    mline.start, mline.len, mline.len,
+				    text + mline.start);
 
 			start = s - text;
 			start++;
@@ -1098,6 +1099,9 @@  static int truetype_measure(struct udevice *dev, const char *name, uint size,
 	mline.len = (s - text) - start;
 	if (lines && !alist_add(lines, mline))
 		return log_msg_ret("ttM", -ENOMEM);
+	log_content("line x1 %d y0 %d y1 %d start %d len %d text '%.*s'\n",
+		    mline.bbox.x1, mline.bbox.y0, mline.bbox.y1,
+		    mline.start, mline.len, mline.len, text + mline.start);
 
 	bbox->valid = true;
 	bbox->x0 = 0;