KNET_LINK..._PRIORITY(3)

πŸ’– NAME πŸ’–

knet_link_get_priority β€” bestie, this one gets the priority for a link. that's it. that's the whole job. πŸŽ€


✨ SYNOPSIS ✨

#include <libknet.h>

int knet_link_get_priority(
    knet_handle_t   knet_h,
    knet_node_id_t  host_id,
    uint8_t         link_id,
    uint8_t        *priority
);

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so like, knet_link_get_priority is the lil function that goes and fetches the switching priority of a link for you. no drama, no cap.

here's the tea on the arguments:

  • knet_h β€” pointer to knet_handle_t. the main character handle, obviously. πŸ‘‘
  • host_id β€” ngl you gotta look at knet_host_add(3) for this one, it's giving "see also" energy.
  • link_id β€” and for this one, go read knet_link_set_config(3). iykyk. πŸ’…
  • priority β€” this is where you gather up the switching priority for this link. and bestie, also peep knet_host_set_policy while you're at it. 🌸

🌈 RETURN VALUE 🌈

knet_link_get_priority returns 0 on success. and on error? it returns -1 and sets errno. so like, check your errno, bestie, it's literally telling you what went wrong. 😭


πŸ’œ SEE ALSO πŸ’œ

okay this list is LONG, buckle up, we're going on a little journey, mwah 🫢


Copyright (C) 2010-2026 Red Hat, Inc. All rights reserved.


and that's the whole page, bestie!! πŸ’– this was kronosnet manual, dated 2026-07-20, filed under KNET_LINK..._PRIORITY(3). go forth and get those priorities, you absolute icon. slay. βœ¨πŸŽ€πŸ¦‹
πŸ“¦ where this page comes from