Skip to content

Bug: Xfw::config_ diverges from kernel state after partial subsystem failure #4

@consuelo2210

Description

@consuelo2210

Problem

set_config() applies updates per subsystem. Each subsystem may successfully commit changes to kernel BPF maps before a later subsystem fails. On failure, earlier subsystems remain applied in kernel state, but config_ is not updated.

This breaks consistency: kernel state != config_

When it happens

After partial failure during kernel apply stage, despite full pre-validation of the input configuration.

Typical failure points: ENOMEM in system, ENOSPC in maps.

These errors can occur after partial successful writes to kernel maps (map consistency is guaranteed through other mechanisms).

Current behavior

Some subsystems are committed to kernel state
Later subsystem fails
config_ remains unchanged (old version)

Expected behavior

After failure: config_ == last successfully committed kernel state

Impact

userspace state is stale
kernel state is partially updated but not reflected in config_
future diffs may be computed from outdated baseline

Fix

Incrementally update config_ after each successful subsystem commit to reflect actual kernel state.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions