ice_pkg_enum_section(9)
π ice_pkg_enum_section(9) β the kernel API manual, but make it group chat
okay so this is ice_pkg_enum_section(9) from the Kernel API Manual, and it's genuinely one of the more chill ones β think of it as the little iterator bestie who walks the ice segment and hands you every section of a type you asked for, one at a time. No cap, that's the whole vibe.
β¨ NAME β¨
ice_pkg_enum_section β and yes, the description line in the original is literally empty. A mysterious queen with nothing to say. We respect it. π
πΈ SYNOPSIS πΈ
void * ice_pkg_enum_section (struct ice_seg *ice_seg , struct
ice_pkg_enum *state , u32 sect_type );
Returns void *, takes a segment, a state blob, and a section type. That's the whole signature, copied exactly, don't come for me. π«Ά
π¦ ARGUMENTS π¦
ice_segβ pointer to the ice segment (orNULLon subsequent calls). First call: you give it the actual segment. After that:NULL, because we're continuing, not restarting.stateβ pointer to the enum state. This little guy is what remembers where you are in the walk. Keep it alive between calls, bestie, it's carrying the whole operation.sect_typeβ section type to enumerate. This is you telling it which kind of section you're hunting for. π―
π DESCRIPTION π
This function will enumerate all the sections of a particular type in the ice segment. Like, all of them, one per call, no skipping. π
The first call is made with the ice_seg parameter non-NULL β that's how the enumerator knows "okay, we're starting fresh." On subsequent calls, ice_seg is set to NULL, which continues the enumeration. Yes, this is the classic "you've got to be in it to win it, but then you have to leave" pattern. The state parameter is holding the receipts the whole time. π
When the function returns a NULL pointer, then the end of the matching sections has been reached. So NULL isn't an error, it's the finish line. π Iconic behaviour, honestly.
lowkey the most important thing: first call = real segment pointer, every call after =NULLforice_seg. Get that backwards and you're starting the walk over and over like a main character with no plot. π
π SEE ALSO π
Kernel file ./drivers/net/ethernet/intel/ice/ice_ddp.c β that's where the actual source lives, go read it, it's giving lore.
And now the full see-also family, in the exact order they were handed to me, because we don't drop members of the squad:
ice_verify_pkg(9)ice_free_seg(9)ice_chk_pkg_version(9)ice_pkg_val_buf(9)ice_find_buf_table(9)ice_pkg_enum_buf(9)ice_pkg_advance_sect(9)ice_pkg_enum_entry(9)ice_sw_fv_handler(9)ice_get_prof_index_max(9)ice_get_ddp_pkg_state(9)ice_init_pkg_regs(9)ice_marker_ptype_tcam_handler(9)ice_add_dvm_hint(9)ice_add_tunnel_hint(9)ice_label_enum_handler(9)ice_enum_labels(9)ice_boost_tcam_handler(9)ice_find_boost_entry(9)ice_is_init_pkg_successful(9)ice_pkg_buf_alloc(9)ice_get_sw_prof_type(9)ice_get_sw_fv_bitmap(9)ice_get_sw_fv_list(9)ice_init_prof_result_bm(9)ice_pkg_buf_free(9)ice_pkg_buf_reserve_section(9)ice_pkg_buf_alloc_section(9)ice_pkg_buf_alloc_single_section(9)ice_pkg_buf_get_active_sections(9)ice_pkg_buf(9)ice_acquire_global_cfg_lock(9)ice_release_global_cfg_lock(9)ice_aq_download_pkg(9)ice_is_buffer_metadata(9)struct ice_ddp_send_ctx(9)ice_ddp_send_hunk(9)ice_dwnld_cfg_bufs_no_lock(9)ice_get_pkg_seg_by_idx(9)ice_is_signing_seg_at_idx(9)ice_is_signing_seg_type_at_idx(9)ice_download_pkg_sig_seg(9)ice_download_pkg_config_seg(9)ice_dwnld_sign_and_cfg_segs(9)ice_match_signing_seg(9)ice_post_dwnld_pkg_actions(9)ice_download_pkg_with_sig_seg(9)ice_dwnld_cfg_bufs(9)ice_download_pkg_without_sig_seg(9)ice_download_pkg(9)ice_aq_get_pkg_info_list(9)ice_aq_update_pkg(9)ice_aq_upload_section(9)ice_update_pkg_no_lock(9)ice_update_pkg(9)ice_find_seg_in_pkg(9)ice_has_signing_seg(9)ice_get_pkg_segment_id(9)ice_get_pkg_sign_type(9)ice_get_signing_req(9)ice_init_pkg_info(9)ice_get_pkg_info(9)ice_chk_pkg_compat(9)ice_init_pkg_hints(9)ice_fill_hw_ptype(9)ice_init_pkg(9)ice_copy_and_init_pkg(9)ice_get_set_tx_topo(9)ice_cfg_tx_topo(9)
That's the whole friend group. Seventy-ish manpages. Slept on exactly none of them. π₯
so yeah β first call with the segment, NULL after, and NULL returned means you're done. gg, go enumerate something. π¦
sign-off time π: this page comes from the source path ./drivers/net/ethernet/intel/ice and it's dated October 2026. cute little timestamp, we love a documented moment. π
π¦ 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