]> Git Repo - linux.git/commitdiff
xhci: dbgtty: Make some functions static
authorWei Yongjun <[email protected]>
Mon, 27 Jul 2020 17:11:49 +0000 (01:11 +0800)
committerGreg Kroah-Hartman <[email protected]>
Tue, 28 Jul 2020 11:15:01 +0000 (13:15 +0200)
The sparse tool complains as follows:

drivers/usb/host/xhci-dbgtty.c:401:5: warning:
 symbol 'xhci_dbc_tty_register_device' was not declared. Should it be static?
drivers/usb/host/xhci-dbgtty.c:452:6: warning:
 symbol 'xhci_dbc_tty_unregister_device' was not declared. Should it be static?

After commit 6ae6470bfa33 ("xhci: dbc: Add a operations structure
to access driver functions"), those functions are not used outside
of xhci-dbgtty.c, so this commit marks them static.

Fixes: 6ae6470bfa33 ("xhci: dbc: Add a operations structure to access driver functions")
Reported-by: Hulk Robot <[email protected]>
Signed-off-by: Wei Yongjun <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>
drivers/usb/host/xhci-dbgtty.c

index 0b942112b6f8400f124b5bd870b32499a5e9ca10..b8918f73a432ebe4d0eb21f5388407b6cdde6ef7 100644 (file)
@@ -398,7 +398,7 @@ xhci_dbc_tty_exit_port(struct dbc_port *port)
        tty_port_destroy(&port->port);
 }
 
-int xhci_dbc_tty_register_device(struct xhci_dbc *dbc)
+static int xhci_dbc_tty_register_device(struct xhci_dbc *dbc)
 {
        int                     ret;
        struct device           *tty_dev;
@@ -449,7 +449,7 @@ register_fail:
        return ret;
 }
 
-void xhci_dbc_tty_unregister_device(struct xhci_dbc *dbc)
+static void xhci_dbc_tty_unregister_device(struct xhci_dbc *dbc)
 {
        struct dbc_port         *port = dbc_to_port(dbc);
 
This page took 0.051412 seconds and 4 git commands to generate.