[PATCH] ENOTTY for nvram ioctl
authorRusty Russell <rusty@rustcorp.com.au>
Mon, 22 Apr 2002 06:10:28 +0000 (23:10 -0700)
committerLinus Torvalds <torvalds@home.transmeta.com>
Mon, 22 Apr 2002 06:10:28 +0000 (23:10 -0700)
commit786ae877ceed3e7f6845ccfb92156f71329702e6
tree35cdddfdeebfb6b837656e8445d263aa5dd6bd69
parent8018e670c7b3249ac3602350e28a52453a930a18
[PATCH] ENOTTY for nvram ioctl

Paul Gortmaker <p_gortmaker@yahoo.com>: ENOTTY for nvram ioctl:
   ioctl(d, valid, crap) --> -EINVAL
   ioctl(d, crap, ....)  --> -ENOTTY

  man ioctl agrees:

         ENOTTY The specified request does not apply to the kind of
                object that the descriptor d references.

  Currently we return -EINVAL for both cases which is not as
  informative for debugging stuff.

  Patch is for 2.5.6 but applies cleanly (with minor offset) to 2.4.19p2

  Paul.

(Included in 2.2)
(Included in 2.4)
drivers/char/nvram.c