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

Commit 436d5a21 authored by Srinu Gorle's avatar Srinu Gorle
Browse files

msm: vidc: enable high resolutions for qcs605



enable high resolutions if it is qcs605 target.

Change-Id: I1238fc472dd5fca6a1352d462f63c4f10e11f391
Signed-off-by: default avatarSrinu Gorle <sgorle@codeaurora.org>
parent 36e621ea
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
/* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
/* Copyright (c) 2012-2018, 2020 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
@@ -505,6 +505,10 @@ static int msm_vidc_probe_vidc_device(struct platform_device *pdev)

	core->platform_data = vidc_get_drv_data(&pdev->dev);
	dev_set_drvdata(&pdev->dev, core);
	if (core->platform_data) {
		core->resources.enable_max_resolution =
			core->platform_data->enable_max_resolution;
	}
	rc = msm_vidc_initialize_core(pdev, core);
	if (rc) {
		dprintk(VIDC_ERR, "Failed to init core\n");
+1 −0
Original line number Diff line number Diff line
@@ -233,6 +233,7 @@ struct msm_vidc_platform_data {
	struct msm_vidc_efuse_data *efuse_data;
	unsigned int efuse_data_length;
	unsigned int sku_version;
	bool enable_max_resolution;
};

struct msm_vidc_format {
+19 −1
Original line number Diff line number Diff line
/* Copyright (c) 2018, The Linux Foundation. All rights reserved.
/* Copyright (c) 2018, 2020 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
@@ -322,6 +322,10 @@ static const struct of_device_id msm_vidc_dt_match[] = {
		.compatible = "qcom,sdm670-vidc",
		.data = &sdm670_data,
	},
	{
		.compatible = "qcom,qcs605-vidc",
		.data = &sdm670_data,
	},
	{},
};

@@ -399,6 +403,20 @@ void *vidc_get_drv_data(struct device *dev)
			driver_data->common_data_length =
					ARRAY_SIZE(sdm670_common_data_v1);
		}
	} else if (!strcmp(match->compatible, "qcom,qcs605-vidc")) {
		rc = msm_vidc_read_efuse(driver_data, dev);
		if (rc) {
			dprintk(VIDC_ERR,
				"msm_vidc_read_efuse failed\n");
				goto exit;
		}

		if (driver_data->sku_version == SKU_VERSION_1) {
			driver_data->common_data = sdm670_common_data_v1;
			driver_data->common_data_length =
			ARRAY_SIZE(sdm670_common_data_v1);
		}
		driver_data->enable_max_resolution = true;
	}

exit:
+2 −1
Original line number Diff line number Diff line
/* Copyright (c) 2013-2018, The Linux Foundation. All rights reserved.
/* Copyright (c) 2013-2018, 2020 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
@@ -190,6 +190,7 @@ struct msm_vidc_platform_resources {
	struct msm_vidc_codec_data *codec_data;
	int codec_data_count;
	struct msm_vidc_csc_coeff *csc_coeff_data;
	bool enable_max_resolution;
};

static inline bool is_iommu_present(struct msm_vidc_platform_resources *res)