/* config function simliar to origanl msm_ioctl_config*/
static int msm_isp_config(struct msm_cam_media_controller *pmctl,
			 unsigned int cmd, unsigned long arg)
{

	int rc = -EINVAL;
	void __user *argp = (void __user *)arg;
	struct v4l2_subdev *sd = pmctl->isp_sdev->sd;

	D("%s: cmd %d\n", __func__, _IOC_NR(cmd));
	switch (cmd) {
	case MSM_CAM_IOCTL_PICT_PP_DONE:
		/* Release the preview of snapshot frame
		 * that was grabbed.
		 */
		/*rc = msm_pp_release(pmsm->sync, arg);*/
		break;

	case MSM_CAM_IOCTL_CONFIG_VFE:
		/* Coming from config thread for update */
		rc = msm_config_vfe(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_CONFIG_VPE:
		/* Coming from config thread for update */
		/*rc = msm_config_vpe(pmsm->sync, argp);*/
		rc = 0;
		break;

	case MSM_CAM_IOCTL_AXI_CONFIG:
		D("Received MSM_CAM_IOCTL_AXI_CONFIG\n");
		rc = msm_axi_config(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_RELEASE_STATS_BUFFER:
		rc = msm_put_stats_buffer(sd, pmctl, argp);
		break;

/* HTC_START */
	case MSM_CAM_IOCTL_ENABLE_DROP_FRAME :
		rc = msm_enable_dropframe(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_SET_DROP_FRAME_NUM :
		rc = msm_set_dropframe_num(sd, pmctl, argp);
		break;
/* HTC_END */

	default:
		break;
	}

	D("%s: cmd %d DONE\n", __func__, _IOC_NR(cmd));

	return rc;
}
예제 #2
0
static int msm_isp_config(struct msm_cam_media_controller *pmctl,
			 unsigned int cmd, unsigned long arg)
{

	int rc = -EINVAL;
	void __user *argp = (void __user *)arg;
	struct v4l2_subdev *sd = pmctl->isp_sdev->sd;

	D("%s: cmd %d\n", __func__, _IOC_NR(cmd));
	switch (cmd) {
	case MSM_CAM_IOCTL_PICT_PP_DONE:
		
		break;

	case MSM_CAM_IOCTL_CONFIG_VFE:
		
		rc = msm_config_vfe(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_CONFIG_VPE:
		
		
		rc = 0;
		break;

	case MSM_CAM_IOCTL_AXI_CONFIG:
		D("Received MSM_CAM_IOCTL_AXI_CONFIG\n");
		rc = msm_axi_config(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_RELEASE_STATS_BUFFER:
		rc = msm_put_stats_buffer(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_ENABLE_DROP_FRAME :
		rc = msm_enable_dropframe(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_SET_DROP_FRAME_NUM :
		rc = msm_set_dropframe_num(sd, pmctl, argp);
		break;

	default:
		break;
	}

	D("%s: cmd %d DONE\n", __func__, _IOC_NR(cmd));

	return rc;
}
예제 #3
0
/* config function simliar to origanl msm_ioctl_config*/
int msm_isp_config(struct msm_cam_media_controller *pmctl,
                   unsigned int cmd, unsigned long arg)
{

    int rc = -EINVAL;
    void __user *argp = (void __user *)arg;
    struct v4l2_subdev *sd;
    if (!pmctl->vfe_sdev) {
        pr_err("%s vfe subdev is NULL\n", __func__);
        return -ENXIO;
    }
    sd = pmctl->vfe_sdev;
    D("%s: cmd %d\n", __func__, _IOC_NR(cmd));
    switch (cmd) {
    case MSM_CAM_IOCTL_CONFIG_VFE:
        /* Coming from config thread for update */
        rc = msm_config_vfe(sd, pmctl, argp);
        break;

    case MSM_CAM_IOCTL_AXI_CONFIG:
#if	0//def F_PANTECH_CAMERA_DEADBEEF_ERROR_FIX
        D("Received MSM_CAM_IOCTL_AXI_CONFIG\n");
#else
        pr_err("%s: Received MSM_CAM_IOCTL_AXI_CONFIG\n", __func__);
#endif
        rc = msm_axi_config(sd, pmctl, argp);
        break;

    case MSM_CAM_IOCTL_RELEASE_STATS_BUFFER:
        rc = msm_put_stats_buffer(sd, pmctl, argp);
        break;

    case MSM_CAM_IOCTL_STATS_REQBUF:
    case MSM_CAM_IOCTL_STATS_ENQUEUEBUF:
    case MSM_CAM_IOCTL_STATS_FLUSH_BUFQ:
    case MSM_CAM_IOCTL_STATS_UNREG_BUF:
        rc = msm_vfe_stats_buf_ioctl(sd, cmd, pmctl, argp);
        break;

    default:
        break;
    }

    D("%s: cmd %d DONE\n", __func__, _IOC_NR(cmd));

    return rc;
}
예제 #4
0
/* config function simliar to origanl msm_ioctl_config*/
static int msm_isp_config(struct msm_cam_media_controller *pmctl,
			 unsigned int cmd, unsigned long arg)
{

	int rc = -EINVAL;
	void __user *argp = (void __user *)arg;
	struct v4l2_subdev *sd;

	if (!pmctl->isp_sdev->sd) {
		pr_err("%s vfe subdev is NULL\n", __func__);
		return -ENXIO;
	}
	sd = pmctl->isp_sdev->sd;
	D("%s: cmd %d\n", __func__, _IOC_NR(cmd));
	switch (cmd) {
	case MSM_CAM_IOCTL_PICT_PP_DONE:
		/* Release the preview of snapshot frame
		 * that was grabbed.
		 */
		/*rc = msm_pp_release(pmsm->sync, arg);*/
		break;

	case MSM_CAM_IOCTL_CONFIG_VFE:
		/* Coming from config thread for update */
		rc = msm_config_vfe(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_AXI_CONFIG:
		D("Received MSM_CAM_IOCTL_AXI_CONFIG\n");
		rc = msm_axi_config(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_RELEASE_STATS_BUFFER:
		rc = msm_put_stats_buffer(sd, pmctl, argp);
		break;

	default:
		break;
	}

	D("%s: cmd %d DONE\n", __func__, _IOC_NR(cmd));

	return rc;
}
예제 #5
0
/* config function simliar to origanl msm_ioctl_config*/
static int msm_isp_config(struct msm_cam_media_controller *pmctl,
			 unsigned int cmd, unsigned long arg)
{

	int rc = -EINVAL;
	void __user *argp = (void __user *)arg;
	struct v4l2_subdev *sd = pmctl->isp_sdev->sd;

	D("%s: cmd %d\n", __func__, _IOC_NR(cmd));
	switch (cmd) {
	case MSM_CAM_IOCTL_CONFIG_VFE:
		/* Coming from config thread for update */
		rc = msm_config_vfe(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_AXI_CONFIG:
		D("Received MSM_CAM_IOCTL_AXI_CONFIG\n");
		rc = msm_axi_config(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_RELEASE_STATS_BUFFER:
		rc = msm_put_stats_buffer(sd, pmctl, argp);
		break;

	case MSM_CAM_IOCTL_STATS_REQBUF:
	case MSM_CAM_IOCTL_STATS_ENQUEUEBUF:
	case MSM_CAM_IOCTL_STATS_FLUSH_BUFQ:
	case MSM_CAM_IOCTL_STATS_UNREG_BUF:
		rc = msm_vfe_stats_buf_ioctl(sd, cmd, pmctl, argp);
		break;

	default:
		break;
	}

	D("%s: cmd %d DONE\n", __func__, _IOC_NR(cmd));

	return rc;
}