Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bluetooth: Controller: Remove unneeded members from ull_hdr #87216

Merged

Conversation

Tronil
Copy link
Collaborator

@Tronil Tronil commented Mar 17, 2025

Several members of the ull_hdr can be removed, saving 12 bytes from all ULL instances used (and a bit of code as well)

ticks_active_to_start is always 0 and can be removed completely

ticks_prepare_to_start is always set to
HAL_TICKER_US_TO_TICKS(EVENT_OVERHEAD_XTAL_US), so replace usage of it by this constant

ticks_preempt_to_start is always set to
HAL_TICKER_US_TO_TICKS(EVENT_OVERHEAD_PREEMPT_MIN_US), so replace usage of it by this constant

In addition, remove logic handling usage of XON_BITMASK since it was only used by the long removed legacy LL

Several members of the ull_hdr can be removed, saving 12 bytes
from all ULL instances used (and a bit of code as well)

ticks_active_to_start is always 0 and can be removed completely

ticks_prepare_to_start is always set to
HAL_TICKER_US_TO_TICKS(EVENT_OVERHEAD_XTAL_US), so replace usage
of it by this constant

ticks_preempt_to_start is always set to
HAL_TICKER_US_TO_TICKS(EVENT_OVERHEAD_PREEMPT_MIN_US), so replace
usage of it by this constant

In addition, remove logic handling usage of XON_BITMASK since it
was only used by the long removed legacy LL

Signed-off-by: Troels Nilsson <trnn@demant.com>
Copy link
Collaborator

@erbr-ot erbr-ot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeap

@kartben kartben merged commit e486a06 into zephyrproject-rtos:main Mar 25, 2025
27 checks passed
@Tronil Tronil deleted the remove-unneeded-members-from-ull_hdr branch March 26, 2025 08:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants