I think that we tried to isolate a lot of these kernel calls into one library, the component library, so that when the kernel APIs change, which seems to happen every release, we only have to change the code in one spot. This actually helps porting to new kernels. For example, I think that it only took a week to get the IBAL code to compile on 2.6 since all or most of the kernel dependencies were isolated to one module. It also then allows most of the code to remain very readable, since we don't have to put #ifdefs all over the place when an API or kernel data structure changes. Are there any other examples of drivers that isolate kernel specific calls to one module or file of their code to ease portability between different revisions of the kernel ? If not, maybe they should look at what we have done, it might save them some headaches in the future. -----Original Message----- From: infiniband-general-admin _at_ lists.sourceforge.net [mailto:infiniband-general-admin _at_ lists.sourceforge.net] On Behalf Of King, Steven R Sent: Thursday, February 05, 2004 11:39 AM To: Greg KH; linux-kernel _at_ vger.kernel.org Cc: infiniband-general _at_ lists.sourceforge.net Subject: RE: [Infiniband-general] Getting an Infiniband access layer in the linux kernel We just use the kernel's spin_lock_irqsave(), so I don't know what you're talking about. -----Original Message----- From: Greg KH [mailto:greg _at_ kroah.com] Sent: Thursday, February 05, 2004 10:55 AM To: King, Steven R; linux-kernel _at_ vger.kernel.org Cc: infiniband-general _at_ lists.sourceforge.net Subject: Re: [Infiniband-general] Getting an Infiniband access layer in the linux kernel On Thu, Feb 05, 2004 at 10:27:54AM -0800, King, Steven R wrote: > Hi Greg, > What exactly is wrong with spinlock? Far as I know, it's been working > bug-free on a variety of platforms for quite some time now. The other > abstractions such as atomic_t are for platform portability. Again, compare them to the current kernel spinlocks and try to realize why your implementation of spinlock_irqsave() will not work on all platforms. Come on, just use the kernel versions, there is no need to reinvent the wheel all of the time, it just wastes everyones time (including mine...) thanks, greg k-h ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Infiniband-general mailing list Infiniband-general _at_ lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/infiniband-general - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo _at_ vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Follow-Ups:
- Re: [Infiniband-general] Getting an Infiniband access layer in the linux kernelGreg KH
- Infiniband thread(s) and etiquette.David Woodhouse
- Prev by Date: Re: 2.6.2-mm1 aka "Geriatric Wombat"
- Next by Date: Re: [Infiniband-general] Getting an Infiniband access layer in the Linux kernel
- Previous by thread: Re: [Infiniband-general] Getting an Infiniband access layer in the linux kernel
- Next by thread: Re: [Infiniband-general] Getting an Infiniband access layer in the linux kernel
- Indexes:[Main][Thread]