]> Git Repo - J-u-boot.git/blobdiff - include/video.h
Merge tag 'v2025.01-rc6' into next
[J-u-boot.git] / include / video.h
index 4d8df9baaada799bda781e554f1660013fb2332f..4ec71ab16da884023e70c8b61aa6e1e4e25c9c37 100644 (file)
@@ -57,12 +57,8 @@ enum video_log2_bpp {
        VIDEO_BPP32,
 };
 
-/*
- * Convert enum video_log2_bpp to bytes and bits. Note we omit the outer
- * brackets to allow multiplication by fractional pixels.
- */
+/* Convert enum video_log2_bpp to bytes and bits */
 #define VNBYTES(bpix)  ((1 << (bpix)) / 8)
-
 #define VNBITS(bpix)   (1 << (bpix))
 
 enum video_format {
@@ -78,7 +74,8 @@ enum video_format {
  *
  * @xsize:     Number of pixel columns (e.g. 1366)
  * @ysize:     Number of pixels rows (e.g.. 768)
- * @rot:       Display rotation (0=none, 1=90 degrees clockwise, etc.)
+ * @rot:       Display rotation (0=none, 1=90 degrees clockwise, etc.). THis
+ *             does not affect @xsize and @ysize
  * @bpix:      Encoded bits per pixel (enum video_log2_bpp)
  * @format:    Pixel format (enum video_format)
  * @vidconsole_drv_name:       Driver to use for the text console, NULL to
@@ -97,6 +94,7 @@ enum video_format {
  *             the LCD is updated
  * @fg_col_idx:        Foreground color code (bit 3 = bold, bit 0-2 = color)
  * @bg_col_idx:        Background color code (bit 3 = bold, bit 0-2 = color)
+ * @last_sync: Monotonic time of last video sync
  */
 struct video_priv {
        /* Things set up by the driver: */
@@ -121,6 +119,7 @@ struct video_priv {
        bool flush_dcache;
        u8 fg_col_idx;
        u8 bg_col_idx;
+       ulong last_sync;
 };
 
 /**
@@ -179,6 +178,7 @@ enum colour_idx {
        VID_LIGHT_MAGENTA,
        VID_LIGHT_CYAN,
        VID_WHITE,
+       VID_DARK_GREY,
 
        VID_COLOUR_COUNT
 };
@@ -418,4 +418,15 @@ int bmp_info(ulong addr);
  */
 int video_reserve_from_bloblist(struct video_handoff *ho);
 
+/**
+ * video_get_fb() - Get the first framebuffer address
+ *
+ * This function does not probe video devices, so can only be used after a video
+ * device has been activated.
+ *
+ * Return: address of the framebuffer of the first video device found, or 0 if
+ * there is no device
+ */
+ulong video_get_fb(void);
+
 #endif
This page took 0.024318 seconds and 4 git commands to generate.