示例#1
0
/*
 * The following two functions absolutely depend on the fact, that
 * there can be only one camera on i.MX1/i.MXL camera sensor interface
 */
static int mx1_camera_clock_start(struct soc_camera_host *ici)
{
	struct mx1_camera_dev *pcdev = ici->priv;

	mx1_camera_activate(pcdev);

	return 0;
}
示例#2
0
/*
 * The following two functions absolutely depend on the fact, that
 * there can be only one camera on i.MX1/i.MXL camera sensor interface
 */
static int mx1_camera_add_device(struct soc_camera_device *icd)
{
	struct soc_camera_host *ici = to_soc_camera_host(icd->parent);
	struct mx1_camera_dev *pcdev = ici->priv;

	dev_info(icd->parent, "MX1 Camera driver attached to camera %d\n",
		 icd->devnum);

	mx1_camera_activate(pcdev);

	return 0;
}
示例#3
0
/*
 * The following two functions absolutely depend on the fact, that
 * there can be only one camera on i.MX1/i.MXL camera sensor interface
 */
static int mx1_camera_add_device(struct soc_camera_device *icd)
{
	struct soc_camera_host *ici = to_soc_camera_host(icd->dev.parent);
	struct mx1_camera_dev *pcdev = ici->priv;
	int ret;

	if (pcdev->icd) {
		ret = -EBUSY;
		goto ebusy;
	}

	dev_info(icd->dev.parent, "MX1 Camera driver attached to camera %d\n",
		 icd->devnum);

	mx1_camera_activate(pcdev);

	pcdev->icd = icd;

ebusy:
	return ret;
}