xref: /freebsd/sbin/devmatch/devmatch.8 (revision 7cafeaa1fde93dbefa40971343bf9a3bb92f2ede)
1.\"
2.\" Copyright (c) 2017 Netflix, Inc
3.\"
4.\" All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:
9.\" 1. Redistributions of source code must retain the above copyright
10.\"    notice, this list of conditions and the following disclaimer.
11.\" 2. Redistributions in binary form must reproduce the above copyright
12.\"    notice, this list of conditions and the following disclaimer in the
13.\"    documentation and/or other materials provided with the distribution.
14.\"
15.\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS OR
16.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18.\" IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY DIRECT, INDIRECT,
19.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25.\"
26.\" $FreeBSD$
27.\"
28.Dd December 25, 2017
29.Dt DEVMATCH 8
30.Os
31.Sh NAME
32.Nm devmatch
33.Nd print information about unattached devices
34.Sh SYNOPSIS
35.Nm
36.Op Fl aduv
37.Op Fl -all
38.Op Fl -dump
39.Op Fl -unbound
40.Op Fl -verbose
41.Sh DESCRIPTION
42The
43.Nm
44utility, without any arguments, prints all the kernel modules it has
45found for all the unattached, enabled devices in the system.
46.Bl -tag -width 20m
47.It Fl a Fl -all
48Include all devices, not just the ones that are unattached.
49.It Fl d Fl -dump
50Produce a human readable dump of the
51.Pa linker.hints
52file.
53.It Fl u Fl -unbound
54Attempt to produce a list of those drivers with PNP info whose driver
55tables with that PNP info can't be found.
56.It Fl v Fl -verbose
57Produce more verbose output.
58.El
59.Sh SEE ALSO
60.Xr devinfo 8
61.Sh BUGS
62The kernel has hints in it, but we exclude it from the list of modules
63to suggest for unmatched devices.
64We exclude it when suggesting drivers, but include it when looking for
65unbound devices or producing a full dump of
66.Pa linker.hints .
67This can be confusing.
68.Pp
69Some modules are hard links in
70.Pa /boot/kernel
71and will be reported twice.
72.Pp
73The PNP string's attributes are evaluated once per PNP entry on that
74bus rather than once.
75.Pp
76The term PNP is overloaded in FreeBSD.
77It means, generically, the identifying data the bus provides about a
78device.
79While this include old ISA PNP identifiers, it also includes the
80logical equivalent in USB, PCI, and others.
81.Pp
82Many drivers currently lack proper PNP table decorations and need to
83be updated.
84.Sh AUTHORS
85.An Warner Losh Aq Mt imp@FreeBSD.org
86