In latest kernel I use the following code to operate the inode of a symlink file:
file = filp_open(filename, O_PATH | O_NOFOLLOW, 0);
If I don't add O_PATH, filp_open would fail with -ELOOP
.
On Linux kernel 2.6.32, O_PATH is unavailable, what should I use instead?