Re: [patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-26 Thread Cyrill Gorcunov
On Sun, Aug 26, 2012 at 04:05:20PM +0100, Al Viro wrote: > > Applied, with a couple of changes: > * there's no need for those games with ihold/iput - opened file pins >its inode down just fine, TYVM. Ah, yeah, thanks! > * struct fd_info is pointless in that form - the last argument >

Re: [patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-26 Thread Al Viro
On Sun, Aug 26, 2012 at 06:28:20PM +0400, Cyrill Gorcunov wrote: > On Sun, Aug 26, 2012 at 03:46:53AM +0100, Al Viro wrote: > > > > IMO doing that at open() time is just a headache for no good reason - > > resolving descriptor to struct file * at read() time as we do now > > is much saner.

Re: [patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-26 Thread Cyrill Gorcunov
On Sun, Aug 26, 2012 at 03:46:53AM +0100, Al Viro wrote: > > IMO doing that at open() time is just a headache for no good reason - > resolving descriptor to struct file * at read() time as we do now > is much saner. Better do that in your ->show(), since you are using > a single-shot iterator

Re: [patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-26 Thread Cyrill Gorcunov
On Sun, Aug 26, 2012 at 03:46:53AM +0100, Al Viro wrote: > On Thu, Aug 23, 2012 at 02:43:25PM +0400, Cyrill Gorcunov wrote: > > This patch converts /proc/pid/fdinfo/ handling routines to seq-file which > > is needed to extend seq operations and plug in auxiliary fdinfo provides > > from subsystems

Re: [patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-26 Thread Cyrill Gorcunov
On Sun, Aug 26, 2012 at 03:46:53AM +0100, Al Viro wrote: On Thu, Aug 23, 2012 at 02:43:25PM +0400, Cyrill Gorcunov wrote: This patch converts /proc/pid/fdinfo/ handling routines to seq-file which is needed to extend seq operations and plug in auxiliary fdinfo provides from subsystems like

Re: [patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-26 Thread Cyrill Gorcunov
On Sun, Aug 26, 2012 at 03:46:53AM +0100, Al Viro wrote: IMO doing that at open() time is just a headache for no good reason - resolving descriptor to struct file * at read() time as we do now is much saner. Better do that in your -show(), since you are using a single-shot iterator

Re: [patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-26 Thread Al Viro
On Sun, Aug 26, 2012 at 06:28:20PM +0400, Cyrill Gorcunov wrote: On Sun, Aug 26, 2012 at 03:46:53AM +0100, Al Viro wrote: IMO doing that at open() time is just a headache for no good reason - resolving descriptor to struct file * at read() time as we do now is much saner. Better do that

Re: [patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-26 Thread Cyrill Gorcunov
On Sun, Aug 26, 2012 at 04:05:20PM +0100, Al Viro wrote: Applied, with a couple of changes: * there's no need for those games with ihold/iput - opened file pins its inode down just fine, TYVM. Ah, yeah, thanks! * struct fd_info is pointless in that form - the last argument of

Re: [patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-25 Thread Al Viro
On Thu, Aug 23, 2012 at 02:43:25PM +0400, Cyrill Gorcunov wrote: > This patch converts /proc/pid/fdinfo/ handling routines to seq-file which > is needed to extend seq operations and plug in auxiliary fdinfo provides > from subsystems like eventfd/eventpoll/fsnotify. > > Note the proc_fd_link no

Re: [patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-25 Thread Al Viro
On Thu, Aug 23, 2012 at 02:43:25PM +0400, Cyrill Gorcunov wrote: This patch converts /proc/pid/fdinfo/ handling routines to seq-file which is needed to extend seq operations and plug in auxiliary fdinfo provides from subsystems like eventfd/eventpoll/fsnotify. Note the proc_fd_link no longer

[patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-23 Thread Cyrill Gorcunov
This patch converts /proc/pid/fdinfo/ handling routines to seq-file which is needed to extend seq operations and plug in auxiliary fdinfo provides from subsystems like eventfd/eventpoll/fsnotify. Note the proc_fd_link no longer call for proc_fd_info, simply because proc_fd_info is converted to

[patch 2/9] procfs: Convert /proc/pid/fdinfo/ handling routines to seq-file v2

2012-08-23 Thread Cyrill Gorcunov
This patch converts /proc/pid/fdinfo/ handling routines to seq-file which is needed to extend seq operations and plug in auxiliary fdinfo provides from subsystems like eventfd/eventpoll/fsnotify. Note the proc_fd_link no longer call for proc_fd_info, simply because proc_fd_info is converted to