[meta-freescale] speed of /dev/i2c-2 in imx6q sabre-lite

Thanassis Silis djnass_18 at hotmail.com
Wed Aug 14 08:40:48 PDT 2013


Hi Eric,
kernel configuration is no stranger to me as I am a longtime slackware user, but thank you for the info. It is always nice to know I have not understood something the wrong way.

What I do not know is how the IMX_I2C_BIT_RATE (which is 100kHz) is related to the imxi2c_platform_data structure.
The file drivers/i2c/busses/i2c_imx.c doesn't include arch/arm/mach-mx6/board_nitrogen6x.c (or _sabrelite.c for that matter) or vice-versa. So is it correct to say that i2c-imx.c sets the bitrate earlier in the boot process and then the platform specific code, overwrites/alters that value to what is set in board_nitrogen6x.c ?

Thank you!

> Date: Wed, 14 Aug 2013 07:28:04 -0700
> From: eric.nelson at boundarydevices.com
> To: djnass_18 at hotmail.com
> CC: meta-freescale at yoctoproject.org
> Subject: Re: [meta-freescale] speed of /dev/i2c-2 in imx6q sabre-lite
> 
> Hi Thanassis,
> 
> On 08/14/2013 05:25 AM, Thanassis Silis wrote:
> > Eric,
> > thank you very much for the answer (I have compiled kernel 3.0.35_1.1.0
> > by the way, but the code hasn't changed since then).
> > I do have a question (in my limited kernel knowledge) :)
> > https://github.com/boundarydevices/linux-imx6/blob/boundary-imx_3.0.35_4.0.0/drivers/i2c/busses/i2c-imx.c#L63
> >
> > this looks like a module, but as I see in my sabrelite's
> > /lib/modules/3.0.35-1.1.0+g2dc5560
> > modules.builtin:92:kernel/drivers/i2c/busses/i2c-imx.ko
> > it is built in the kernel.
> >
> > What is the purpose of i2c-imx and how does it relate to imx* boards?
> >
> i2c-imx is the device driver for the i2c part on many i.MX
> processors, including i.MX6.
> 
> Because it's needed for many internal operations, we compile it
> into the kernel, instead of as a separately loadable module.
> 
> This is a bit of "kernel configuration 101", but when you configure
> drivers into the Linux kernel, you can generally choose either
> "*" or "M", shown as "y" or "m" in the .config file:
> 	https://github.com/boundarydevices/linux-imx6/blob/boundary-imx_3.0.35_4.0.0/arch/arm/configs/nitrogen6x_defconfig#L144
> 
> When you choose '*' or 'y', the driver is included in the
> kernel itself (uImage on our normal usage).
> 
> If you choose 'm', the external .ko file is built.
> 
> This is mostly important at startup, since you have to have
> a working filesystem and utilities like 'modprobe' or 'insmod'
> to load a .ko file.
> 
> Regards,
> 
> 
> Eric
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/meta-freescale/attachments/20130814/24170134/attachment.html>


More information about the meta-freescale mailing list