[lkml]   [2012]   [Feb]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: Linux 3.3-rc5
Linus Torvalds <> writes:

> I also think that your explanation is wrong. The problem is not the
> use of _IOR() at all, the problem is that the data structure given
> *to* the _IOR() macro is complete grabage. For example:
> #define I8K_GET_SPEED _IOWR('i', 0x85, size_t)

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


Andreas Schwab,
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."

 \ /
  Last update: 2012-02-28 20:31    [W:0.109 / U:5.776 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site