Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1585545

[RFC 0/3] fs,epoll: Add ability to call kcmp to find target files

From Cyrill Gorcunov <gorcunov@openvz.org>
Newsgroups linux.kernel
Subject [RFC 0/3] fs,epoll: Add ability to call kcmp to find target files
Date 2017-02-21 18:20 +0100
Message-ID <tdmgy-5z4-25@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


Hi! In previous series EPOLL_CTL_DUP operation has been discussed
but considered as potentially scary. So here is an another approach:

 - extend fdinfo of epoll files with inode, device and file position
   for every target, which allow the reader to gather targets with
   this bundle as a key for primary sorting

 - extent kcmp to check if some particular file is matching one
   sitting inside epoll queue (duplicate numbers are resolved with
   offset parameter)

Please take a look once time permit. Note that I did only basic
testing (without CRIU) but it should fit our needs because we
sort and lookup regualr files by same scheme. So I'm about to
implemet full criu support for this new kernel features in
a couple of days thus any comments are *higly* appreciated.

NB: Initially I added

	if (file_ns_capable(epi->ffd.file, ns, CAP_SYS_ADMIN))

into fdinfo output to check if caller is allowed to see
target ino/dev/pos but dropped it later because if process
is added file descriptor into epoll queue it mean fdstat
and such already can be called and this information is
already obtained, so I don't this it's information
disclosure.

	Cyrill

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[RFC 0/3] fs,epoll: Add ability to call kcmp to find target files Cyrill Gorcunov <gorcunov@openvz.org> - 2017-02-21 18:20 +0100
  Re: [RFC 0/3] fs,epoll: Add ability to call kcmp to find target files Jason Baron <jbaron@akamai.com> - 2017-02-21 21:40 +0100
    Re: [RFC 0/3] fs,epoll: Add ability to call kcmp to find target files Cyrill Gorcunov <gorcunov@gmail.com> - 2017-02-21 22:00 +0100
      Re: [RFC 0/3] fs,epoll: Add ability to call kcmp to find target files Cyrill Gorcunov <gorcunov@gmail.com> - 2017-02-28 18:20 +0100

csiph-web