calculate_sw...deadline_dst(9)
π NAME
ok so bestie, this is calculate_swath_deadline_dst β it's the little helper function that does the math for you and spits out the hdl dst position when you hand it a swath index β¨ (yes, that's literally the whole job, and it ate)
This page lives in section 9 of the Kernel API Manual, and yeah the title is a whole mouthful: calculate_sw...deadline_dst(9) π
πΈ SYNOPSIS
no cap, here's the exact signature, copy it character for character or it won't vibe:
uint32_t calculate_swath_deadline_dst (uint32_t swath_index , uint32_t
prefetch_swaths , uint32_t pre_first_hdl_x1000 , uint32_t
rec_first_hdl_x1000 , uint32_t pre_hdl_delta_x1000 , uint32_t
rec_hdl_delta_x1000 );
like, it returns a uint32_t and takes six uint32_ts. six. iconic of it honestly π
π¦ ARGUMENTS
ok so this is the part where the docs simply did not show up π every single one of these is marked -- undescribed -- in the original. i'm not gonna invent lore, that would be lying to you and we don't do that here π so here's the full roster, exactly as mysterious as the source left it:
swath_indexβ-- undescribed --(mystery girl. unknown. we simply don't know.)prefetch_swathsβ-- undescribed --(also undescribed, the silence is loud)pre_first_hdl_x1000β-- undescribed --(undescribed, but the name has_x1000in it which is giving fixed-point energy, iykyk)rec_first_hdl_x1000β-- undescribed --(same situation, still undescribed)rec_first_hdl_delta_x1000β-- undescribed --(undescribed, delta flavored)rec_hdl_delta_x1000β-- undescribed --(last one, also undescribed, we stan a consistent absence π)
fr fr: don't guess at these semantics. the manpage literally left them blank. if you need to know, go read the source, bestie π«Ά
β¨ RETURN
it hands you back the dst line associated with the swath deadline β that's the value, that's the whole return, go off king π
aaand then the original just drops this absolute unit of a separator line at the end of the RETURN section, so here it is in all its glory, verbatim, we do not gatekeep:
***********************************************************************************************************
likeβ¦ 107 asterisks of pure main character energy. obsessed. π₯
π SEE ALSO
ok the cross-reference situation is stacked, bestie. first, the kernel file this thing lives in β full path, no cuts:
./drivers/gpu/drm/amd/display/dc/dml2_0/dml21/src/dml2_standalone_libraries/alternate_pstate_shared_lib.c
and then the whole friend group, all in section 9, in this exact order:
in_circular_range(9)apply_svp1_workaround(9)calculate_start_line_and_height_from_swath(9)get_swath_deadlines(9)is_dst_in_next_frame(9)is_end_swath_in_next_frame(9)is_svp_dst_in_next_frame(9)calculate_swath_idx_from_dst(9)populate_svp_params(9)populate_start_index_num_swaths_helper(9)calculate_start_index_num_swaths(9)calculate_hubp_start_end_lines(9)get_prefetch_end_line(9)get_effective_vblank_start(9)
that's fourteen besties plus the file. a whole group chat π§
π sign-off
this page came from the source path ./drivers/gpu/drm/amd/display/... and the version/date stamp on it is October 2026, stamped with the title calculate_sw...deadline_dst(9) at the bottom like a little signature. slay, bye, go read the source ππΈπ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms