]> git.baikalelectronics.ru Git - kernel.git/commit
staging: gasket: remove duplicate call to retrieve device callback
authorTodd Poynor <toddpoynor@google.com>
Sat, 21 Jul 2018 13:34:55 +0000 (06:34 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 24 Jul 2018 11:56:45 +0000 (13:56 +0200)
commite79350113892ccf15e7be0bb740cbbe294343b46
treee334f43b1a2d2627b2649887b30b8bf9e0ce261b
parent8a7ccc728e5061b7c9c26c8d85f3d5409568e244
staging: gasket: remove duplicate call to retrieve device callback

gasket_handle_ioctl() calls gasket_get_ioctl_permissions_cb() twice;
simplify the code and avoid duplicated work by fetching the callback
pointer only once.

Reported-by: Dmitry Torokhov <dtor@chromium.org>
Signed-off-by: Todd Poynor <toddpoynor@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/gasket/gasket_ioctl.c