feat(mailbox): Mailbox driver implementation and host unit tests #100
No reviewers
Labels
No labels
Category
App
Category
Documentation
Category
Firmware
Category
Hardware
Category
Qms
PR_Size
L
PR_Size
M
PR_Size
S
PR_Size
XL
PR_Size
XS
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Priority
Very Low Priority
Size
Epic
Size
Feature
Size
Task
Status
Blocked
Status
Draft
Status
Needs-review
Team
Board
Team
Dev
Team
Management
Type
Bug
Type
Capa
Type
Improvement
Type
New-feature
Type
Regulatory
Type
Usability
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
opendutchsolutions.public/hal_awr6843!100
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feat/99-mailbox-driver"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Description
Adds
hal/dss/hal_mailbox/hal_mailbox.c/.h— the inter-processor Mailbox driver (MSS's point of view, covering both the MSS<->BSS and MSS<->DSS links):hal_mailbox_send(),hal_mailbox_message_pending(),hal_mailbox_receive(), and the four raw device handlers (MBOX_MSS_DSS_BOX_FULL_IRQHandler/MBOX_MSS_DSS_BOX_EMPTY_IRQHandler/MBOX_MSS_BSS_BOX_FULL_IRQHandler/MBOX_MSS_BSS_BOX_EMPTY_IRQHandler) decoding/clearing the CPU interrupt condition to a weak, application-overridablehal_mailbox_irq_handler()hook. Self-contained — no cross-module dependency.This is the first driver of a second, DSS-side driver batch — landed first since
hal_vim.c's already-merged dispatch table references its fourMBOX_*handler symbols directly.Why
Continues the driver-implementation phase, moving into the DSS-side batch after completing the MSS-side batch (GPIO through MCAN, #75-#98).
Related Issue
Closes #99
Type of Change
Impact Assessment
Testing
testing/dss/hal_mailbox/test_mailbox_functionallocally (9 test cases, 65 assertions, all passing) alongside the full existingctestsuite (338/338 passing, no regressions); ran a full MISRA C:2025 pass (0 unsuppressed findings,-DENABLE_MAILBOX_MODULEadded —hal/dssis picked up automatically byrun_misra.sh's existing directory loop, first driver to exercise that path); reformatted and re-verified against the exact clang-format 18.1.3 the CI runner uses; sanity-checked by swappinghal_mailbox_send()'s doorbell strobe fromMAILBOX_INT_TRIG_MAILBOXtoMAILBOX_INT_TRIG_MAILBOX_ACK, confirming the test suite fails (2 test cases, 5 assertions), then reverting.PR Size
Size justification / exemption (if L or XL):
682 raw lines across 6 files, all hand-reviewed (no mechanically-generated content). Not split further — the driver (
hal_mailbox.c/.h, 403 lines) and its comprehensive Catch2 spec (test_mailbox.c, 271 lines, covering both links' send/receive/pending paths and all four IRQ handlers' correct register-block resolution) don't decompose into independently-reviewable sub-PRs, same rationale as every prior driver PR in this project. The remaining files are small CMake/MISRA wiring diffs, also not independently reviewable apart from the driver they enable.Checklist
type(scope): descriptionconvention withRelates to #<issue>footerSummary
hal/dss/hal_mailbox/hal_mailbox.c/.h: Mailbox driver (send/receive/pending, IRQ handlers)testing/dss/hal_mailbox/test_mailbox.c(+CMakeLists.txt): Catch2 functional test suite. Namedtest_mailbox_functional(nottest_mailbox) to avoid a CMake target-name collision withti_hal_comparison/test_mailbox.c's register-layout comparison test.testing/CMakeLists.txt:add_subdirectory(dss/hal_mailbox)— first DSS-side host-functionality test subdirectory, alongsideENABLE_MAILBOX_MODULEin the sharedhw_fakescompile definitionstools/misra/run_misra.sh:-DENABLE_MAILBOX_MODULEadded