Re: [PATCH] sysfs: correctly handle read offset on PREALLOC attrs

2016-09-05 Thread Konstantin Khlebnikov
On Mon, Sep 5, 2016 at 5:13 PM, Greg Kroah-Hartman wrote: > On Mon, Sep 05, 2016 at 03:46:28PM +0200, Greg Kroah-Hartman wrote: >> On Mon, Sep 05, 2016 at 04:25:48PM +0300, Konstantin Khlebnikov wrote: >> > Bump >> >> Huh? >> >> > On Wed, Jun 22, 2016 at 9:42 PM, Konstantin Khlebnikov >> > wrote:

Re: [PATCH] sysfs: correctly handle read offset on PREALLOC attrs

2016-09-05 Thread Greg Kroah-Hartman
On Mon, Sep 05, 2016 at 05:02:43PM +0300, Konstantin Khlebnikov wrote: > On 05.09.2016 16:46, Greg Kroah-Hartman wrote: > > On Mon, Sep 05, 2016 at 04:25:48PM +0300, Konstantin Khlebnikov wrote: > > > Bump > > > > Huh? > > > > > On Wed, Jun 22, 2016 at 9:42 PM, Konstantin Khlebnikov > > > wrote:

Re: [PATCH] sysfs: correctly handle read offset on PREALLOC attrs

2016-09-05 Thread Greg Kroah-Hartman
On Mon, Sep 05, 2016 at 03:46:28PM +0200, Greg Kroah-Hartman wrote: > On Mon, Sep 05, 2016 at 04:25:48PM +0300, Konstantin Khlebnikov wrote: > > Bump > > Huh? > > > On Wed, Jun 22, 2016 at 9:42 PM, Konstantin Khlebnikov > > wrote: > > > Attributes declared with __ATTR_PREALLOC use sysfs_kf_read(

Re: [PATCH] sysfs: correctly handle read offset on PREALLOC attrs

2016-09-05 Thread Konstantin Khlebnikov
On 05.09.2016 16:46, Greg Kroah-Hartman wrote: On Mon, Sep 05, 2016 at 04:25:48PM +0300, Konstantin Khlebnikov wrote: Bump Huh? On Wed, Jun 22, 2016 at 9:42 PM, Konstantin Khlebnikov wrote: Attributes declared with __ATTR_PREALLOC use sysfs_kf_read() which returns zero bytes for non-zero o

Re: [PATCH] sysfs: correctly handle read offset on PREALLOC attrs

2016-09-05 Thread Greg Kroah-Hartman
On Mon, Sep 05, 2016 at 04:25:48PM +0300, Konstantin Khlebnikov wrote: > Bump Huh? > On Wed, Jun 22, 2016 at 9:42 PM, Konstantin Khlebnikov > wrote: > > Attributes declared with __ATTR_PREALLOC use sysfs_kf_read() which returns > > zero bytes for non-zero offset. This breaks script checkarray in

Re: [PATCH] sysfs: correctly handle read offset on PREALLOC attrs

2016-09-05 Thread Konstantin Khlebnikov
Bump On Wed, Jun 22, 2016 at 9:42 PM, Konstantin Khlebnikov wrote: > Attributes declared with __ATTR_PREALLOC use sysfs_kf_read() which returns > zero bytes for non-zero offset. This breaks script checkarray in mdadm tool > in debian where /bin/sh is 'dash' because its builtin 'read' reads only o

Re: [PATCH] sysfs: correctly handle read offset on PREALLOC attrs

2016-06-23 Thread Tejun Heo
On Wed, Jun 22, 2016 at 09:42:16PM +0300, Konstantin Khlebnikov wrote: > Attributes declared with __ATTR_PREALLOC use sysfs_kf_read() which returns > zero bytes for non-zero offset. This breaks script checkarray in mdadm tool > in debian where /bin/sh is 'dash' because its builtin 'read' reads only

[PATCH] sysfs: correctly handle read offset on PREALLOC attrs

2016-06-22 Thread Konstantin Khlebnikov
Attributes declared with __ATTR_PREALLOC use sysfs_kf_read() which returns zero bytes for non-zero offset. This breaks script checkarray in mdadm tool in debian where /bin/sh is 'dash' because its builtin 'read' reads only one byte at a time. Script gets 'i' instead of 'idle' when reads current act