[PATCH v4] seq_file: reset iterator to first record for zero offset

2016-11-29 Thread Tomasz Majchrzak
will not return iterator as position is already on the second object. This defect doesn't allow to monitor badblocks sysfs files from MD raid. They are initially empty but if data appears at some stage, userspace is not able to read it. Signed-off-by: Tomasz Majchrzak <tomasz.majchr...@intel.

[PATCH v4] seq_file: reset iterator to first record for zero offset

2016-11-29 Thread Tomasz Majchrzak
will not return iterator as position is already on the second object. This defect doesn't allow to monitor badblocks sysfs files from MD raid. They are initially empty but if data appears at some stage, userspace is not able to read it. Signed-off-by: Tomasz Majchrzak Acked-by: Miklos Szeredi

[PATCH v3] seq_file: reset iterator to first record for zero offset

2016-11-28 Thread Tomasz Majchrzak
will not return iterator as position is already on the second object. This defect doesn't allow to monitor badblocks sysfs files from MD raid. They are initially empty but if data appears at some stage, userspace is not able to read it. Signed-off-by: Tomasz Majchrzak <tomasz.majchr...@intel.

[PATCH v3] seq_file: reset iterator to first record for zero offset

2016-11-28 Thread Tomasz Majchrzak
will not return iterator as position is already on the second object. This defect doesn't allow to monitor badblocks sysfs files from MD raid. They are initially empty but if data appears at some stage, userspace is not able to read it. Signed-off-by: Tomasz Majchrzak --- fs/seq_file.c | 3 +++ 1

Re: [PATCH v2][RESEND] seq_file: don't set read position for invalid iterator

2016-11-24 Thread Tomasz Majchrzak
On Wed, Nov 02, 2016 at 10:11:47AM +0100, Miklos Szeredi wrote: > On Mon, Oct 31, 2016 at 10:32:21AM +0100, Tomasz Majchrzak wrote: > > On Wed, Oct 26, 2016 at 11:17:13AM +0200, Miklos Szeredi wrote: > > > On Wed, Oct 12, 2016 at 2:07 PM, Tomasz Majchrzak > > > <tom

Re: [PATCH v2][RESEND] seq_file: don't set read position for invalid iterator

2016-11-24 Thread Tomasz Majchrzak
On Wed, Nov 02, 2016 at 10:11:47AM +0100, Miklos Szeredi wrote: > On Mon, Oct 31, 2016 at 10:32:21AM +0100, Tomasz Majchrzak wrote: > > On Wed, Oct 26, 2016 at 11:17:13AM +0200, Miklos Szeredi wrote: > > > On Wed, Oct 12, 2016 at 2:07 PM, Tomasz Majchrzak > > > wr

Re: [PATCH v2][RESEND] seq_file: don't set read position for invalid iterator

2016-10-31 Thread Tomasz Majchrzak
On Wed, Oct 26, 2016 at 11:17:13AM +0200, Miklos Szeredi wrote: > On Wed, Oct 12, 2016 at 2:07 PM, Tomasz Majchrzak > <tomasz.majchr...@intel.com> wrote: > > If kernfs file is empty on a first read, successive read operations > > using the same file descriptor will return

Re: [PATCH v2][RESEND] seq_file: don't set read position for invalid iterator

2016-10-31 Thread Tomasz Majchrzak
On Wed, Oct 26, 2016 at 11:17:13AM +0200, Miklos Szeredi wrote: > On Wed, Oct 12, 2016 at 2:07 PM, Tomasz Majchrzak > wrote: > > If kernfs file is empty on a first read, successive read operations > > using the same file descriptor will return no data, even when data is >

[PATCH v2][RESEND] seq_file: don't set read position for invalid iterator

2016-10-12 Thread Tomasz Majchrzak
for upcoming bad block support for external metadata in MD raid. Signed-off-by: Tomasz Majchrzak <tomasz.majchr...@intel.com> Reviewed-by: Dan Williams <dan.j.willi...@intel.com> --- fs/seq_file.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fs/seq_file.c b/f

[PATCH v2][RESEND] seq_file: don't set read position for invalid iterator

2016-10-12 Thread Tomasz Majchrzak
for upcoming bad block support for external metadata in MD raid. Signed-off-by: Tomasz Majchrzak Reviewed-by: Dan Williams --- fs/seq_file.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fs/seq_file.c b/fs/seq_file.c index 6dc4296..74197f4 100644 --- a/fs/seq_file.c +++ b

[PATCH v2] seq_file: don't set read position for invalid iterator

2016-09-27 Thread Tomasz Majchrzak
for upcoming bad block support for external metadata in MD raid. Signed-off-by: Tomasz Majchrzak <tomasz.majchr...@intel.com> Reviewed-by: Dan Williams <dan.j.willi...@intel.com> --- fs/seq_file.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fs/seq_file.c b/f

[PATCH v2] seq_file: don't set read position for invalid iterator

2016-09-27 Thread Tomasz Majchrzak
for upcoming bad block support for external metadata in MD raid. Signed-off-by: Tomasz Majchrzak Reviewed-by: Dan Williams --- fs/seq_file.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fs/seq_file.c b/fs/seq_file.c index 6dc4296..74197f4 100644 --- a/fs/seq_file.c +++ b