gfs2_llseek(9)
π gfs2_llseek(9) β seek to a location in a file π
okay bestie, welcome to the Kernel API Manual entry for gfs2_llseek(9). This is the little function that handles seeking to a location in a file, and we're gonna get into every detail together. π«Ά
π NAME π
gfs2_llseek β seek to a location in a file
β¨ SYNOPSIS β¨
loff_t gfs2_llseek (struct file *file , loff_t offset , int whence );
π¦ ARGUMENTS π¦
fileβ the file, literally the file we're working with.offsetβ the offset, periodt.whenceβ where to seek from:SEEK_SET,SEEK_CUR, orSEEK_END. π
πΈ DESCRIPTION πΈ
When whence is SEEK_END, this requires the glock for the file, because it references the file's size. No cap, that's the whole description vibe. π
β RETURN β
The new offset, or errno. That's it, bestie β the new offset or errno. π«Ά
π SEE ALSO π
- Kernel file
./fs/gfs2/file.c gfs2_readdir(9)do_gfs2_set_flags(9)gfs2_size_hint(9)gfs2_allocate_folio_backing(9)gfs2_page_mkwrite(9)gfs2_mmap(9)gfs2_open_common(9)gfs2_open(9)gfs2_release(9)gfs2_fsync(9)gfs2_file_write_iter(9)calc_max_reserv(9)gfs2_lock(9)gfs2_flock(9)
signing off from ./fs/gfs2, stamped October 2026 β 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