Re: [PATCH 5/6] ubifs: Implement export_operations

2017-05-23 Thread Richard Weinberger
Christoph, Am 23.05.2017 um 10:48 schrieb Christoph Hellwig: > On Tue, May 23, 2017 at 10:41:16AM +0200, Richard Weinberger wrote: >> UBIFS has no inode generations, inodes simply can't wrap around. >> We "handle" it like JFF2 does, we assumes that the NAND is long dead >> before we reach the maxi

Re: [PATCH 5/6] ubifs: Implement export_operations

2017-05-23 Thread Christoph Hellwig
On Tue, May 23, 2017 at 10:41:16AM +0200, Richard Weinberger wrote: > UBIFS has no inode generations, inodes simply can't wrap around. > We "handle" it like JFF2 does, we assumes that the NAND is long dead > before we reach the maximum inode number. So you never ever reuse an inode number once it'

Re: [PATCH 5/6] ubifs: Implement export_operations

2017-05-23 Thread Richard Weinberger
Christoph, Am 23.05.2017 um 10:39 schrieb Christoph Hellwig: >> +static struct inode *ubifs_nfs_get_inode(struct super_block *sb, uint64_t >> ino, >> + uint32_t generation) >> +{ >> +return ubifs_iget(sb, ino); >> +} > > You need to maintain and check an i

Re: [PATCH 5/6] ubifs: Implement export_operations

2017-05-23 Thread Christoph Hellwig
> +static struct inode *ubifs_nfs_get_inode(struct super_block *sb, uint64_t > ino, > + uint32_t generation) > +{ > + return ubifs_iget(sb, ino); > +} You need to maintain and check an inode generation counter for this to be safe.

[PATCH 5/6] ubifs: Implement export_operations

2017-05-21 Thread Richard Weinberger
Signed-off-by: Richard Weinberger --- fs/ubifs/super.c | 35 +++ fs/ubifs/ubifs.h | 1 + 2 files changed, 36 insertions(+) diff --git a/fs/ubifs/super.c b/fs/ubifs/super.c index 7560071534bf..4788420162b8 100644 --- a/fs/ubifs/super.c +++ b/fs/ubifs/super.c @@ -2

[PATCH 5/6] ubifs: Implement export_operations

2016-12-01 Thread Richard Weinberger
Signed-off-by: Richard Weinberger --- fs/ubifs/super.c | 31 +++ fs/ubifs/ubifs.h | 1 + 2 files changed, 32 insertions(+) diff --git a/fs/ubifs/super.c b/fs/ubifs/super.c index c50952f43e36..be5b697d8214 100644 --- a/fs/ubifs/super.c +++ b/fs/ubifs/super.c @@ -2006,