Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[media] media: OF: add "sync-on-green-active" property

This patch adds 'sync-on-green-active' property as part
of endpoint property.

Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>

authored by

Lad, Prabhakar and committed by
Mauro Carvalho Chehab
d1d70aa6 edcaa49a

+9
+2
Documentation/devicetree/bindings/media/video-interfaces.txt
··· 88 88 - field-even-active: field signal level during the even field data transmission. 89 89 - pclk-sample: sample data on rising (1) or falling (0) edge of the pixel clock 90 90 signal. 91 + - sync-on-green-active: active state of Sync-on-green (SoG) signal, 0/1 for 92 + LOW/HIGH respectively. 91 93 - data-lanes: an array of physical data lane indexes. Position of an entry 92 94 determines the logical lane number, while the value of an entry indicates 93 95 physical lane, e.g. for 2-lane MIPI CSI-2 bus we could have
+4
drivers/media/v4l2-core/v4l2-of.c
··· 100 100 if (!of_property_read_u32(node, "data-shift", &v)) 101 101 bus->data_shift = v; 102 102 103 + if (!of_property_read_u32(node, "sync-on-green-active", &v)) 104 + flags |= v ? V4L2_MBUS_VIDEO_SOG_ACTIVE_HIGH : 105 + V4L2_MBUS_VIDEO_SOG_ACTIVE_LOW; 106 + 103 107 bus->flags = flags; 104 108 105 109 }
+3
include/media/v4l2-mediabus.h
··· 40 40 #define V4L2_MBUS_FIELD_EVEN_HIGH (1 << 10) 41 41 /* FIELD = 1/0 - Field1 (odd)/Field2 (even) */ 42 42 #define V4L2_MBUS_FIELD_EVEN_LOW (1 << 11) 43 + /* Active state of Sync-on-green (SoG) signal, 0/1 for LOW/HIGH respectively. */ 44 + #define V4L2_MBUS_VIDEO_SOG_ACTIVE_HIGH (1 << 12) 45 + #define V4L2_MBUS_VIDEO_SOG_ACTIVE_LOW (1 << 13) 43 46 44 47 /* Serial flags */ 45 48 /* How many lanes the client can use */