This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: DEVIO table change
Bart Veer wrote:
>
> >>>>> "Grant" == Grant Edwards <grante@visi.com> writes:
>
> Grant> Would it be possible to include some sort of kernel version
> Grant> or kernel API version macro in the one of the eCos kernel
> Grant> header files so that a single driver can support multiple
> Grant> versions of the kernel?
>
> Actually, the kernel version macros do exist:
>
> #include <pkgconf/system.h>
> #ifdef CYGPKG_KERNEL_CURRENT
> ...
> #endif
>
> With current versions of the host-side tools there will also be
> definitions for CYGNUM_KERNEL_VERSION_MAJOR, _MINOR and _RELEASE which
> can be used for numerical comparisons in a #if, but that functionality
> was added after the 1.3.1 release.
But that's okay, because if those macros aren't defined, you know it's too
old :-).
Jifl
--
Red Hat, 35 Cambridge Place, Cambridge, UK. CB2 1NS Tel: +44 (1223) 728762
"Plan to be spontaneous tomorrow." || These opinions are all my own fault