Re: [RFC 17/17] rm680: Add camera init

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Sakari,

On 12/20/2011 09:28 PM, Sakari Ailus wrote:
+
+static int rm680_sec_camera_set_xshutdown(struct v4l2_subdev *subdev, u8 set)

It may be more efficient to just use u32.

+{
+	gpio_set_value(SEC_CAMERA_RESET_GPIO, !!set);
+	return 0;
+}
+
...
+void __init rm680_camera_init(void)
+{
+	struct isp_platform_data *pdata;
+	int rval;
+
+	rval = rm680_camera_hw_init();
+	if (rval) {
+		printk(KERN_WARNING "%s: unable to initialise camera\n",

pr_warn is preferred for new code.

+		       __func__);
+		return;
+	}
+
+	if (board_is_rm680())
+		pdata =&rm680_isp_platform_data;
+	else
+		pdata =&rm696_isp_platform_data;
+
+	if (omap3_init_camera(pdata)<  0)
+		printk(KERN_WARNING

pr_warn

+		       "%s: unable to register camera platform device\n",
+		       __func__);
+}
...
+static struct regulator_consumer_supply rm680_vaux2_consumers[] = {
+	REGULATOR_SUPPLY("VDD_CSIPHY1", "omap3isp"),	/* OMAP ISP */
+	REGULATOR_SUPPLY("VDD_CSIPHY2", "omap3isp"),	/* OMAP ISP */
+	{
+		.supply		= "vaux2",
+	},

Could also be
	REGULATOR_SUPPLY("vaux2", NULL),

+};
+REGULATOR_INIT_DATA_FIXED(rm680_vaux2, 1800000);
+
+static struct regulator_consumer_supply rm680_vaux3_consumers[] = {
+	REGULATOR_SUPPLY("VANA", "2-0037"),	/* Main Camera Sensor */
+	REGULATOR_SUPPLY("VANA", "2-000e"),	/* Main Camera Lens */
+	REGULATOR_SUPPLY("VANA", "2-0010"),	/* Front Camera */
+	{
+		.supply		= "vaux3",
+	},

and 	REGULATOR_SUPPLY("vaux3", NULL),

+};

--
Regards,
Sylwester
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux