Re: pathconf syscall for linux

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 09/21/2017 03:17 PM, Lukas Czerner wrote:

_PC_NAME_MAX		linux limits

Note that _PC_NAME_MAX is basically a lie. There are file systems which support longer names than 255 bytes. It's quite common for file systems which store names in UCS-2 or UTF-16 and have code point limit of 255, which translates to something larger after UTF-8 conversion in the kernel. This value is available today through statfs/f_namemax, but historically, the reported value was not correct.

But due to file bind mounts, any value the kernel can return is useless for application use anyway.

The only real user of this constant was readdir_r, and I've been trying to kill it (it's still in POSIX, but will be removed in a future edition).

_PC_REC_INCR_XFER_SIZE 	?
_PC_REC_MAX_XFER_SIZE	?
_PC_REC_MIN_XFER_SIZE	? block size ?
_PC_REC_XFER_ALIGN	per fs (block size)

NFS (and perhaps other network file systems) treats f_bsize to signal something similar. We had to remove f_bsize-based tuning from glibc as a result because the value is quite misleading for many workloads.

_PC_ALLOC_SIZE_MIN	per fs (block size)

Like the other size limits quoted above, the semantics are quite unclear. POSIX documents them mostly in the context of the RT extensions, so the acceptable values likely depend whether the application uses kernel-assisted aio, or aio based on userspace threads.

Thanks,
Florian
--
To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux