ice_find_free_recp_res_idx(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ‘‘ ice_find_free_recp_res_idx(9) πŸ’…

okay bestie, welcome to the Kernel API Manual entry for ice_find_free_recp_res_idx(9) β€” we're finding free result indexes for a recipe, and yes, it's exactly as niche and iconic as it sounds. ✨


✨ NAME ✨

  • ice_find_free_recp_res_idx β€” find free result indexes for recipe. that's the whole name vibe, no cap. πŸ’–

πŸ¦‹ SYNOPSIS πŸ¦‹

u16 ice_find_free_recp_res_idx (struct ice_hw *hw , const unsigned long
       *profiles , unsigned long *free_idx );

πŸ’… ARGUMENTS πŸ’…

  • hw β€” pointer to hardware structure. the hardware's main character moment. πŸ’…
  • profiles β€” bitmap of profiles that will be associated with the new recipe. think guest list, but for profiles. πŸŽ€
  • free_idx β€” pointer to variable to receive the free index bitmap. it's literally catching the free-index tea. πŸ“

🌸 DESCRIPTION 🌸

The algorithm used here is giving very much "figure out which result indexes are free before we commit," and it goes like this:

  1. When creating a new recipe, create a set P which contains all Profiles that will be associated with our new recipe. πŸ’–
  2. For each Profile p in set P:
    • a. Add all recipes associated with Profile p into set R.
    • b. Optional: PossibleIndexes &= profile[p].possibleIndexes β€” initially PossibleIndexes should be 0xFFFFFFFFFFFFFFFF.
      • i. Or just assume they all have the same possible indexes: 44, 45, 46, 47, i.e., PossibleIndexes = 0x0000F00000000000.
  3. For each Recipe r in set R:
    • a. UsedIndexes |= (bitwise or) recipe[r].res_indexes.
    • b. FreeIndexes = UsedIndexes ^ PossibleIndexes.

FreeIndexes will contain the bits indicating the indexes free for use, then the code needs to update recipe[r].used_result_idx_bits to indicate which indexes were selected for use by this recipe. slay. πŸ”₯


πŸŽ€ SEE ALSO πŸŽ€

Kernel file: ./drivers/net/ethernet/intel/ice/ice_switch.c β€” yes, that exact path, bestie. 🫢

Then all the linked manual pages, in their full glory:

πŸ’– that's the whole glow-up, bestie β€” this Kernel API Manual entry for ice_find_free_recp_res_idx(9) comes from ./drivers/net/ethernet/intel/ice and is dated October 2026. periodt. πŸŽ€βœ¨

πŸ“¦ where this page comes from