Skip to content

Commit

Permalink
Revert "msm: isp: Add support for VFE resolution limit"
Browse files Browse the repository at this point in the history
This reverts commit ebdc70c.
  • Loading branch information
TheScarastic authored and HighwayStar committed Oct 1, 2019
1 parent b4be553 commit 1a50375
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/media/platform/msm/camera_v2/isp/msm_isp.h
Original file line number Diff line number Diff line change
Expand Up @@ -772,7 +772,9 @@ struct vfe_device {
uint32_t is_split;
uint32_t dual_vfe_enable;
unsigned long page_fault_addr;
#if !defined(CONFIG_MACH_NUBIA_NX551J) && !defined(CONFIG_MACH_NUBIA_NX549J)
uint32_t vfe_hw_limit;
#endif

/* Debug variables */
int dump_reg;
Expand Down
4 changes: 4 additions & 0 deletions drivers/media/platform/msm/camera_v2/isp/msm_isp47.c
Original file line number Diff line number Diff line change
Expand Up @@ -2586,8 +2586,10 @@ int msm_vfe47_enable_regulators(struct vfe_device *vfe_dev, int enable)
int msm_vfe47_get_platform_data(struct vfe_device *vfe_dev)
{
int rc = 0;
#if !defined(CONFIG_MACH_NUBIA_NX551J) && !defined(CONFIG_MACH_NUBIA_NX549J)
void __iomem *vfe_fuse_base;
uint32_t vfe_fuse_base_size;
#endif

vfe_dev->vfe_base = msm_camera_get_reg_base(vfe_dev->pdev, "vfe", 0);
if (!vfe_dev->vfe_base)
Expand All @@ -2612,6 +2614,7 @@ int msm_vfe47_get_platform_data(struct vfe_device *vfe_dev)
rc = -ENOMEM;
goto get_res_fail;
}
#if !defined(CONFIG_MACH_NUBIA_NX551J) && !defined(CONFIG_MACH_NUBIA_NX549J)
vfe_dev->vfe_hw_limit = 0;
vfe_fuse_base = msm_camera_get_reg_base(vfe_dev->pdev,
"vfe_fuse", 0);
Expand All @@ -2624,6 +2627,7 @@ int msm_vfe47_get_platform_data(struct vfe_device *vfe_dev)
msm_camera_put_reg_base(vfe_dev->pdev, vfe_fuse_base,
"vfe_fuse", 0);
}
#endif
rc = vfe_dev->hw_info->vfe_ops.platform_ops.get_regulators(vfe_dev);
if (rc)
goto get_regulator_fail;
Expand Down
2 changes: 2 additions & 0 deletions drivers/media/platform/msm/camera_v2/isp/msm_isp_util.c
Original file line number Diff line number Diff line change
Expand Up @@ -1427,6 +1427,7 @@ static int msm_isp_send_hw_cmd(struct vfe_device *vfe_dev,
vfe_dev->vfe_ub_policy = *cfg_data;
break;
}
#if !defined(CONFIG_MACH_NUBIA_NX551J) && !defined(CONFIG_MACH_NUBIA_NX549J)
case GET_VFE_HW_LIMIT: {
uint32_t *hw_limit = NULL;

Expand All @@ -1441,6 +1442,7 @@ static int msm_isp_send_hw_cmd(struct vfe_device *vfe_dev,
*hw_limit = vfe_dev->vfe_hw_limit;
break;
}
#endif
}
return 0;
}
Expand Down
13 changes: 13 additions & 0 deletions include/uapi/media/msmb_isp.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@

#define ISP_STATS_STREAM_BIT 0x80000000

#if !defined(CONFIG_MACH_NUBIA_NX551J) && !defined(CONFIG_MACH_NUBIA_NX549J)
#define VFE_HW_LIMIT 1
#endif

struct msm_vfe_cfg_cmd_list;

Expand Down Expand Up @@ -502,7 +504,9 @@ enum msm_vfe_reg_cfg_type {
VFE_HW_UPDATE_UNLOCK,
SET_WM_UB_SIZE,
SET_UB_POLICY,
#if !defined(CONFIG_MACH_NUBIA_NX551J) && !defined(CONFIG_MACH_NUBIA_NX549J)
GET_VFE_HW_LIMIT,
#endif
};

struct msm_vfe_cfg_cmd2 {
Expand Down Expand Up @@ -959,7 +963,9 @@ enum msm_isp_ioctl_cmd_code {
MSM_ISP_FETCH_ENG_MULTI_PASS_START,
MSM_ISP_MAP_BUF_START_MULTI_PASS_FE,
MSM_ISP_CFG_HW_STATE,
#if !defined(CONFIG_MACH_NUBIA_NX551J) && !defined(CONFIG_MACH_NUBIA_NX549J)
MSM_ISP_AHB_CLK_CFG,
#endif
MSM_ISP_UPDATE_FE_FRAME_ID,
MSM_ISP_RESTART_FE,
MSM_ISP32_REQUEST_STREAM,
Expand Down Expand Up @@ -1077,6 +1083,11 @@ enum msm_isp_ioctl_cmd_code {
_IOWR('V', MSM_ISP_UNMAP_BUF, \
struct msm_isp_unmap_buf_req)

#if defined(CONFIG_MACH_NUBIA_NX551J) || defined(CONFIG_MACH_NUBIA_NX549J)
#define VIDIOC_MSM_ISP_AHB_CLK_CFG \
_IOWR('V', BASE_VIDIOC_PRIVATE+25, struct msm_isp_ahb_clk_cfg)
#endif

#define VIDIOC_MSM_ISP_FETCH_ENG_MULTI_PASS_START \
_IOWR('V', MSM_ISP_FETCH_ENG_MULTI_PASS_START, \
struct msm_vfe_fetch_eng_multi_pass_start)
Expand All @@ -1089,8 +1100,10 @@ enum msm_isp_ioctl_cmd_code {
_IOWR('V', MSM_ISP_CFG_HW_STATE, \
struct msm_vfe_axi_stream_cfg_cmd)

#if !defined(CONFIG_MACH_NUBIA_NX551J) && !defined(CONFIG_MACH_NUBIA_NX549J)
#define VIDIOC_MSM_ISP_AHB_CLK_CFG \
_IOWR('V', MSM_ISP_AHB_CLK_CFG, struct msm_isp_ahb_clk_cfg)
#endif

#define VIDIOC_MSM_ISP_BUF_DONE \
_IOWR('V', BASE_VIDIOC_PRIVATE+21, struct msm_isp32_event_data)
Expand Down

0 comments on commit 1a50375

Please sign in to comment.