calculate_st...x_num_swaths(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… calculate_st...x_num_swaths(9) β€” Kernel API Manual πŸ’…

okay so bestie, welcome to the Kernel API Manual page for calculate_start_index_num_swaths. it’s giving helper-function main character energy, and we’re gonna read it together. 🫢✨

🌸 NAME 🌸

calculate_start_index_num_swaths β€” the helper function that calculates svp params for both vp0 and vp1. that’s the whole vibe, no cap. πŸ’–

πŸ¦‹ SYNOPSIS πŸ¦‹

void calculate_start_index_num_swaths (uint32_t svp0_start_swath_idx ,
uint32_t svp0_end_swath_idx , uint32_t svp1_start_swath_idx , uint32_t
svp1_end_swath_idx , uint16_t prefetch_swaths , uint16_t total_swaths ,
uint32_t *svp0_start_sw_idx_curr , uint32_t *svp0_num_swaths_curr ,
uint32_t *svp0_start_sw_idx_next , uint32_t *svp0_num_swaths_next ,
uint32_t *svp1_start_sw_idx_curr , uint32_t *svp1_num_swaths_curr ,
uint32_t *svp1_start_sw_idx_next , uint32_t *svp1_num_swaths_next );

πŸŽ€ ARGUMENTS πŸŽ€

okay so there are 14 arguments, and the source is out here giving us absolutely nothing but -- undescribed -- for every single one. not me reading the manual like πŸ‘οΈπŸ‘„πŸ‘οΈ. anyway, here they all are, exactly, with zero invented lore:

  • svp0_start_swath_idx β€” -- undescribed --
  • svp0_end_swath_idx β€” -- undescribed --
  • svp1_start_swath_idx β€” -- undescribed --
  • svp1_end_swath_idx β€” -- undescribed --
  • prefetch_swaths β€” -- undescribed --
  • total_swaths β€” -- undescribed --
  • svp0_start_sw_idx_curr β€” -- undescribed --
  • svp0_num_swaths_curr β€” -- undescribed --
  • svp0_start_sw_idx_next β€” -- undescribed --
  • svp0_num_swaths_next β€” -- undescribed --
  • svp1_start_sw_idx_curr β€” -- undescribed --
  • svp1_num_swaths_curr β€” -- undescribed --
  • svp1_start_sw_idx_next β€” -- undescribed --
  • svp1_num_swaths_next β€” -- undescribed --
bestie, the manual literally says -- undescribed -- for all of these, so I’m not gonna guess at behaviour. that would be fake lore and we don’t do that here. πŸ’…

πŸ”₯ DESCRIPTION πŸ”₯

okay so the actual description is short and sweet: it calculates svp parameters in terms of start swath idx and number of swaths for both vp0 and vp1. lowkey iconic that it does both vp0 and vp1. πŸ’œ

there’s also this exact asterisk wall in the page, so I’m preserving it because details matter:

***********************************************************************************************************

🌈 SEE ALSO 🌈

first up, Kernel file: ./drivers/gpu/drm/amd/display/dc/dml2_0/dml21/src/dml2_standalone_libraries/alternate_pstate_shared_lib.c

then the whole bestie squad of refs, all present and accounted for:


mwah πŸ’‹ this page is from ./drivers/gpu/drm/amd/display/... and it’s dated October 2026, bestie. go off and calculate those svp params. periodt. πŸŽ€βœ¨πŸ¦‹

πŸ“¦ where this page comes from