Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-23 Thread Miklos Szeredi
> Pavel Machek wrote: > > On Sun 2008-01-20 09:23:00, Miklos Szeredi wrote: > >>> Miklos Szeredi wrote: > - for mount ID's use IDA (from the IDR library) instead of a 32bit > counter, which could overflow > >>> IDAs tend to get reused quickly, which can cause race conditions. Any > >>

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-23 Thread H. Peter Anvin
Pavel Machek wrote: On Sun 2008-01-20 09:23:00, Miklos Szeredi wrote: Miklos Szeredi wrote: - for mount ID's use IDA (from the IDR library) instead of a 32bit counter, which could overflow IDAs tend to get reused quickly, which can cause race conditions. Any reason not to just use a 64-bit

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-23 Thread Pavel Machek
On Sun 2008-01-20 09:23:00, Miklos Szeredi wrote: > > Miklos Szeredi wrote: > > > - for mount ID's use IDA (from the IDR library) instead of a 32bit > > > counter, which could overflow > > > > IDAs tend to get reused quickly, which can cause race conditions. Any > > reason not to just use a 64

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-22 Thread Serge E. Hallyn
Quoting Miklos Szeredi ([EMAIL PROTECTED]): > > On Mon, 2008-01-21 at 22:25 +0100, Miklos Szeredi wrote: > > > > You have removed the code that checked if the peer or > > > > master mount was in the same namespace before reporting their > > > > corresponding mount-ids. One d

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-21 Thread Miklos Szeredi
> On Mon, 2008-01-21 at 22:25 +0100, Miklos Szeredi wrote: > > > You have removed the code that checked if the peer or > > > master mount was in the same namespace before reporting their > > > corresponding mount-ids. One downside of that approach is the > > > user will see an mount_id in t

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-21 Thread Ram Pai
On Mon, 2008-01-21 at 22:25 +0100, Miklos Szeredi wrote: > > You have removed the code that checked if the peer or > > master mount was in the same namespace before reporting their > > corresponding mount-ids. One downside of that approach is the > > user will see an mount_id in the

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-21 Thread Miklos Szeredi
> You have removed the code that checked if the peer or > master mount was in the same namespace before reporting their > corresponding mount-ids. One downside of that approach is the > user will see an mount_id in the output with no corresponding > line to explain the

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-21 Thread Ram Pai
Miklos, You have removed the code that checked if the peer or master mount was in the same namespace before reporting their corresponding mount-ids. One downside of that approach is the user will see an mount_id in the output with no corresponding line to e

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-20 Thread Miklos Szeredi
> On Jan 19 2008 12:05, Miklos Szeredi wrote: > >+ > >+/* > >+ * Write full pathname from the root of the filesystem into the buffer. > >+ */ > >+char *dentry_path(struct dentry *dentry, char *buf, int buflen) > > Hm, this functions looks very much like __d_path(). Is it > an unintentional copy?

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-20 Thread Jan Engelhardt
On Jan 19 2008 12:05, Miklos Szeredi wrote: >+ >+/* >+ * Write full pathname from the root of the filesystem into the buffer. >+ */ >+char *dentry_path(struct dentry *dentry, char *buf, int buflen) Hm, this functions looks very much like __d_path(). Is it an unintentional copy? >+{ >+ char

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-20 Thread Miklos Szeredi
> Miklos Szeredi wrote: > > - for mount ID's use IDA (from the IDR library) instead of a 32bit > > counter, which could overflow > > IDAs tend to get reused quickly, which can cause race conditions. Any > reason not to just use a 64-bit counter? They tend to become hard to parse/compare for h

Re: [RFC][PATCH] VFS: create /proc//mountinfo

2008-01-19 Thread H. Peter Anvin
Miklos Szeredi wrote: - for mount ID's use IDA (from the IDR library) instead of a 32bit counter, which could overflow IDAs tend to get reused quickly, which can cause race conditions. Any reason not to just use a 64-bit counter? -hpa -- To unsubscribe from this list: send the lin

[RFC][PATCH] VFS: create /proc//mountinfo

2008-01-19 Thread Miklos Szeredi
Seems, most people would be happier with a new file, instead of extending /proc/mounts. This patch is the first attempt at doing that, as well as fixing the issues found in the previous submission. Thanks, Miklos --- From: Ram Pai <[EMAIL PROTECTED]> /proc/mounts in its current state fail to di