ENUM DPSW_LEARNING_MODE(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ¦‹ enum dpsw_learning_mode(9) β€” the Kernel API Manual page your bestie needs

okay so this is a page straight out of the Kernel API Manual and it's literally all about auto-learning modes, which honestly sounds boring until you realize it's about how a switch decides who gets to learn MAC addresses and how. slay. let's get into it πŸ’…


✨ NAME ✨

enum dpsw_learning_mode β€” Auto-learning modes. that's it, that's the whole vibe. it's the enum that tells you how learning happens on a DPAA2 switch interface πŸŽ€


🌸 SYNOPSIS 🌸

enum dpsw_learning_mode {
    DPSW_LEARNING_MODE_DIS ,
    DPSW_LEARNING_MODE_HW ,
    DPSW_LEARNING_MODE_NON_SECURE ,
    DPSW_LEARNING_MODE_SECURE

};

four members, no cap. that's the whole enum, icon behavior ✨


πŸ’– Constants πŸ’–

these are the four moods this enum can be in, bestie:

  • DPSW_LEARNING_MODE_DIS β€” Disable Auto-learning. nope, not today, no learning happening here πŸ™ˆ
  • DPSW_LEARNING_MODE_HW β€” Enable HW auto-Learning. let the hardware do the learning, it's giving main character energy πŸ”₯
  • DPSW_LEARNING_MODE_NON_SECURE β€” Enable None secure learning by CPU. the CPU learns, but like... not securely. (yes, "None secure" is exactly how the source spells it, i'm not fixing it, i don't do that 🫢)
  • DPSW_LEARNING_MODE_SECURE β€” Enable secure learning by CPU. now the CPU learns and it's secure. the upgrade we deserve πŸ‘‘

🧚 Description 🧚

okay bestie, this part is a table and the doc generator absolutely butchered it β€” the columns got all tangled and honestly it's giving "my group chat after 3am" πŸ’€ but the rule is: keep every detail, so here it is, verbatim, exactly as the page has it. don't come for me, i didn't write it:

NONE - SECURE LEARNING SMAC found      DMAC found      CTLU Action v
v       Forward frame to

1      DMAC destination

β€’      v       Forward frame to

1      DMAC destination

2      Control interface v               -       Forward frame to

1      Flooding list of interfaces

β€’      -       Forward frame to

1      Flooding list of interfaces

2      Control interface SECURE LEARING SMAC found      DMAC found
       CTLU Action v               v               Forward frame to

1      DMAC destination

β€’      v               Forward frame to

1      Control interface v               -               Forward frame
       to

1      Flooding list of interfaces

β€’      -               Forward frame to

1      Control interface

so yeah. it's about SMAC found, DMAC found, and what the CTLU Action ends up being β€” forward to DMAC destination, forward to the flooding list of interfaces, or forward to the control interface. in the non-secure case and the secure case. that's the whole tea β˜• (and yes, SECURE LEARING is missing an N in the source β€” we love a typo'd icon πŸŽ€)


🌈 SEE ALSO 🌈

the kernel file lives at ./drivers/net/ethernet/freescale/dpaa2/dpsw.h β€” go read it, it's the whole family tree πŸ¦‹

and then the extended fam, in order, all of them, no skipping (i promised):

DPSW_OPT_FLOODING_DIS(9), DPSW_OPT_MULTICAST_DIS(9), DPSW_OPT_CTRL_IF_DIS(9), enum dpsw_component_type(9), enum dpsw_flooding_cfg(9), enum dpsw_broadcast_cfg(9), DPSW_IRQ_EVENT_LINK_CHANGED(9), DPSW_IRQ_EVENT_ENDPOINT_CHANGED(9), struct dpsw_irq_cfg(9), struct dpsw_attr(9), struct dpsw_ctrl_if_attr(9), struct dpsw_ctrl_if_pools_cfg(9), enum dpsw_action(9), struct dpsw_link_cfg(9), struct dpsw_link_state(9), struct dpsw_tci_cfg(9), enum dpsw_stp_state(9), struct dpsw_stp_cfg(9), enum dpsw_accepted_frames(9), enum dpsw_counter(9), struct dpsw_if_attr(9), struct dpsw_vlan_cfg(9), struct dpsw_vlan_if_cfg(9), enum dpsw_fdb_entry_type(9), struct dpsw_fdb_unicast_cfg(9), struct fdb_dump_entry(9), struct dpsw_fdb_multicast_cfg(9), struct dpsw_fdb_attr(9), struct dpsw_fdb_cfg(9), enum dpsw_flood_type(9), struct dpsw_acl_cfg(9), struct dpsw_acl_if_cfg(9), struct dpsw_acl_fields(9), struct dpsw_acl_key(9), enum dpsw_acl_action(9), struct dpsw_acl_result(9), struct dpsw_acl_entry_cfg(9), enum dpsw_reflection_filter(9), struct dpsw_reflection_cfg(9), struct dpsw_lag_cfg(9)


and that's the page!! πŸ’œ this lil legend comes from ./drivers/net/ethernet/freesca... (the path got cut off in the footer, tragic, i know 😭) and it's dated October 2026, filed under enum dpsw_learning_mode(9). mwah, go read the header file bestie πŸ’‹βœ¨

πŸ“¦ where this page comes from