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

Pavel Emelyanov xemul at parallels.com
Tue Feb 25 11:03:36 PST 2014


On 02/25/2014 11:01 PM, Cyrill Gorcunov wrote:
> 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.
> .
> 


OK, fair enough. Is O_PATH present on all distros we compile CRIU?


More information about the CRIU mailing list