pvr_dev_quer...ncements_get(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… pvr_dev_quer...ncements_get(9) β€” from the Kernel API Manual, bestie ✨

okay so you're in the kernel API manual and you found pvr_dev_quer...ncements_get(9) β€” that's the page. welcome, pull up a chair πŸŽ€


🌸 NAME 🌸

pvr_dev_query_enhancements_get β€” it unpacks the array of enhancements at the address you gave it in a struct drm_pvr_dev_query_enhancements, or it just tells you how much space you need for that whole situation. two jobs, one function, main character energy πŸ‘‘


✨ SYNOPSIS ✨

int pvr_dev_query_enhancements_get (struct pvr_device *pvr_dev , struct
drm_pvr_ioctl_dev_query_args *args );

like, that's the whole vibe. two args, one int back 🫢


πŸ¦‹ ARGUMENTS πŸ¦‹

  • pvr_dev β€” the device pointer, your lil handle on the actual hardware situation πŸ’–
  • args β€” [IN] device query arguments, and inside them lives a pointer to a userspace struct drm_pvr_dev_query_enhancements. that pointer is the whole point of the operation, no cap

πŸ’œ DESCRIPTION πŸ’œ

so here's the tea 🍡 β€” read these branches carefully, they're doing a lot:

  • if the query object pointer is NULL, then the size field gets updated with the expected size of the query object. that's your "how big should this be" mode, iconic
  • if the userspace pointer in the query object is NULL, or the count is short β€” then no data is copied. literally none. don't come for the data, there is no data 😭
  • the count field will be updated to whichever count actually got copied β€” or, if either pointer is NULL, it gets updated to the count that would have been copied πŸ‘€
  • and the size field in the query object gets updated to the size copied

that's it, that's the whole dance. size in, size out, and the count reporting on what did or didn't happen πŸ’«


πŸ”₯ RETURN πŸ”₯

  • 0 on success β€” or also 0 if size/count is being requested with a NULL pointer, because that's a valid ask, bestie βœ”οΈ
  • -EINVAL if args contained non-zero reserved fields β€” like, those fields are reserved, respect them πŸ™ˆ
  • -E2BIG if the indicated length of the allocation is less than what's required to contain the copied data. your buffer is too small, that's the whole problem πŸ’€
  • -EFAULT if local memory could not be copied to userspace. the copy did not slay, it failed πŸ˜”

🌈 SEE ALSO 🌈

the whole friend group, in order, exactly as listed:

that's nineteen friends plus the driver file. go read them all, i'll wait 🧚


and that's the page!! source situation: ./drivers/gpu/drm/imagination, dated October 2026 β€” mwah, love that for us, bye bestie πŸ’…πŸ’–πŸŽ€

πŸ“¦ where this page comes from