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

Bug#783259: Debian kernel API for 3.16.7



Hi Ben,

Ben Hutchings <ben@decadent.org.uk> wrote:
> On Fri, 2015-04-24 at 15:28 -0400, Jon Bernard wrote:
[...]
> > This is fine, if we could have a way to distinguish between upstream
> > 3.16.7 and our version.  It appears that Ubuntu kernels introduce
> > a UTS_UBUNTU_RELEASE_ABI into their kernels, which can be used to follow
> > their own kernel versions.  Could we perhaps do the same?
> 
> I used to maintain OOT modules myself, trying to support basically every
> distribution as well as mainline and stable kernels.  Version tests just
> don't scale to this.  Instead, you need to use some kind of a configure
> script to check the API of your target kernel.

Using version tests, we have scaled LTTng modules to support every kernels
released over the past 5 years, from 2.6.36 to 4.0, including mainline and
stable releases, as well as distribution kernels for every major distribution
out there.

I understand that this approach has not scaled well for your use case, but
it appears to work pretty well for us.

> 
> > Without the ability to do conditionals comparing numeric values both in
> > Makefiles and within C, I am not sure how tell the two different kernels
> > apart, and therefore am rather stuck.
> 
> ABI changes are indicated by bumping the number after the dash in the
> kernel version string (3.16.0-3 to 3.16.0-4).  But you actually need to
> know about the API, not the ABI.  Not all changes to the API change the
> ABI, and vice versa.

Good point, the ABI is not exactly what we need to track. This should
perhaps be referred to as a publicly exposed API then. Still, it would
greatly help us to have this version number available as a numeric value.

Thanks,

Mathieu

> 
> Ben.

-- 
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com


Reply to: