Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a4fda005 authored by E V Ravi's avatar E V Ravi Committed by Gerrit - the friendly Code Review server
Browse files

msm: ais: fix camif_cfg programming



Fixed Camera configuration register. Register expects width and height
starting from 0 while it was programmed starting from 1.

This fixes CAMIF erorrs we experience as the programmed size is
always 1 more pixel and line.

Change-Id: I73f1f5040820b71d317c317f8f5c6e3ff19db6e6
Signed-off-by: default avatarE V Ravi <evenka@codeaurora.org>
parent b3e4ae27
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
/* Copyright (c) 2013-2018, The Linux Foundation. All rights reserved.
/* Copyright (c) 2013-2019, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -1323,8 +1323,8 @@ void msm_vfe47_cfg_camif(struct vfe_device *vfe_dev,
	first_line = camif_cfg->first_line;
	last_line = camif_cfg->last_line;

	msm_camera_io_w((camif_cfg->lines_per_frame) << 16 |
		(camif_cfg->pixels_per_line), vfe_dev->vfe_base + 0x484);
	msm_camera_io_w((camif_cfg->lines_per_frame - 1) << 16 |
		(camif_cfg->pixels_per_line - 1), vfe_dev->vfe_base + 0x484);
	if (bus_sub_en) {
		val = msm_camera_io_r(vfe_dev->vfe_base + 0x47C);
		val &= 0xFFFFFFDF;