[CRIU] [PATCH 1/2] fsnotify: Open handle with O_PATH

Cyrill Gorcunov gorcunov at gmail.com
Tue Feb 25 11:01:12 PST 2014


On Tue, Feb 25, 2014 at 10:55:02PM +0400, Pavel Emelyanov wrote:
> On 02/25/2014 12:21 PM, Cyrill Gorcunov wrote:
> > 
> > Otherwise if the mark is set up on link we end
> > with -ELOOP error trying to open it. 
> 
> I don't understand this explanation. Please, elaborate.

Kernel's namei.c

may_open
	...
	/* O_PATH? */
	if (!acc_mode)
		return 0;
	switch (inode->i_mode & S_IFMT) {
	case S_IFLNK:
		return -ELOOP;

In the test case Andrew showed me we set a notification
mark on symbolic link, and when we're tryin to open it
by fhandle we hit this -ELOOP problem.


More information about the CRIU mailing list