ice_alloc_fd_res_cntr(9)
π ice_alloc_fd_res_cntr(9) β your girl's guide to grabbing a counter resource π
okay so bestie, welcome to the Kernel API Manual, section 9, and today's main character is ice_alloc_fd_res_cntr β the lil function that goes and obtains a counter resource for an FD type. that's literally the whole name, that's the whole vibe. π
β¨ NAME β¨
ice_alloc_fd_res_cntr β obtain counter resource for FD type π¦
like, you want a counter, but for an FD type specifically, and this is the function that gets you one. slay.
πΈ SYNOPSIS πΈ
int ice_alloc_fd_res_cntr (struct ice_hw *hw , u16 *cntr_id );
it returns an int (iykyk, that's your success/failure situation) and takes exactly two arguments. no cap. β¨
π ARGUMENTS π
hwβ pointer to the hardware structure π«Ά like yeah bestie, you gotta hand over the hardware struct, that's the whole context of where this counter is coming from.cntr_idβ returns counter index β this one's an output β you pass in theu16 *and it hands you back the counter index. not me passing a pointer to get a value back π iconic behavior honestly.
π₯ SEE ALSO π₯
first up, the kernel file location, in case you wanna go read the source like the little researcher you are:
./drivers/net/ethernet/intel/ice/ice_fdir.c
and then the whole friend group β these are the neighbors, the siblings, the ones you'll bump into:
ice_set_dflt_val_fd_desc(9)ice_set_fd_desc_val(9)ice_fdir_get_prgm_desc(9)ice_free_fd_res_cntr(9)ice_alloc_fd_guar_item(9)ice_alloc_fd_shrd_item(9)ice_get_fdir_cnt_all(9)ice_pkt_insert_ipv6_addr(9)ice_pkt_insert_u6_qfi(9)ice_pkt_insert_u8(9)ice_pkt_insert_u8_tc(9)ice_pkt_insert_u16(9)ice_pkt_insert_u32(9)ice_pkt_insert_mac_addr(9)ice_fdir_get_gen_prgm_pkt(9)ice_fdir_has_frag(9)ice_fdir_find_fltr_by_idx(9)ice_fdir_list_add_fltr(9)ice_fdir_update_cntrs(9)ice_cmp_ipv6_addr(9)ice_fdir_comp_rules(9)ice_fdir_is_dup_fltr(9)
okay that's the whole squad, go say hi ππ
and that's the page, bestie β no notes, periodt. this beauty lives down in ./drivers/net/ethernet/intel/ice and the October 2026 date is stamped on it like a little time capsule π°οΈβ¨ go forth and allocate those counters responsibly, mwah ππ
π¦ 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