Skip to contentSkip to conversation

media: i2c: imx471: Fix register size for IMX471_REG_DPGA_USE_GLOBAL_GAIN

PATCH New Kate Hsuan 1 participant 1 message Oct 2

Subsystems (3)
lore
Share & tools
lore

Kate Hsuan

author maintainer
#0 lore raw

PATCH 1/1 media: i2c: imx471: Fix register size for IMX471_REG_DPGA_USE_GLOBAL_GAIN

The IMX471_REG_DPGA_USE_GLOBAL_GAIN register was incorrectly defined as a 16-bit register, preventing global gain from enabling correctly. As a result, only the green channel gain was applied instead of the intended global gain.

Change the register size to 8 bits to ensure global gain is properly enabled.

Fixes be1589e567ae ("media: i2c: imx471: Add Sony IMX471 image sensor driver")
---
 drivers/media/i2c/imx471.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/i2c/imx471.c +1 -1
index 4053aed84340..b442b083286d 100644
@@ -46,7 +46,7 @@
 #define IMX471_ANA_GAIN_DEFAULT			0
 
 /* Digital gain control */
-#define IMX471_REG_DPGA_USE_GLOBAL_GAIN		CCI_REG16(0x3ff9)
+#define IMX471_REG_DPGA_USE_GLOBAL_GAIN		CCI_REG8(0x3ff9)
 #define IMX471_REG_DIG_GAIN_GLOBAL		CCI_REG16(0x020e)
 #define IMX471_DGTL_GAIN_MIN			256
 #define IMX471_DGTL_GAIN_MAX			4095
Signature · 1 line
2.55.0