mlx5dv_devx_subs...ibe_devx_event_fd(3)

πŸ’– NAME πŸ’–

okay bestie, welcome to the mlx5dv_devx_subs...ibe_devx_event_fd(3) manual page β€” yes, the name is long enough to need a snack break, but the tea is: these functions subscribe over an event channel for device events.

  • mlx5dv_devx_subscribe_devx_event β€” subscribe over an event channel for device events. slay.
  • mlx5dv_devx_subscribe_devx_event_fd β€” subscribe over an event channel for device events to signal eventfd. iconic.

✨ SYNOPSIS ✨

              #include <infiniband/mlx5dv.h>

              int mlx5dv_devx_subscribe_devx_event(struct mlx5dv_devx_event_channel *dv_event_channel,
                                   struct mlx5dv_devx_obj *obj,
                                   uint16_t events_sz,
                                   uint16_t events_num[],
                                   uint64_t cookie)

              int mlx5dv_devx_subscribe_devx_event_fd(struct mlx5dv_devx_event_channel *dv_event_channel,
                                  int fd,
                                  struct mlx5dv_devx_obj *obj,
                                  uint16_t event_num)

🌸 DESCRIPTION 🌸

okay so the whole plot is literally this: subscribe over a DEVX event channel for device events. that's the main character energy of this page. no cap.

πŸŽ€ ARGUMENTS πŸŽ€

  • dv_event_channel β€” event channel to subscribe over. that's the channel you're locking in with, bestie πŸ’…
  • fd β€” a file descriptor that previously was opened by the eventfd() system call. so yes, it has already been opened by eventfd() β€” noted.
  • obj β€” DEVX object that events_num relates to; can be NULL for unaffiliated events. yes, NULL is allowed here for unaffiliated events 🫢
  • events_sz β€” size of the events_num buffer that holds the events to subscribe for. it's giving "buffer size check" energy.
  • events_num β€” holds the required event numbers to subscribe for; numbers are according to the device specification. the device spec is the source of truth here, iykyk.
  • cookie β€” the value to be returned back when reading the event; can be used as an ID for application use. cute little app-side ID moment πŸ“

quick bestie note: event_num is chillin' in the mlx5dv_devx_subscribe_devx_event_fd signature up in SYNOPSIS, but the ARGUMENTS list here doesn't give it its own separate description. not me inventing lore πŸ’€

🧚 NOTES 🧚

when mlx5dv_devx_subscribe_devx_event_fd will be used, the fd will be signaled once an event has occurred. that's the whole note, bestie β€” short, sweet, and signaling. πŸ’–

πŸ¦‹ SEE ALSO πŸ¦‹

πŸ‘‘ AUTHOR πŸ‘‘

Yishai Hadas <yishaih@mellanox.com>


bestie sign-off πŸ’–: that's the mlx5dv_devx_subs...ibe_devx_event_fd(3) manual page, section 3. the footer doesn't give a separate source/version or date, it just repeats that page name, so consider this your cute little wave goodbye. stay subscribed βœ¨πŸ¦‹

πŸ“¦ where this page comes from