Skip to content

engine/rcf: allow reboot of dynamically added agents#10

Open
okt-konst wants to merge 1 commit into
ts-factory:mainfrom
okt-konst:up/rcf-agent-reboot
Open

engine/rcf: allow reboot of dynamically added agents#10
okt-konst wants to merge 1 commit into
ts-factory:mainfrom
okt-konst:up/rcf-agent-reboot

Conversation

@okt-konst

Copy link
Copy Markdown
Collaborator

A TA added at runtime via rcf_add_ta_unix() with RCF_TA_REBOOTABLE could
never be rebooted: rcf_ta_reboot() always failed with RCF-EOPNOTSUPP
("None of the requested reboot types are allowed") because the RCFOP_ADD_TA
path never initializes reboot_ctx.allowed_types (the agent struct is
zero-allocated), while the rcf.conf parse path defaults it to all reboot
types when the reboot_types attribute is absent.

Apply the same all-types default to dynamic TAs; rebootability is still
guarded by the RCF_TA_REBOOTABLE flag (TE_EPERM otherwise).

A TA added at runtime via rcf_add_ta_unix() with RCF_TA_REBOOTABLE
could never be rebooted: rcf_ta_reboot() always failed with
RCF-EOPNOTSUPP ("None of the requested reboot types are allowed")
because the RCFOP_ADD_TA path never initializes
reboot_ctx.allowed_types (the agent struct is zero-allocated),
while the rcf.conf parse path defaults it to all reboot types when
the reboot_types attribute is absent.

Apply the same all-types default to dynamic TAs; rebootability is
still guarded by the RCF_TA_REBOOTABLE flag (TE_EPERM otherwise).

Signed-off-by: Konstantin Ushakov <kushakov@oktet.co.il>
@okt-konst okt-konst marked this pull request as ready for review July 6, 2026 22:53
@okt-konst

Copy link
Copy Markdown
Collaborator Author

@ol-arteman @arybchik could you please review?

@okt-konst okt-konst requested review from arybchik and ol-arteman July 6, 2026 23:18
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