]> git.baikalelectronics.ru Git - kernel.git/commit
expose a low-level variant of fd_install() for binder
authorAl Viro <viro@zeniv.linux.org.uk>
Thu, 16 Aug 2012 01:06:33 +0000 (21:06 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Thu, 27 Sep 2012 01:08:55 +0000 (21:08 -0400)
commit6d4a2f4a0fb3a3ef91ef6ed6fe6c82ea994bdd56
tree3b215f30a040812eb7488bd4596a5c3ae0b50e51
parentde818bc3cd55e6d9e007ed9b70701329c78f9e13
expose a low-level variant of fd_install() for binder

Similar situation to that of __alloc_fd(); do not use unless you
really have to.  You should not touch any descriptor table other
than your own; it's a sure sign of a really bad API design.

As with __alloc_fd(), you *must* use a first-class reference to
struct files_struct; something obtained by get_files_struct(some task)
(let alone direct task->files) will not do.  It must be either
current->files, or obtained by get_files_struct(current) by the
owner of that sucker and given to you.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
drivers/staging/android/binder.c
fs/file.c
include/linux/fdtable.h