[Bug 293076] ctld regression in FreeBSD 15: multiple physical ports per target rejected and ports not enabled automatically
[email protected] Wed, 27 May 2026 21:01:01 +0000
| Newsgroups | gmane.os.freebsd.devel.scsi |
|---|---|
| Message-ID | <[email protected]/bugzilla/> |
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D293076 --- Comment #26 from [email protected] --- A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=3Dd1a8fa2e0f415f941e628f959fa0e70f2= 3058fdb commit d1a8fa2e0f415f941e628f959fa0e70f23058fdb Author: John Baldwin <[email protected]> AuthorDate: 2026-05-27 20:57:38 +0000 Commit: John Baldwin <[email protected]> CommitDate: 2026-05-27 20:57:38 +0000 ctld: Only check physical port linking in a single configuration context Commit 969876fcee57 moved struct pport from being per-configuration to being a "global" object shared across multiple configurations. As a result, the check for duplicate ports actually spanned across configurations, such that reloading a configuration would now think that existing physical ports were already linked. The linking field in pport added in the C++-ification (commit 6acc7afa34aa) faithfully replicated this bug (albeit simpler as I had noticed that the TAILQ links weren't used after the earlier commit). To restore the desired behavior, remove the linking field from struct pport entirely and use a local unordered_map in conf::add_pports which tracks if a given pport is claimed by more than one target. PR: 293076 Reported by: Ken J. Thomson <[email protected]> Fixes: 969876fcee57 ("ctld: parse config file independently of getting kernel info") Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D57093 usr.sbin/ctld/ctld.cc | 12 +++++++----- usr.sbin/ctld/ctld.hh | 4 ---- 2 files changed, 7 insertions(+), 9 deletions(-) --=20 You are receiving this mail because: You are the assignee for the bug.=