Subject: Re: [bug#77153] [PATCH v2 0/3] doc: cookbook: Custom NAT-based libvirt networks.

From: Maxim Cournoyer <[email-masked]>
Date: Sun, 23 Mar 2025 00:50:17 +0900

Hi,

45mg <[email-masked]> writes:

> Changes from v1:
> 1/3:
> - Added copyright.
> - Modified commit message to include the discussed rationale for this change.
> 3/3: Addressed Maxim's review [1].
> Unaddressed, pending items [2]:
> - Link to libvirt networking handbook - keep, move, or ditch?

Not sure.  If we link to it, I'd do so from the first section covering
material sourced from it.

> - What does 'stp_state' param for a bridge actually do?

Apparently it means this, per man 8 bridge:

       state STP_STATE
              The spanning tree state, see the state option of bridge
              link set for supported states.

and from the same manual:

       state STP_STATE
              the operation state of the vlan. One may enter STP state
              name (case insensitive), or one of the numbers below.
              Negative inputs are ignored, and unrecognized names return
              an error. Note that the state is set only for the vlan of
              the specified device, e.g. if it is a bridge port then the
              state will be set only for the vlan of the port.

              0 - vlan is in STP DISABLED state. Make this vlan
              completely inactive for STP. This is also called BPDU
              filter and could be used to disable STP on an untrusted
              vlan.

              1 - vlan is in STP LISTENING state. Only valid if STP is
              enabled on the bridge. In this state the vlan listens for
              STP BPDUs and drops all other traffic frames.

              2 - vlan is in STP LEARNING state. Only valid if STP is
              enabled on the bridge. In this state the vlan will accept
              traffic only for the purpose of updating MAC address
              tables.

              3 - vlan is in STP FORWARDING state. This is the default
              vlan state.

              4 - vlan is in STP BLOCKING state. Only valid if STP is
              enabled on the bridge. This state is used during the STP
              election process. In this state, the vlan will only process
              STP BPDUs.

So you could add comment mentioning that this is to configure the bridge
in the listening @acronym{STP, Spanning Tree State} or similar, or
something nicer if you have a better understanding of why that is useful.

-- 
Thanks,
Maxim