Want to change the i2c bus frequency from other drivers

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Want to change the i2c bus frequency from other drivers

1,945 次查看
titusstalin
Contributor V

Dear All,

I have iMx6 Nitrogen board and Linux kernel version is 3.14.

I want to change the i2c bus frequency from other drivers.

Also need to get the i2c bus clock frequency from other drivers.

Can I export the symbol of "i2c_imx_set_clk" and use ?

Any other ideas ?

Thanks for the support.

Regards,

Titus S.

标签 (2)
0 项奖励
回复
3 回复数

1,176 次查看
igorpadykov
NXP Employee
NXP Employee

Hi Titus

one can look at entry in i2c1 in imx6q-sabrelite.dts

clock-frequency = <100000>

linux-2.6-imx.git - Freescale i.MX Linux Tree

Best regards

igor

-----------------------------------------------------------------------------------------------------------------------

Note: If this post answers your question, please click the Correct Answer button. Thank you!

-----------------------------------------------------------------------------------------------------------------------

0 项奖励
回复

1,176 次查看
titusstalin
Contributor V

Thank you.

But I need to get the bitrate (i2c bus clock) from other driver say for example Ethernet driver.

Yes, I can change the i2c bus clock in dts file but after boot, need to check what is the i2c frequency ?

Also I want to change/modify the i2c clock (to 400KHz) in run time after boot from other drivers.

I am expecting to use "i2c_imx_set_clk" API to change it but need to know how ?

0 项奖励
回复

1,176 次查看
igorpadykov
NXP Employee
NXP Employee

I am afraid changing bitrate dynamically is not supported in linux.

For procedure of changing bitrate please check reference manual i2c chapter.

~igor

0 项奖励
回复