From: Luis.F.Correia <Lui...@se...> - 2005-04-05 08:00:19
|
Hi Michael, > -----Original Message----- > From: Michael Reinelt [mailto:re...@eu...] > Sent: Tuesday, April 05, 2005 8:53 AM > To: lcd4linux-devel > Subject: Re: [Lcd4linux-devel] Re: fixes to the i2c patch > that Luis suppli ed > > Hi Luis, > > > Try this, go to your current kernel source and enable I2C support. > > Then, run make dep. > > I do have I2C support enabled. ANd 'make dep' gives me > > merlin.ethnet:/usr/src/linux # make dep > *** Warning: make dep is unnecessary now. > > on my 2.6.11 kernel :-) Are you absolutely sure that that's your running kernel? In my Fedora system, the source can be looked at /lib/modules/(kernel-version)/build if i'm not mistaken... Anyway, you must have something broken over there, I just don't know what... > > > nice try! :-) > > > bye, michael > > -- > Michael Reinelt <re...@eu...> > http://home.pages.at/reinelt > GPG-Key 0xDF13BA50 > ICQ #288386781 Luis |
From: Luis.F.Correia <Lui...@se...> - 2005-04-05 09:08:24
|
Hi! > -----Original Message----- > From: Michael Reinelt [mailto:re...@eu...] > Sent: Tuesday, April 05, 2005 9:42 AM > To: lcd4linux-devel > Subject: Re: [Lcd4linux-devel] Re: fixes to the i2c patch > that Luis suppli ed > > Sorry for the first post, hit the wrong button :-) > > >>on my 2.6.11 kernel :-) > > Are you absolutely sure that that's your running kernel? > > Yes, I am. Absolutely very shure. > > > In my Fedora system, the source can be looked at > > /lib/modules/(kernel-version)/build > > if i'm not mistaken... > I'm using debian, but none of the debian kernels, but my own vanilla > homebrew kernel 2.6.11 from kernel.org. > > > Anyway, you must have something broken over there, I just > don't know what... > Yes, there *is* something broken here. It has something to do with the > i2c.h file. It includes lots of other files, which should be used only > when compiling the kernel. > > A ugly workaround would be to extract the needed symbols from > i2c.h and > hardcode them into drv_generic_i2c. But, as I said, ugly ugly ugly.... > > Is there any other sowftware out there which uses the i2c subsystem? I > once had a look into lm_sensors, but they do not really use the i2c > interface, but the various files in /proc or /sys only. Well, to be able to talk with I2C devices, some drivers must be present. lm_sensors does use i2c interface, in fact they were the originators of the current I2C support in Linux. But I really don't have an answer to your particular problem. I'll ask my other Linux co-workers for possible workarounds... > > bye, Michael > > -- > Michael Reinelt <re...@eu...> Luis Correia |
From: Michael R. <re...@eu...> - 2005-04-05 08:47:07
|
Sorry for the first post, hit the wrong button :-) >>on my 2.6.11 kernel :-) > Are you absolutely sure that that's your running kernel? Yes, I am. Absolutely very shure. > In my Fedora system, the source can be looked at > /lib/modules/(kernel-version)/build > if i'm not mistaken... I'm using debian, but none of the debian kernels, but my own vanilla homebrew kernel 2.6.11 from kernel.org. > Anyway, you must have something broken over there, I just don't know what... Yes, there *is* something broken here. It has something to do with the i2c.h file. It includes lots of other files, which should be used only when compiling the kernel. A ugly workaround would be to extract the needed symbols from i2c.h and hardcode them into drv_generic_i2c. But, as I said, ugly ugly ugly.... Is there any other sowftware out there which uses the i2c subsystem? I once had a look into lm_sensors, but they do not really use the i2c interface, but the various files in /proc or /sys only. bye, Michael -- Michael Reinelt <re...@eu...> http://home.pages.at/reinelt GPG-Key 0xDF13BA50 ICQ #288386781 |
From: paul k. <pau...@xs...> - 2005-04-05 09:13:14
|
>Yes, there *is* something broken here. It has something to do with the >i2c.h file. It includes lots of other files, which should be used only >when compiling the kernel. > > > So if I understand correctly, you have (for some reason) this __KERNEL__ define set. That is strange. That should only be set when compiling the actual kernel, ie compile for kernel space use. We want to use it in user space. So __KERNEL__ should not be defined. Can you verify your default compiler settings? or the environment variables (probably using a windows term here)? >A ugly workaround would be to extract the needed symbols from i2c.h and >hardcode them into drv_generic_i2c. But, as I said, ugly ugly ugly.... > >Is there any other sowftware out there which uses the i2c subsystem? I >once had a look into lm_sensors, but they do not really use the i2c >interface, but the various files in /proc or /sys only. > >bye, Michael > > That is too ugly for me too. Would it be possible to undefine __KERNEL__ prior to building L4L? If I am not mistaken, the only reason we need this i2c stuff, is for the i2c_smbus* definitions. I am not sure how lm_sensors handle these issues. Actually I think I know. /proc and /sys require kernel space drivers to perform the i2c actions. However I would expect that 'i2cdetect' would do it directly. And I do know that lm_sensors does require the 2.6 kernel headers installed for the i2c support. On kernel 2.4 lm_sensors had their own set of i2c includes. Paul |