aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/devctl
Commit message (Collapse)AuthorAgeFilesLines
* 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/
* Update/fix Makefile.depend for userlandSimon J. Gerraty2023-04-191-1/+0
|
* man pages: Fix typoChristian Weisgerber2022-04-071-1/+1
| | | | | | s/the the/the/ Approved by: ygy (doc)
* devctl: add getpath commandWarner Losh2022-03-012-1/+39
| | | | | | | | | Retrieves that path for a device. Different methods to enumerat the path are supported, called locators. Sponsored by: Netflix Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D32747
* Add freeze/thaw description to devctl(8)Li-Wen Hsu2021-06-011-1/+22
| | | | | | | | | This is a follow-up to 5fa29797910346fc0c54829bd979856e83b9b7ea . PR: 256311 Reviewed by: imp MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D29867
* devctl(8): Correct "sections out of conventional order" errorGordon Bergling2020-12-191-5/+5
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=368808
* Fix gcc warning about shadowed global.Konstantin Belousov2019-04-051-4/+4
| | | | | | | | Sponsored by: Mellanox Technologies MFC after: 2 weeks Notes: svn path=/head/; revision=345968
* Implement devctl(8) command 'reset', using DEV_RESET /dev/devctl2 ioctl.Konstantin Belousov2019-04-052-2/+70
| | | | | | | | | | Reviewed by: imp (previous version), jhb (previous version) Sponsored by: Mellanox Technologies MFC after: 2 weeks Differential revision: https://reviews.freebsd.org/D19646 Notes: svn path=/head/; revision=345966
* Drop "All rights reserved" from my copyright statements.John Baldwin2019-03-062-2/+0
| | | | | | | | | Reviewed by: rgrimes MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D19485 Notes: svn path=/head/; revision=344855
* Create devctl freeze/thaw.Warner Losh2018-08-231-11/+53
| | | | | | | | | | | | This adds it to devctl, libdevctl, defines the two IOCTLs and implements the kernel bits. causes any new drivers that are added via kldload to be deferred until a 'thaw' comes in. These do not stack: it is an error to freeze while frozen, or thaw while thawed. Differential Revision: https://reviews.freebsd.org/D16735 Notes: svn path=/head/; revision=338233
* DIRDEPS_BUILD: Update dependencies.Bryan Drewery2017-10-311-1/+0
| | | | | | | Sponsored by: Dell EMC Isilon Notes: svn path=/head/; revision=325188
* o Missed flag restored.Maxim Konovalov2017-05-191-1/+1
| | | | | | | | PR: 219395 Submitted by: Tiwei Bie Notes: svn path=/head/; revision=318550
* Implement 'devctl clear driver' to undo a previous 'devctl set driver'.John Baldwin2016-08-292-2/+57
| | | | | | | | | | | | | | | Add a new 'clear driver' command for devctl along with the accompanying ioctl and devctl_clear_driver() library routine to reset a device to use a wildcard devclass instead of a fixed devclass. This can be used to undo a previous 'set driver' command. After the device's name has been reset to permit wildcard names, it is reprobed so that it can attach to newly-available (to it) device drivers. MFC after: 1 month Sponsored by: Chelsio Communications Notes: svn path=/head/; revision=305034
* Add 'devctl delete' that calls device_delete_child().John Baldwin2016-04-272-2/+54
| | | | | | | | | | | | | | | | 'devctl delete' can be used to delete a device that is no longer present. As an anti-foot-shooting measure, 'delete' will not delete a device unless it's parent bus says it is no longer present. This can be overridden by passing the force ('-f') flag. Note that this command should be used with care. If a device is deleted that is actually present it can't be resurrected unless the parent bus device's driver supports rescans. Differential Revision: https://reviews.freebsd.org/D6019 Notes: svn path=/head/; revision=298709
* Add a new rescan method to the bus interface.John Baldwin2016-04-272-1/+19
| | | | | | | | | | | The BUS_RESCAN() method rescans a single bus device checking for devices that have been added or removed from the bus. A new 'rescan' command is added to devctl(8) to trigger a rescan. Differential Revision: https://reviews.freebsd.org/D6016 Notes: svn path=/head/; revision=298707
* - Note that devctl(8) will appear in 10.3 first.John Baldwin2016-02-021-2/+2
| | | | | | | | | | - Add missing devctl_set_driver entry to namelist in devlist(3). - Fix sorting of function prototypes in devlist(3). MFC after: 3 days Notes: svn path=/head/; revision=295174
* META MODE: Update dependencies with 'the-lot' and add missing directories.Bryan Drewery2015-12-011-0/+19
| | | | | | | | | | | | | | | | | This is not properly respecting WITHOUT or ARCH dependencies in target/. Doing so requires a massive effort to rework targets/ to do so. A better approach will be to either include the SUBDIR Makefiles directly and map to DIRDEPS or just dynamically lookup the SUBDIR. These lose the benefit of having a userland/lib, userland/libexec, etc, though and results in a massive package. The current implementation of targets/ is very unmaintainable. Currently rescue/rescue and sys/modules are still not connected. Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=291563
* Fix formatting.Justin Hibbits2015-07-161-1/+1
| | | | Notes: svn path=/head/; revision=285621
* install the man page...John-Mark Gurney2015-02-161-1/+0
| | | | | | | Sponsored by: FreeBSD Foundation Notes: svn path=/head/; revision=278830
* Add a new device control utility for new-bus devices called devctl. ThisJohn Baldwin2015-02-063-0/+428
allows the user to request administrative changes to individual devices such as attach or detaching drivers or disabling and re-enabling devices. - Add a new /dev/devctl2 character device which uses ioctls for device requests. The ioctls use a common 'struct devreq' which is somewhat similar to 'struct ifreq'. - The ioctls identify the device to operate on via a string. This string can either by the device's name, or it can be a bus-specific address. (For unattached devices, a bus address is the only way to locate a device.) Bus drivers register an eventhandler to claim unrecognized device names that the driver recognizes as a valid address. Two buses currently support addresses: ACPI recognizes any device in the ACPI namespace via its full path starting with "\" and the PCI bus driver recognizes an address specification of 'pci[<domain>:]<bus>:<slot>:<func>' (identical to the PCI selector strings supported by pciconf). - To make it easier to cut and paste, change the PnP location string in the PCI bus driver to output a full PCI selector string rather than 'slot=<slot> function=<func>'. - Add a devctl(3) interface in libdevctl which provides a wrapper around the ioctls and is the preferred interface for other userland code. - Add a devctl(8) program which is a simple wrapper around the requests supported by devctl(3). - Add a device_is_suspended() function to check DF_SUSPENDED. - Add a resource_unset_value() function that can be used to remove a hint from the kernel environment. This is used to clear a hint.<driver>.<unit>.disabled hint when re-enabling a boot-time disabled device. Reviewed by: imp (parts) Requested by: imp (changing PCI location string) Relnotes: yes Notes: svn path=/head/; revision=278320