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]
Date:	Tue, 28 Feb 2012 11:39:09 -0800
From:	Linus Torvalds <torvalds@...ux-foundation.org>
To:	Andreas Schwab <schwab@...ux-m68k.org>
Cc:	Mark Lord <kernel@...savvy.com>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: Linux 3.3-rc5

On Tue, Feb 28, 2012 at 11:29 AM, Andreas Schwab <schwab@...ux-m68k.org> wrote:
>
> Originally the garbage looked like this:
>
> #define I8K_BIOS_VERSION       _IOR ('i', 0x80, 4)
> #define I8K_MACHINE_ID         _IOR ('i', 0x81, 16)
> #define I8K_POWER_STATUS       _IOR ('i', 0x82, sizeof(int))
> #define I8K_FN_STATUS          _IOR ('i', 0x83, sizeof(int))
> #define I8K_GET_TEMP           _IOR ('i', 0x84, sizeof(int))
> #define I8K_GET_SPEED          _IOWR('i', 0x85, sizeof(int))
> #define I8K_GET_FAN            _IOWR('i', 0x86, sizeof(int))
> #define I8K_SET_FAN            _IOWR('i', 0x87, sizeof(int)*2)
>
> Later they were modified by "[PATCH] use size_t for the broken ioctl
> numbers" and "Fix more ioctl _IOR/_IOW misusage." (see tglx's history
> tree).

Ahh, yes. That wasn't the only driver that did the "sizeof" by hand,
and as a result got "size_t" when the (nested) *real* sizeof then
happened.

That explains the history behind the garbage.

ioctl numbering have always been pretty painful. Oh, how I wish they
had been ASCII strings rather than random binary blobs. But that's the
way things are (and we certainly screwed up a few /proc files too, so
it's not like using text fixes all potential for screwing up)

                 Linus
--
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