HUGETLBFS_FIND_PATH(3)

πŸ’– HUGETLBFS_FIND_PATH πŸ’–

okay bestie, so this is a page from the Library Functions Manual, and it's about hugetlbfs_find_path and hugetlbfs_find_path_for_size β€” two little cuties whose whole job is to Locate an appropriate hugetlbfs mount point. no cap. 🫢


✨ NAME ✨

hugetlbfs_find_path, hugetlbfs_find_path_for_size β€” they locate an appropriate hugetlbfs mount point for you πŸ’…


🌸 SYNOPSIS 🌸

#include <hugetlbfs.h>

const char *hugetlbfs_find_path(void);
const char *hugetlbfs_find_path_for_size(long page_size);

πŸ¦‹ DESCRIPTION πŸ¦‹

so these functions literally hand you back a pathname for a mounted hugetlbfs filesystem, and they pick the one that matches the appropriate huge page size. it's giving ✨personalized service✨

  • hugetlbfs_find_path β€” uses the default huge page size. if you wanna know what that default actually is, go check gethugepagesize(3) bestie 😌
  • hugetlbfs_find_path_for_size β€” here you gotta pass in a valid huge page size yourself, no guessing allowed. see gethugepagesizes(3) for the list of what counts as valid πŸ‘‘
lowkey important: hugetlbfs_find_path_for_size needs a valid huge page size. don't just make one up, it will not slay.

⭐ RETURN VALUE ⭐

  • on success πŸ’– β€” you get back a non-NULL value. iconic.
  • on failure πŸ’€ β€” you get NULL. it's giving rejected.

🌈 SEE ALSO 🌈


πŸ‘‘ AUTHORS πŸ‘‘

libhugetlbfs was written by various people on the libhugetlbfs-devel mailing list. a whole group chat of legends fr fr 🫢


and that's the tea, bestie πŸ“ this page is dated March 7, 2012, and it comes to you from libhugetlbfs. go find your mount point and live your main character era πŸ’–βœ¨πŸŽ€