aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/devinfo
Commit message (Collapse)AuthorAgeFilesLines
* devinfo: Support PCI DBSF and ACPI handles for -pJohn Baldwin2026-03-062-2/+78
| | | | | | | | | | | | When matching on a name of a device, match on ACPI handles and PCI selectors in addition to device names. This can be useful for matching on devices without an attached driver. For example: devinfo -p pci0:0:31:0 Reviewed by: imp Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D55673
* Correct Identifer typo in SPDX tagsEd Maste2026-02-181-1/+1
|
* Revert "devinfo: Add support for libxo"John Baldwin2025-12-153-193/+39
| | | | | | | | | | | | This broke the human output formatting in several ways. This reverts commit 4cf5878d27ddc9d3ca3ed870f88112c3b4f6fb69. This reverts commit e8d6b58ef5a4afe0d155b6967c92d55f3bbd53fe. This reverts commit c759aca606cee8352c1d739bf7a762c8a2ed2012. PR: 291511 Reviewed by: imp, des Differential Revision: https://reviews.freebsd.org/D54196
* devinfo.8: Document libxo supportAlexander Ziaee2025-08-291-1/+13
| | | | | | | | PR: 289151 Fixes: c759aca606cee (Add support for libxo) MFC after: 3 days Reviewed by: imp Closes: https://github.com/freebsd/freebsd-src/pull/1829
* devinfo.8: PolishAlexander Ziaee2025-08-291-11/+18
| | | | | | | | | | + replace "-*- nroff -*-" comment with SPDX tag + alphabetize options in SYNOPSIS and DESCRIPTION + add HISTORY, correct two minor mdoc typos MFC after: 3 days Reviewed by: imp Closes: https://github.com/freebsd/freebsd-src/pull/1829
* devinfo: Fix some libxo errorsWarner Losh2025-07-241-7/+6
| | | | | | | | Add missing names of fields, as exposed by --libxo:JPW Fixes: c759aca606cee Noticed by: phil Sponsored by: Netflix
* devinfo: Add support for libxoktullavik2025-05-062-38/+181
| | | | | | Reviewed by: imp Pull-Request: https://github.com/freebsd/freebsd-src/pull/1480 Closes: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Factor out helper functionktullavik2025-05-061-8/+13
| | | | | | | | This is prep for libxo. No functional change intended. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Rename function and move out printf of device namektullavik2025-05-061-9/+8
| | | | | | | | This is prep for libxo. No functional change intended. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Add missing function declarationsktullavik2025-05-061-0/+3
| | | | | | | No functional change intended. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Add helper functionktullavik2025-05-061-4/+11
| | | | | | | | This is prep for libxo. No functional change intended. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Rename function and add declarationktullavik2025-05-061-3/+4
| | | | | | | | This is prep for libxo. No functional change intended. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Restructure function in prep for libxoktullavik2025-05-061-5/+8
| | | | | | | No functional change intended. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Inline the code from print_resource()ktullavik2025-05-061-1/+18
| | | | | | | The code will diverge when libxo is added. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Put expression into variable in prep for libxoktullavik2025-05-061-1/+3
| | | | | | | | We'll need it twice when libxo is added. No functional change intended. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Turn '&&' into nested condition in prep for libxoktullavik2025-05-061-6/+13
| | | | | | | No functional change intended. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Unwind the ternary operator to better fit future libxo structurektullavik2025-05-061-4/+12
| | | | | | | No functional change intended. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Introduce function for printing indentktullavik2025-05-061-10/+21
| | | | | | | | | When libxo is added we want the whole indentation to be printed in a single call. Otherwise the html will be spammed with indentation tags. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Use bool instead of intktullavik2025-05-061-8/+10
| | | | | Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo: Add missing 'static'ktullavik2025-05-061-1/+1
| | | | | Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1480
* devinfo.8: Bump Dd for addition of -v to -u modeJohn Baldwin2025-01-291-1/+1
|
* devinfo: Distinguish resources owned by unnamed devices from free resourcesJohn Baldwin2025-01-292-4/+12
| | | | | | | | | For resources owned by an unnamed device, list the device name as "(unknown)" instead of using "----". In addition, if the -v flag is given, output the pnpinfo and location info for the device if present. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D48676
* devinfo: Output device description in verbose modeJohn Baldwin2024-10-161-0/+2
| | | | | | | | The description is listed in angle brackets after the device name similar to device probe messages. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D47157
* Remove residual blank line at start of MakefileWarner Losh2024-07-151-1/+0
| | | | | | | This is a residual of the $FreeBSD$ removal. MFC After: 3 days (though I'll just run the command on the branches) Sponsored by: Netflix
* usr.sbin: Automated cleanup of cdefs and other formattingWarner Losh2023-11-271-1/+0
| | | | | | | | | | | | | | | | Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row. Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/ Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/ Remove /\n+#if.*\n#endif.*\n+/ Remove /^#if.*\n#endif.*\n/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/ Sponsored by: Netflix
* Remove $FreeBSD$: two-line nroff patternWarner Losh2023-08-161-2/+0
| | | | Remove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/
* Remove $FreeBSD$: one-line sh patternWarner Losh2023-08-162-2/+0
| | | | Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
* Remove $FreeBSD$: one-line .c patternWarner Losh2023-08-161-2/+0
| | | | Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
* spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSDWarner Losh2023-05-121-1/+1
| | | | | | | | | The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause. Discussed with: pfg MFC After: 3 days Sponsored by: Netflix
* Update/fix Makefile.depend for userlandSimon J. Gerraty2023-04-191-1/+1
|
* pkgbase: Put devmatch in its own packageEmmanuel Vadot2022-10-261-0/+1
| | | | | | | devmatch is useful on standalone machine but not on jails. Put devinfo(8) and libdevinfo there too. Differential Revision: https://reviews.freebsd.org/D36229
* devinfo: xref devctlWarner Losh2022-07-051-1/+2
| | | | | | | devctl has ways to get the different locator's paths to devices, while devinfo does not. xref devctl in devinfo(8) as a hint. Sponsored by: Netflix
* devinfo(8): Remove cross-reference to pnpinfo(8)Felix Johnson2021-11-011-2/+1
| | | | | | | | | devinfo(8) manpage contains reference to pnpinfo(8) which existed at the time. Remove it. PR: 232587 MFC: 3 days Reported by: Graham Perrin <grahamperrin@gmail.com>
* Fix devinfo typo.Alexander Motin2021-01-051-1/+1
| | | | | | Submitted by: Nick Wolff <darkfiberiru@gmail.com> MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D27981
* devinfo_init() returns an errno, but doesn't set errno, so the errorWarner Losh2018-05-301-2/+5
| | | | | | | | message when it fails reflects some random thing rather than what it returned. Set errno to the return value. Notes: svn path=/head/; revision=334384
* When -v is specified with -p dev, print the same verbose output asWarner Losh2017-12-212-26/+41
| | | | | | | | | | when listing the whole tree. The list, however, is from the requested device to the root (so it backwards from the normal tree). Sponsored by: Netflix Notes: svn path=/head/; revision=327068
* Fix markup and bump .Dd.Warner Losh2017-12-211-4/+6
| | | | Notes: svn path=/head/; revision=327067
* Implement "-p dev" to print the path to the given device back to theWarner Losh2017-12-212-7/+48
| | | | | | | | | | nexus. With redirection, could also be used to test if the device exists in the device tree. Sponsored by: Netflix Notes: svn path=/head/; revision=327066
* various: general adoption of SPDX licensing ID tags.Pedro F. Giffuni2017-11-271-0/+2
| | | | | | | | | | | | | | | | | Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error prone - task. The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts. No functional change intended. Notes: svn path=/head/; revision=326276
* DIRDEPS_BUILD: Update dependencies.Bryan Drewery2017-10-311-1/+0
| | | | | | | Sponsored by: Dell EMC Isilon Notes: svn path=/head/; revision=325188
* Use uintmax_t (typedef'd to rman_res_t type) for rman ranges.Justin Hibbits2016-03-181-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On some architectures, u_long isn't large enough for resource definitions. Particularly, powerpc and arm allow 36-bit (or larger) physical addresses, but type `long' is only 32-bit. This extends rman's resources to uintmax_t. With this change, any resource can feasibly be placed anywhere in physical memory (within the constraints of the driver). Why uintmax_t and not something machine dependent, or uint64_t? Though it's possible for uintmax_t to grow, it's highly unlikely it will become 128-bit on 32-bit architectures. 64-bit architectures should have plenty of RAM to absorb the increase on resource sizes if and when this occurs, and the number of resources on memory-constrained systems should be sufficiently small as to not pose a drastic overhead. That being said, uintmax_t was chosen for source clarity. If it's specified as uint64_t, all printf()-like calls would either need casts to uintmax_t, or be littered with PRI*64 macros. Casts to uintmax_t aren't horrible, but it would also bake into the API for resource_list_print_type() either a hidden assumption that entries get cast to uintmax_t for printing, or these calls would need the PRI*64 macros. Since source code is meant to be read more often than written, I chose the clearest path of simply using uintmax_t. Tested on a PowerPC p5020-based board, which places all device resources in 0xfxxxxxxxx, and has 8GB RAM. Regression tested on qemu-system-i386 Regression tested on qemu-system-mips (malta profile) Tested PAE and devinfo on virtualbox (live CD) Special thanks to bz for his testing on ARM. Reviewed By: bz, jhb (previous) Relnotes: Yes Sponsored by: Alex Perez/Inertial Computing Differential Revision: https://reviews.freebsd.org/D4544 Notes: svn path=/head/; revision=297000
* Add META_MODE support.Simon J. Gerraty2015-06-131-0/+18
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | Off by default, build behaves normally. WITH_META_MODE we get auto objdir creation, the ability to start build from anywhere in the tree. Still need to add real targets under targets/ to build packages. Differential Revision: D2796 Reviewed by: brooks imp Notes: svn path=/head/; revision=284345
| * dirdeps.mk now sets DEP_RELDIRSimon J. Gerraty2015-06-081-2/+0
| | | | | | | | Notes: svn path=/projects/bmake/; revision=284172
| * Merge sync of headSimon J. Gerraty2015-05-272-2/+5
| |\ | |/ |/| | | Notes: svn path=/projects/bmake/; revision=283595
| * Merge head from 7/28Simon J. Gerraty2014-08-191-1/+1
| |\ | | | | | | | | | Notes: svn path=/projects/bmake/; revision=270164
| * | Updated dependenciesSimon J. Gerraty2014-05-161-1/+0
| | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=266219
| * | Updated dependenciesSimon J. Gerraty2014-05-101-0/+2
| | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=265802
| * | Updated dependenciesSimon J. Gerraty2013-03-111-0/+1
| | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=248169
| * | Updated dependenciesSimon J. Gerraty2013-02-161-2/+0
| | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=246868
| * | Sync FreeBSD's bmake branch with Juniper's internal bmake branch.Marcel Moolenaar2012-08-221-0/+19
| | | | | | | | | | | | | | | | | | | | | Requested by: Simon Gerraty <sjg@juniper.net> Notes: svn path=/projects/bmake/; revision=239572