Skip to content

feat(sbp2): add session registry and command flow#5

Closed
gly11 wants to merge 23 commits into
pr/foundation-async-discoveryfrom
pr/sbp2-session-core
Closed

feat(sbp2): add session registry and command flow#5
gly11 wants to merge 23 commits into
pr/foundation-async-discoveryfrom
pr/sbp2-session-core

Conversation

@gly11

@gly11 gly11 commented May 27, 2026

Copy link
Copy Markdown
Owner

Summary

This PR is stacked on pr/foundation-async-discovery and adds the SBP-2 session and command core on top of the foundation fixes.

SBP-2 Session Core

  • Add login, reconnect, and logout session state handling, including bus-reset retry behavior, busy-timeout replay, and unsolicited status setup
  • Add a session registry for discovered SBP-2 units and command lifecycle management
  • Add command submission helpers for standard SCSI command flow and task management
  • Wire SBP-2 session operations through ControllerCore, DriverContext, and the user-client handler

ORB and Addressing

  • Extend management and command ORB layout and status handling
  • Add full bus/node embedded-address handling and page-table/direct-descriptor updates
  • Add command wire formats for the user-client boundary

Tests

  • Add login-session and session-registry coverage
  • Extend ORB and address-space tests for timeout, status, embedded-address, and command lifecycle behavior

Why this PR

This layer adds SBP-2 session and command behavior without mixing in controller bring-up policy, Swift connector APIs, app UI, local diagnostic scripts, or documentation-only planning notes.

Verification

Local verification completed for this slice:

cmake -S . -B /tmp/asfw-pr19-build -DCMAKE_BUILD_TYPE=Debug
cmake --build /tmp/asfw-pr19-build --target AddressSpaceManagerTests SBP2ORBTests SBP2LoginSessionTests SBP2SessionRegistryTests --parallel 8
/tmp/asfw-pr19-build/tests/AddressSpaceManagerTests
/tmp/asfw-pr19-build/tests/SBP2ORBTests
/tmp/asfw-pr19-build/tests/SBP2LoginSessionTests
/tmp/asfw-pr19-build/tests/SBP2SessionRegistryTests
xcodebuild -project ASFW.xcodeproj -scheme ASFW -configuration Debug -destination 'platform=macOS' CODE_SIGNING_ALLOWED=NO build

@gly11 gly11 force-pushed the pr/sbp2-session-core branch 2 times, most recently from eff2132 to 76a8f1d Compare May 27, 2026 14:44
@gly11 gly11 force-pushed the pr/sbp2-session-core branch from 76a8f1d to 166b8a7 Compare May 27, 2026 14:59
@gly11

gly11 commented Jun 2, 2026

Copy link
Copy Markdown
Owner Author

Superseded by mrmidi#19, which has been merged. Closing this fork-side draft; follow-up SBP-2 work will be re-split against the current upstream architecture.

@gly11 gly11 closed this Jun 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants