summaryrefslogtreecommitdiffstats
path: root/usr.sbin/devctl/devctl.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/devctl/devctl.c')
-rw-r--r--usr.sbin/devctl/devctl.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/usr.sbin/devctl/devctl.c b/usr.sbin/devctl/devctl.c
index 076c650..545224b 100644
--- a/usr.sbin/devctl/devctl.c
+++ b/usr.sbin/devctl/devctl.c
@@ -259,6 +259,18 @@ set_driver(int ac, char **av)
}
DEVCTL_COMMAND(set, driver, set_driver);
+static int
+rescan(int ac, char **av)
+{
+
+ if (ac != 2)
+ usage();
+ if (devctl_rescan(av[1]) < 0)
+ err(1, "Failed to rescan %s", av[1]);
+ return (0);
+}
+DEVCTL_COMMAND(top, rescan, rescan);
+
int
main(int ac, char *av[])
{
OpenPOWER on IntegriCloud