Re: [beagleboard] [PATCH v5 2/2] Add support for mt9p031 (LI-5M03 module) in Beagleboard xM.

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

 



On Tuesday 31 May 2011 15:55:04 Guennadi Liakhovetski wrote:
> On Tue, 31 May 2011, Koen Kooi wrote:
> > Op 31 mei 2011, om 11:46 heeft Javier Martin het volgende geschreven:
> > > diff --git a/arch/arm/mach-omap2/board-omap3beagle-camera.c
> > > b/arch/arm/mach-omap2/board-omap3beagle-camera.c new file mode 100644
> > > index 0000000..04365b2
> > > --- /dev/null
> > > +++ b/arch/arm/mach-omap2/board-omap3beagle-camera.c
> > > 
> > > +static int __init beagle_camera_init(void)
> > > +{
> > > +	reg_1v8 = regulator_get(NULL, "cam_1v8");
> > > +	if (IS_ERR(reg_1v8))
> > > +		pr_err("%s: cannot get cam_1v8 regulator\n", __func__);
> > > +	else
> > > +		regulator_enable(reg_1v8);
> > > +
> > > +	reg_2v8 = regulator_get(NULL, "cam_2v8");
> > > +	if (IS_ERR(reg_2v8))
> > > +		pr_err("%s: cannot get cam_2v8 regulator\n", __func__);
> > > +	else
> > > +		regulator_enable(reg_2v8);
> > > +
> > > +	omap_register_i2c_bus(2, 100, NULL, 0);
> > > +	gpio_request(MT9P031_RESET_GPIO, "cam_rst");
> > > +	gpio_direction_output(MT9P031_RESET_GPIO, 0);
> > > +	omap3_init_camera(&beagle_isp_platform_data);
> > > +	return 0;
> > > +}
> > > +late_initcall(beagle_camera_init);
> > 
> > There should probably a if (cpu_is_omap3630()) {} wrapped around that, so
> > the camera doesn't get initted on a 3530 beagle.
> 
> ...speaking of which - if multiarch kernels are supported by OMAP3 you
> probably want to use something like
> 
> 	if (!machine_is_omap3_beagle() || !cpu_is_omap3630())
> 		return;

Shouldn't you check the Beagleboard version instead? The OMAP3530 has an ISP, 
so there's nothing wrong with it per-se.

-- 
Regards,

Laurent Pinchart
--
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