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

Commit 9402ff8d authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: camera: Update DDR device types"

parents 361bd47c 53320994
Loading
Loading
Loading
Loading
+4 −2
Original line number Original line Diff line number Diff line
@@ -368,7 +368,7 @@ int cam_a5_process_cmd(void *device_priv, uint32_t cmd_type,
	uint32_t ubwc_ipe_cfg[ICP_UBWC_MAX] = {0};
	uint32_t ubwc_ipe_cfg[ICP_UBWC_MAX] = {0};
	uint32_t ubwc_bps_cfg[ICP_UBWC_MAX] = {0};
	uint32_t ubwc_bps_cfg[ICP_UBWC_MAX] = {0};
	uint32_t index = 0;
	uint32_t index = 0;
	int rc = 0;
	int rc = 0, ddr_type = 0;


	if (!device_priv) {
	if (!device_priv) {
		CAM_ERR(CAM_ICP, "Invalid arguments");
		CAM_ERR(CAM_ICP, "Invalid arguments");
@@ -474,7 +474,9 @@ int cam_a5_process_cmd(void *device_priv, uint32_t cmd_type,


		if (a5_soc->ubwc_config_ext) {
		if (a5_soc->ubwc_config_ext) {
			/* Invoke kernel API to determine DDR type */
			/* Invoke kernel API to determine DDR type */
			if (of_fdt_get_ddrtype() == DDR_TYPE_LPDDR5)
			ddr_type = of_fdt_get_ddrtype();
			if ((ddr_type == DDR_TYPE_LPDDR5) ||
				(ddr_type == DDR_TYPE_LPDDR5X))
				index = 1;
				index = 1;


			ubwc_cfg_ext = &a5_soc->uconfig.ubwc_cfg_ext;
			ubwc_cfg_ext = &a5_soc->uconfig.ubwc_cfg_ext;
+4 −1
Original line number Original line Diff line number Diff line
@@ -1713,6 +1713,7 @@ static int cam_vfe_bus_ver3_init_comp_grp(uint32_t index,
{
{
	struct cam_vfe_bus_ver3_comp_grp_data *rsrc_data = NULL;
	struct cam_vfe_bus_ver3_comp_grp_data *rsrc_data = NULL;
	struct cam_vfe_soc_private *vfe_soc_private = soc_info->soc_private;
	struct cam_vfe_soc_private *vfe_soc_private = soc_info->soc_private;
	int ddr_type = 0;


	rsrc_data = kzalloc(sizeof(struct cam_vfe_bus_ver3_comp_grp_data),
	rsrc_data = kzalloc(sizeof(struct cam_vfe_bus_ver3_comp_grp_data),
		GFP_KERNEL);
		GFP_KERNEL);
@@ -1732,7 +1733,9 @@ static int cam_vfe_bus_ver3_init_comp_grp(uint32_t index,
		rsrc_data->comp_grp_type != CAM_VFE_BUS_VER3_COMP_GRP_1)
		rsrc_data->comp_grp_type != CAM_VFE_BUS_VER3_COMP_GRP_1)
		rsrc_data->ubwc_static_ctrl = 0;
		rsrc_data->ubwc_static_ctrl = 0;
	else {
	else {
		if (of_fdt_get_ddrtype() == DDR_TYPE_LPDDR5)
		ddr_type = of_fdt_get_ddrtype();
		if ((ddr_type == DDR_TYPE_LPDDR5) ||
			(ddr_type == DDR_TYPE_LPDDR5X))
			rsrc_data->ubwc_static_ctrl =
			rsrc_data->ubwc_static_ctrl =
				vfe_soc_private->ubwc_static_ctrl[1];
				vfe_soc_private->ubwc_static_ctrl[1];
		else
		else
+4 −2
Original line number Original line Diff line number Diff line
@@ -37,7 +37,9 @@


/* DDR device types */
/* DDR device types */
#define DDR_TYPE_LPDDR4        6
#define DDR_TYPE_LPDDR4        6
#define DDR_TYPE_LPDDR5       9
#define DDR_TYPE_LPDDR4X       7
#define DDR_TYPE_LPDDR5        8
#define DDR_TYPE_LPDDR5X       9


/**
/**
 * enum cam_vote_level - Enum for voting level
 * enum cam_vote_level - Enum for voting level