summaryrefslogtreecommitdiff
path: root/drivers/tty/tty_io.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-07-30 13:26:39 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-07-30 13:26:39 +0200
commitf87da58b797aa591f2e288c7012faf3ab1e54c55 (patch)
treec1c991fe1350515a7b5ca01818f66f677cc0e14e /drivers/tty/tty_io.c
parentfb583c8eeeb1fd57e24ef41ed94c9112067aeac9 (diff)
parent36f3313d6bff91ab2a9e47698c27d15363640a4e (diff)
Merge branch 'generic_lookup_helpers' into driver-core-next
This was on a separate branch so that others can pull it in. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/tty_io.c')
-rw-r--r--drivers/tty/tty_io.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/tty/tty_io.c b/drivers/tty/tty_io.c
index 566728fbaf3c..802c1210558f 100644
--- a/drivers/tty/tty_io.c
+++ b/drivers/tty/tty_io.c
@@ -2952,17 +2952,11 @@ void do_SAK(struct tty_struct *tty)
EXPORT_SYMBOL(do_SAK);
-static int dev_match_devt(struct device *dev, const void *data)
-{
- const dev_t *devt = data;
- return dev->devt == *devt;
-}
-
/* Must put_device() after it's unused! */
static struct device *tty_get_device(struct tty_struct *tty)
{
dev_t devt = tty_devnum(tty);
- return class_find_device(tty_class, NULL, &devt, dev_match_devt);
+ return class_find_device_by_devt(tty_class, devt);
}