lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <BANLkTi=wQaUSagZjptGnvUHNpJeMm0C6yw@mail.gmail.com>
Date:	Fri, 10 Jun 2011 01:16:13 -0400
From:	Arnaud Lacombe <lacombar@...il.com>
To:	Linus Torvalds <torvalds@...ux-foundation.org>
Cc:	Michal Marek <mmarek@...e.cz>, pefoley2@...izon.net,
	linux-kbuild@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [GIT] kbuild fixes for 3.0

Hi,

On Thu, Jun 9, 2011 at 11:57 PM, Linus Torvalds
<torvalds@...ux-foundation.org> wrote:
> On Thu, Jun 9, 2011 at 8:45 PM, Arnaud Lacombe <lacombar@...il.com> wrote:
>>
>> For the record, this should have been fixed by Michal in:
>
> You're missing the problem: we can't assume that people have updated user land.
>
I absolutely agree with you. But I am not the one about to decide to
break a 15 years old interface :) [I gave me a 5 year delta as I have
no idea how the version number was at that time; moreover, do not get
me wrong, I do not really care about the kernel version being 2 or 3
digits.].

> Furthermore, the very pull request I'm responding to actually tries to
> handle this, see commit bfe5424a8b31 ("kbuild: Hack for depmod not
> handling X.Y versions"), but it's just not working for me.
>
> And it's not working, because it only handles the "modules_install"
> case, not the case where the system install scripts do their own
> depmod.
>
I totally agree! But, it is a technical challenge to give a 2 digit
version number to an application expecting a 3 digit version number
without much control over its environment.

Beside that, no matter what, you are about to break
`/usr/sbin/sensors-detect' (from my Fedora 14), which rely on a 3
digits version number:

# [0] -> VERSION
# [1] -> PATCHLEVEL
# [2] -> SUBLEVEL
# [3] -> EXTRAVERSION
#
use vars qw(@kernel_version $kernel_arch);

sub initialize_kernel_version
{
        `uname -r` =~ /(\d+)\.(\d+)\.(\d+)(.*)/;
        @kernel_version = ($1, $2, $3, $4);
        chomp($kernel_arch = `uname -m`);

        # We only support kernels >= 2.6.5
        if (!kernel_version_at_least(2, 6, 5)) {
                print "Kernel version is unsupported (too old, >=
2.6.5 needed)\n";
                exit -1;
        }
}

sub kernel_version_at_least
{
        my ($vers, $plvl, $slvl) = @_;
        return 1 if ($kernel_version[0] > $vers ||
                     ($kernel_version[0] == $vers &&
                      ($kernel_version[1] > $plvl ||
                       ($kernel_version[1] == $plvl &&
                        ($kernel_version[2] >= $slvl)))));
        return 0;
}

would fail with:

Kernel version is unsupported (too old, >= 2.6.5 needed)

with "uname -r" being "3.0-rc2"

 - Arnaud
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ