msm: camera: tfe: Enable TFE and OPE for bengal
Enable TFE and OPE compilation for bengal target. CRs-Fixed: 2729996 Change-Id: I648cae32f39a5bf7225c8be545f1c310e24db8e6 Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>
This commit is contained in:

committed by
Gerrit - the friendly Code Review server

parent
8c5f76e807
commit
97eeefea15
@@ -2,9 +2,7 @@
|
||||
# Copyright (c) 2019, The Linux Foundation. All rights reserved.
|
||||
|
||||
export CONFIG_SPECTRA_CAMERA=y
|
||||
export CONFIG_SPECTRA_TFE=y
|
||||
export CONFIG_SPECTRA_ISP=y
|
||||
export CONFIG_SPECTRA_SENSOR=y
|
||||
export CONFIG_SPECTRA_ICP=y
|
||||
export CONFIG_SPECTRA_JPEG=y
|
||||
export CONFIG_SPECTRA_LRME=y
|
||||
export CONFIG_SPECTRA_FD=y
|
||||
export CONFIG_SPECTRA_OPE=y
|
||||
|
@@ -1,13 +1,11 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0-only */
|
||||
/*
|
||||
* Copyright (c) 2019, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2019-2020, The Linux Foundation. All rights reserved.
|
||||
*/
|
||||
|
||||
#define CONFIG_SPECTRA_CAMERA 1
|
||||
#define CONFIG_SPECTRA_TFE 1
|
||||
#define CONFIG_SPECTRA_ISP 1
|
||||
#define CONFIG_SPECTRA_SENSOR 1
|
||||
#define CONFIG_SPECTRA_ICP 1
|
||||
#define CONFIG_SPECTRA_JPEG 1
|
||||
#define CONFIG_SPECTRA_LRME 1
|
||||
#define CONFIG_SPECTRA_FD 1
|
||||
#define CONFIG_SPECTRA_OPE 1
|
||||
|
||||
|
@@ -702,10 +702,10 @@ struct platform_driver cam_cdm_intf_driver = {
|
||||
.probe = cam_cdm_intf_probe,
|
||||
.remove = cam_cdm_intf_remove,
|
||||
.driver = {
|
||||
.name = "msm_cam_cdm_intf",
|
||||
.owner = THIS_MODULE,
|
||||
.of_match_table = msm_cam_cdm_intf_dt_match,
|
||||
.suppress_bind_attrs = true,
|
||||
.name = "msm_cam_cdm_intf",
|
||||
.owner = THIS_MODULE,
|
||||
.of_match_table = msm_cam_cdm_intf_dt_match,
|
||||
.suppress_bind_attrs = true,
|
||||
},
|
||||
};
|
||||
|
||||
|
@@ -1565,7 +1565,7 @@ static int cam_cpas_hw_stop(void *hw_priv, void *stop_args,
|
||||
CAM_ERR(CAM_CPAS, "disable_resorce failed, rc=%d", rc);
|
||||
goto done;
|
||||
}
|
||||
CAM_DBG(CAM_CPAS, "Disabled all the resources: irq_count=%d\n",
|
||||
CAM_DBG(CAM_CPAS, "Disabled all the resources: irq_count=%d",
|
||||
atomic_read(&cpas_core->irq_count));
|
||||
cpas_hw->hw_state = CAM_HW_STATE_POWER_DOWN;
|
||||
}
|
||||
|
@@ -25,7 +25,7 @@ static const struct of_device_id cam_csid_ppi100_dt_match[] = {
|
||||
|
||||
MODULE_DEVICE_TABLE(of, cam_csid_ppi100_dt_match);
|
||||
|
||||
static struct platform_driver cam_csid_ppi100_driver = {
|
||||
struct platform_driver cam_csid_ppi100_driver = {
|
||||
.probe = cam_csid_ppi_probe,
|
||||
.remove = cam_csid_ppi_remove,
|
||||
.driver = {
|
||||
|
@@ -3018,7 +3018,8 @@ int cam_tfe_csid_hw_probe_init(struct cam_hw_intf *csid_hw_intf,
|
||||
for (i = 0; i < CAM_CSID_PPI_HW_MAX; i++) {
|
||||
rc = cam_csid_ppi_hw_init(&tfe_csid_hw->ppi_hw_intf[i], i);
|
||||
if (rc < 0) {
|
||||
CAM_ERR(CAM_ISP, "PPI init failed for PPI %d", i);
|
||||
CAM_INFO(CAM_ISP, "PPI init failed for PPI %d", i);
|
||||
rc = 0;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@@ -10,13 +10,15 @@
|
||||
#include "cam_tfe_csid_dev.h"
|
||||
#include "cam_tfe_csid_hw_intf.h"
|
||||
#include "cam_debug_util.h"
|
||||
#include "camera_main.h"
|
||||
|
||||
static struct cam_hw_intf *cam_tfe_csid_hw_list[CAM_TFE_CSID_HW_NUM_MAX] = {
|
||||
0, 0, 0};
|
||||
|
||||
static char csid_dev_name[8];
|
||||
|
||||
int cam_tfe_csid_probe(struct platform_device *pdev)
|
||||
static int cam_tfe_csid_component_bind(struct device *dev,
|
||||
struct device *master_dev, void *data)
|
||||
{
|
||||
|
||||
struct cam_hw_intf *csid_hw_intf;
|
||||
@@ -26,6 +28,7 @@ int cam_tfe_csid_probe(struct platform_device *pdev)
|
||||
struct cam_tfe_csid_hw_info *csid_hw_data = NULL;
|
||||
uint32_t csid_dev_idx;
|
||||
int rc = 0;
|
||||
struct platform_device *pdev = to_platform_device(dev);
|
||||
|
||||
CAM_DBG(CAM_ISP, "probe called");
|
||||
|
||||
@@ -101,11 +104,13 @@ err:
|
||||
return rc;
|
||||
}
|
||||
|
||||
int cam_tfe_csid_remove(struct platform_device *pdev)
|
||||
void cam_tfe_csid_component_unbind(struct device *dev,
|
||||
struct device *master_dev, void *data)
|
||||
{
|
||||
struct cam_tfe_csid_hw *csid_dev = NULL;
|
||||
struct cam_hw_intf *csid_hw_intf;
|
||||
struct cam_hw_info *csid_hw_info;
|
||||
struct platform_device *pdev = to_platform_device(dev);
|
||||
|
||||
csid_dev = (struct cam_tfe_csid_hw *)platform_get_drvdata(pdev);
|
||||
csid_hw_intf = csid_dev->hw_intf;
|
||||
@@ -120,6 +125,27 @@ int cam_tfe_csid_remove(struct platform_device *pdev)
|
||||
kfree(csid_dev);
|
||||
kfree(csid_hw_info);
|
||||
kfree(csid_hw_intf);
|
||||
}
|
||||
|
||||
const static struct component_ops cam_tfe_csid_component_ops = {
|
||||
.bind = cam_tfe_csid_component_bind,
|
||||
.unbind = cam_tfe_csid_component_unbind,
|
||||
};
|
||||
|
||||
int cam_tfe_csid_probe(struct platform_device *pdev)
|
||||
{
|
||||
int rc = 0;
|
||||
|
||||
rc = component_add(&pdev->dev, &cam_tfe_csid_component_ops);
|
||||
if (rc)
|
||||
CAM_ERR(CAM_ISP, "failed to add component rc: %d", rc);
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
||||
int cam_tfe_csid_remove(struct platform_device *pdev)
|
||||
{
|
||||
component_del(&pdev->dev, &cam_tfe_csid_component_ops);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@@ -67,6 +67,7 @@ static int cam_ope_init_hw_version(struct cam_hw_soc_info *soc_info,
|
||||
|
||||
switch (core_info->hw_version) {
|
||||
case OPE_HW_VER_1_0_0:
|
||||
case OPE_HW_VER_1_1_0:
|
||||
core_info->ope_hw_info->ope_hw = &ope_hw_100;
|
||||
break;
|
||||
default:
|
||||
|
@@ -7,6 +7,7 @@
|
||||
#define CAM_OPE_HW_H
|
||||
|
||||
#define OPE_HW_VER_1_0_0 0x10000000
|
||||
#define OPE_HW_VER_1_1_0 0x10010000
|
||||
|
||||
#define OPE_DEV_OPE 0
|
||||
#define OPE_DEV_MAX 1
|
||||
|
@@ -79,7 +79,6 @@ static const struct camera_submodule_component camera_base[] = {
|
||||
|
||||
static const struct camera_submodule_component camera_tfe[] = {
|
||||
#ifdef CONFIG_SPECTRA_TFE
|
||||
{&cam_top_tpg_init_module, &cam_top_tpg_exit_module},
|
||||
{&cam_csid_ppi100_init_module, &cam_csid_ppi100_exit_module},
|
||||
{&cam_tfe_init_module, &cam_tfe_exit_module},
|
||||
{&cam_tfe_csid530_init_module, &cam_tfe_csid530_exit_module},
|
||||
|
@@ -22,7 +22,7 @@ extern struct platform_driver cam_vfe_driver;
|
||||
extern struct platform_driver isp_driver;
|
||||
#endif
|
||||
#ifdef CONFIG_SPECTRA_TFE
|
||||
extern struct platform_driver cam_top_tpg_driver;
|
||||
extern struct platform_driver cam_csid_ppi100_driver;
|
||||
extern struct platform_driver cam_tfe_driver;
|
||||
extern struct platform_driver cam_tfe_csid530_driver;
|
||||
#endif
|
||||
@@ -79,6 +79,11 @@ static struct platform_driver *const cam_component_drivers[] = {
|
||||
&cam_cpas_driver,
|
||||
&cam_cdm_intf_driver,
|
||||
&cam_hw_cdm_driver,
|
||||
#ifdef CONFIG_SPECTRA_TFE
|
||||
&cam_csid_ppi100_driver,
|
||||
&cam_tfe_driver,
|
||||
&cam_tfe_csid530_driver,
|
||||
#endif
|
||||
#ifdef CONFIG_SPECTRA_ISP
|
||||
&cam_top_tpg_driver,
|
||||
&cam_ife_csid17x_driver,
|
||||
@@ -86,11 +91,6 @@ static struct platform_driver *const cam_component_drivers[] = {
|
||||
&cam_vfe_driver,
|
||||
&isp_driver,
|
||||
#endif
|
||||
#ifdef CONFIG_SPECTRA_TFE
|
||||
&cam_top_tpg_driver,
|
||||
&cam_tfe_driver,
|
||||
&cam_tfe_csid530_driver,
|
||||
#endif
|
||||
#ifdef CONFIG_SPECTRA_SENSOR
|
||||
&cam_res_mgr_driver,
|
||||
&cci_driver,
|
||||
|
Reference in New Issue
Block a user