Re: Probe method vs attach method.

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

 




Are there any documentation on what the changes in the i2c modules are going from 2.6.22 to 2.6.31.
The driver which compiles and runs on 2.6.22 returns the following errors when compiled on 2.6.31.
I have included the correspondign lies from the code to clarify my predicament. Due to the current urgency I am sticking to the old binding method as the new method requires more indepth understanding. Are there ways to get over the following messages?

error: unknown field �detach_client� specified in initializer

device_create(lkmoz_class,NULL,lkomz_dev_number, LKOMZ_DEV_NAME)

=>error: too few arguments to function �device_create�

i2c_probe(adapter,&lkomz_addr_data,lkomz_attach)
=>error: implicit declaration of function �i2c_probe�

i2c_detach_client(client)
=>error: implicit declaration of function �i2c_detach_client�

make[1]: Leaving directory `/usr/src/kernels/linux-2.6.31'
make: *** [all] Error 2


Any help would be greatly appreciaetd.

Thanking you.

L Komz.


On Fri, Dec 4, 2009 at 10:19 PM, Greg KH <greg@xxxxxxxxx> wrote:
On Fri, Dec 04, 2009 at 02:29:36PM -0600, LKomz Komz wrote:
> Thanks Greg for the reply!
>
> I have an i2c driver written using the attach method for binding. It opens
> the device and reads the registers etc.
>
> The following document talks about another binding method.
> http://www.kernel.org/doc/Documentation/i2c/upgrading-clients
>
> Could you clarify that whether the new binding method is the way to go for
> i2c devices.

Yes, why would the document lie?

> Do I have to rewrite the current driver to make it compatible with
> future kernel versions.?

Yes.

The best thing for you to do is get it into the main kernel tree, then
it will remain compatible with future kernel versions as the API changes
over time.

thanks,

greg k-h


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux