[PATCH v1 2/4] video: mipi-dbi: add display rotation support

Giandomenico Rossi rossi at amelchem.com
Fri Feb 13 11:12:45 PST 2026


Add a rotation field to struct mipi_dbi_dev to allow panel drivers
to configure the display orientation via the MADCTL register.

The value is expressed in degrees counter-clockwise (0, 90, 180, 270)
and is intended to be parsed from the optional 'rotation' device tree
property by individual panel drivers.

Signed-off-by: Giandomenico Rossi <rossi at amelchem.com>
---
 include/video/mipi_dbi.h | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/include/video/mipi_dbi.h b/include/video/mipi_dbi.h
index 42ca8a6332..ee6aca675c 100644
--- a/include/video/mipi_dbi.h
+++ b/include/video/mipi_dbi.h
@@ -121,6 +121,11 @@ struct mipi_dbi_dev {
 	 */
 	void *driver_private;
 
+	/**
+	 * @rotation: initial rotation in degrees Counter Clock Wise
+	 */
+	unsigned int rotation;
+
 	/**
 	 * @damage: Damage rectangle.
 	 */
-- 
2.34.1




More information about the barebox mailing list