ov5645: Fix incorrect behavior of ov5645_set_regs The sysfs functionality of setting registers for the OV5645 camera was broken. This is purely for development and debugging functionality so does not fix any "real" bugs. Change-Id: I991e1319aaf58cda66bdeac55f035f72c16b9441
diff --git a/drivers/media/platform/mxc/capture/ov5645_mipi_v2.c b/drivers/media/platform/mxc/capture/ov5645_mipi_v2.c index 3c0e3d2..6ae6aa3 100644 --- a/drivers/media/platform/mxc/capture/ov5645_mipi_v2.c +++ b/drivers/media/platform/mxc/capture/ov5645_mipi_v2.c
@@ -3439,7 +3439,7 @@ static int ov5645_set_regs(const char *buffer, struct kernel_param *kp) if (in_string == NULL) return 0; - while (true) { + while (in_string != NULL) { reg = strsep(&in_string, ","); cnt = sscanf(reg, "%x", ®_addr); if (cnt != 1)