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

mgmt: mcumgr: Add iterable section to register MCUmgr handlers #52923

Merged
merged 6 commits into from Dec 22, 2022

Conversation

nordicjm
Copy link
Collaborator

@nordicjm nordicjm commented Dec 9, 2022

mgmt: mcumgr: Add iterable section to register MCUmgr handlers

This replaces the requirement for applications to manually
register MCUmgr handlers by having an iterable section which
then automatically registers the handlers at boot time.
  • Update code
  • Update samples
  • Documentation update There is no documentation about creating handlers, we should probably add this some time
  • Release notes update
  • Rework transports
  • Re-think bluetooth registration due to how mesh sample works

@nordicjm nordicjm added this to In progress in mcumgr via automation Dec 9, 2022
@zephyrbot zephyrbot added the platform: nRF Nordic nRFx label Dec 9, 2022
@nordicjm nordicjm changed the title It mcu mgmt: mcumgr: Add iterable section to register MCUmgr handlers Dec 9, 2022
@nordicjm nordicjm force-pushed the it_mcu branch 2 times, most recently from e57e111 to 8844099 Compare December 9, 2022 10:46
@zephyrbot zephyrbot added Release Notes To be mentioned in the release notes area: Documentation labels Dec 9, 2022
@nordicjm
Copy link
Collaborator Author

nordicjm commented Dec 9, 2022

Should probably make all the registration functions static too

@nordicjm nordicjm marked this pull request as draft December 9, 2022 15:13
@nordicjm nordicjm force-pushed the it_mcu branch 2 times, most recently from 49cf926 to 1c30a69 Compare December 12, 2022 15:47
@nordicjm nordicjm marked this pull request as ready for review December 12, 2022 15:47
@carlescufi
Copy link
Member

@tejlmand this one could do with your review, it touches the linker script.

This replaces the requirement for applications to manually
register MCUmgr handlers by having an iterable section which
then automatically registers the handlers at boot time.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Adds a note on MCUmgr handlers now being automatically called
without needing an application to manually register them.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Makes group registration functions for MCUmgr handlers static as
they are registered automatically at startup.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Copy link
Collaborator

@de-nordic de-nordic left a comment

Choose a reason for hiding this comment

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

Comment regarding Kconfig options naming, otherwise looks OK.

subsys/mgmt/mcumgr/transport/Kconfig.bluetooth Outdated Show resolved Hide resolved
This moves the UDP and Bluetooth initialisation for MCUmgr to be
performed automatically with the new hander registration feature.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Adds a note on MCUmgr Bluetooth and UDP transports now being
automatically registered without needing an application to
manually register them.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
This application does not actually seem to use MCUmgr
functionality, therefore remove it.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
@carlescufi carlescufi merged commit 17e7ca7 into zephyrproject-rtos:main Dec 22, 2022
mcumgr automation moved this from In progress to Done in release 3.3 Dec 22, 2022
@nordicjm nordicjm deleted the it_mcu branch January 6, 2023 10:38
@nordicjm nordicjm moved this from Done in release 3.3 to Done in mcumgr Feb 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging this pull request may close these issues.

None yet

4 participants