[PATCH 07/11] media: i2c: ov5640: Split out AWB registers

From: Kieran Bingham

Date: Fri May 01 2026 - 11:44:28 EST


Move the AWB registers to their own lines and split out from
the bulk block independently as a first stage before documenting
to ensure no registers values get lost or reordered during
the updates.

Signed-off-by: Kieran Bingham <kieran.bingham@xxxxxxxxxxxxxxxx>
---
drivers/media/i2c/ov5640.c | 46 +++++++++++++++++++++++++++++++++++-----------
1 file changed, 35 insertions(+), 11 deletions(-)

diff --git a/drivers/media/i2c/ov5640.c b/drivers/media/i2c/ov5640.c
index b4e1ec4364df..4b6804fc47e1 100644
--- a/drivers/media/i2c/ov5640.c
+++ b/drivers/media/i2c/ov5640.c
@@ -573,17 +573,41 @@ static const struct reg_value ov5640_init_setting[] = {
{0x3002, 0x1c, 0, 0}, {0x3004, 0xff, 0, 0}, {0x3006, 0xc3, 0, 0},
{0x302e, 0x08, 0, 0}, {0x4300, 0x3f, 0, 0},
{0x501f, 0x00, 0, 0}, {0x440e, 0x00, 0, 0}, {0x4837, 0x0a, 0, 0},
- {0x5000, 0xa7, 0, 0}, {0x5001, 0xa3, 0, 0}, {0x5180, 0xff, 0, 0},
- {0x5181, 0xf2, 0, 0}, {0x5182, 0x00, 0, 0}, {0x5183, 0x14, 0, 0},
- {0x5184, 0x25, 0, 0}, {0x5185, 0x24, 0, 0}, {0x5186, 0x09, 0, 0},
- {0x5187, 0x09, 0, 0}, {0x5188, 0x09, 0, 0}, {0x5189, 0x88, 0, 0},
- {0x518a, 0x54, 0, 0}, {0x518b, 0xee, 0, 0}, {0x518c, 0xb2, 0, 0},
- {0x518d, 0x50, 0, 0}, {0x518e, 0x34, 0, 0}, {0x518f, 0x6b, 0, 0},
- {0x5190, 0x46, 0, 0}, {0x5191, 0xf8, 0, 0}, {0x5192, 0x04, 0, 0},
- {0x5193, 0x70, 0, 0}, {0x5194, 0xf0, 0, 0}, {0x5195, 0xf0, 0, 0},
- {0x5196, 0x03, 0, 0}, {0x5197, 0x01, 0, 0}, {0x5198, 0x04, 0, 0},
- {0x5199, 0x6c, 0, 0}, {0x519a, 0x04, 0, 0}, {0x519b, 0x00, 0, 0},
- {0x519c, 0x09, 0, 0}, {0x519d, 0x2b, 0, 0}, {0x519e, 0x38, 0, 0},
+ {0x5000, 0xa7, 0, 0}, {0x5001, 0xa3, 0, 0},
+
+ /* AWB Control */
+ {0x5180, 0xff, 0, 0},
+ {0x5181, 0xf2, 0, 0},
+ {0x5182, 0x00, 0, 0},
+ {0x5183, 0x14, 0, 0},
+ {0x5184, 0x25, 0, 0},
+ {0x5185, 0x24, 0, 0},
+ {0x5186, 0x09, 0, 0},
+ {0x5187, 0x09, 0, 0},
+ {0x5188, 0x09, 0, 0},
+ {0x5189, 0x88, 0, 0},
+ {0x518a, 0x54, 0, 0},
+ {0x518b, 0xee, 0, 0},
+ {0x518c, 0xb2, 0, 0},
+ {0x518d, 0x50, 0, 0},
+ {0x518e, 0x34, 0, 0},
+ {0x518f, 0x6b, 0, 0},
+ {0x5190, 0x46, 0, 0},
+ {0x5191, 0xf8, 0, 0},
+ {0x5192, 0x04, 0, 0},
+ {0x5193, 0x70, 0, 0},
+ {0x5194, 0xf0, 0, 0},
+ {0x5195, 0xf0, 0, 0},
+ {0x5196, 0x03, 0, 0},
+ {0x5197, 0x01, 0, 0},
+ {0x5198, 0x04, 0, 0},
+ {0x5199, 0x6c, 0, 0},
+ {0x519a, 0x04, 0, 0},
+ {0x519b, 0x00, 0, 0},
+ {0x519c, 0x09, 0, 0},
+ {0x519d, 0x2b, 0, 0},
+ {0x519e, 0x38, 0, 0},
+
{0x5381, 0x1e, 0, 0}, {0x5382, 0x5b, 0, 0}, {0x5383, 0x08, 0, 0},
{0x5384, 0x0a, 0, 0}, {0x5385, 0x7e, 0, 0}, {0x5386, 0x88, 0, 0},
{0x5387, 0x7c, 0, 0}, {0x5388, 0x6c, 0, 0}, {0x5389, 0x10, 0, 0},

--
2.52.0