Hi, Actually I want to write a single code using some macro to identify the kernel version and using preprocessor directives during preprocessing time which code snippet will be there, that I want to decide.... Like #if UTS_RELEASE == 2.6.9 some code #elif UTS_RELEASE == 2.6.13 some code #endif can I do this thanx for ur help, Kaustav -----Original Message----- From: Greg KH [mailto:greg@xxxxxxxxx] Sent: Monday, October 10, 2005 8:12 PM To: Kaustav Majumdar (WT01 - Semiconductors & Consumer Electronics) Cc: kernelnewbies@xxxxxxxxxxxx Subject: Re: writing driver code supporting multiple linux kernel versions On Mon, Oct 10, 2005 at 05:50:55PM +0530, kaustav.majumdar@xxxxxxxxx wrote: > > Is it possible??? No. Please remember that drivers are tied to kernel versions, you will need two different ones. Or, just get your driver into the main kernel tree and you will not have any problem at all... good luck, greg k-h -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/