Bug 291675 - libusb20_dev_open and libusb20_be_device_foreach each deserve man pages.
Summary: libusb20_dev_open and libusb20_be_device_foreach each deserve man pages.
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: usb (show other bugs)
Version: 15.0-RELEASE
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-usb (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-12-14 22:44 UTC by elephant
Modified: 2026-08-06 22:33 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description elephant 2025-12-14 22:44:17 UTC
Document libusb20_dev_open in man page form.
Document libusb20_be_device_foreach in man page form.

If / when approved, also document a new libusb20_dev_open variant (likely libusb20_dev_open_with_flags) that accepts a LIBUSB20_OPEN_EXCLUSIVE flag to provide exclusive device access. 

Stretch goal: also document libusb20_be_alloc_default. libusb20_be_alloc_linux and libusb20_be_alloc_freebsd seem to no longer work so update the main libusb20.3 man page accordingly.
Comment 1 elephant 2025-12-14 23:36:53 UTC
LIBUSB20_ERROR_BUSY reports that a stream is busy or that the same libusb20_device is already open. The device may be opened from a separate backend or a different process.
Comment 2 elephant 2025-12-15 07:30:50 UTC
Review is here: https://reviews.freebsd.org/D54231
Comment 3 commit-hook freebsd_committer freebsd_triage 2026-02-15 18:02:36 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/src/commit/?id=caf23c8e0b7981dd022c52feaf6edfef232f7e27

commit caf23c8e0b7981dd022c52feaf6edfef232f7e27
Author:     Rick Parrish <unitrunker@unitrunker.net>
AuthorDate: 2026-02-15 17:45:21 +0000
Commit:     Alexander Ziaee <ziaee@FreeBSD.org>
CommitDate: 2026-02-15 18:00:28 +0000

    libusb20: Add dev_open + be_device_foreach manuals

    Manual pages for libusb20_open(3) and libusb20_be_device_foreach(3).

    PR:                     291675
    MFC after:              3 days
    Reviewed by:            adrian (usb), ziaee (manpages)
    Differential Revision:  https://reviews.freebsd.org/D54231

 lib/libusb/Makefile                           |  6 +--
 lib/libusb/libusb20_be_device_foreach.3 (new) | 56 ++++++++++++++++++++++
 lib/libusb/libusb20_dev_open.3 (new)          | 69 +++++++++++++++++++++++++++
 3 files changed, 127 insertions(+), 4 deletions(-)
Comment 4 commit-hook freebsd_committer freebsd_triage 2026-04-10 18:32:25 UTC
A commit in branch stable/15 references this bug:

URL: https://cgit.FreeBSD.org/src/commit/?id=31711e1cc57d9538be648e29a2acb85c1cf62ea3

commit 31711e1cc57d9538be648e29a2acb85c1cf62ea3
Author:     Rick Parrish <unitrunker@unitrunker.net>
AuthorDate: 2026-02-15 17:45:21 +0000
Commit:     Alexander Ziaee <ziaee@FreeBSD.org>
CommitDate: 2026-04-10 18:26:40 +0000

    libusb20: Add dev_open + be_device_foreach manuals

    Manual pages for libusb20_open(3) and libusb20_be_device_foreach(3).

    PR:                     291675
    MFC after:              3 days
    Reviewed by:            adrian (usb), ziaee (manpages)
    Differential Revision:  https://reviews.freebsd.org/D54231

    (cherry picked from commit caf23c8e0b7981dd022c52feaf6edfef232f7e27)

 lib/libusb/Makefile                           |  6 +--
 lib/libusb/libusb20_be_device_foreach.3 (new) | 56 ++++++++++++++++++++++
 lib/libusb/libusb20_dev_open.3 (new)          | 69 +++++++++++++++++++++++++++
 3 files changed, 127 insertions(+), 4 deletions(-)
Comment 5 commit-hook freebsd_committer freebsd_triage 2026-08-06 22:33:14 UTC
A commit in branch stable/14 references this bug:

URL: https://cgit.FreeBSD.org/src/commit/?id=3e05b2366af1fa56907390d540a97e29f0f191dd

commit 3e05b2366af1fa56907390d540a97e29f0f191dd
Author:     Rick Parrish <unitrunker@unitrunker.net>
AuthorDate: 2026-02-15 17:45:21 +0000
Commit:     Alexander Ziaee <ziaee@FreeBSD.org>
CommitDate: 2026-08-06 22:21:32 +0000

    libusb20: Add dev_open + be_device_foreach manuals

    Manual pages for libusb20_open(3) and libusb20_be_device_foreach(3).

    PR:                     291675
    Relnotes:               yes
    MFC after:              3 days
    Reviewed by:            adrian (usb), ziaee (manpages)
    Differential Revision:  https://reviews.freebsd.org/D54231

    (cherry picked from commit caf23c8e0b7981dd022c52feaf6edfef232f7e27)

 lib/libusb/Makefile                           |  6 +--
 lib/libusb/libusb20_be_device_foreach.3 (new) | 56 ++++++++++++++++++++++
 lib/libusb/libusb20_dev_open.3 (new)          | 69 +++++++++++++++++++++++++++
 3 files changed, 127 insertions(+), 4 deletions(-)