lkml.org 
[lkml]   [2008]   [Nov]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] usb/serial: Add compat_ioctl pass-through
From
Date
On Fri, 2008-11-28 at 22:33 +0000, Alan Cox wrote:

> Can never be used only overwritten so why not replace with -ENOIOCTLCMD
> and remove the else of the if

Yeah, of course.

> Also I get a CodingStyle whine about the port->serial-> side of the if
> not needing { }

Oops. Changed when I removed the bkl calls.

> No... the ioctl path for tty comes from unlocked_ioctl so the BKL is not
> held and should not be held.

Oh yes, it is -- serial_ioctl does:

if (port->serial->type->ioctl) {
lock_kernel();
retval = port->serial->type->ioctl(tty, file, cmd, arg);
unlock_kernel();
} else

I added the comment to make the difference in calling convention
documented in the header file at least, I didn't change the code.

--
keith.packard@intel.com
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2008-11-29 02:05    [W:0.122 / U:0.064 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site