diff options
-rw-r--r-- | fs/configfs/file.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/configfs/file.c b/fs/configfs/file.c index bbc1252a59f5..c30cf49b69d2 100644 --- a/fs/configfs/file.c +++ b/fs/configfs/file.c @@ -80,11 +80,11 @@ static int fill_read_buffer(struct dentry * dentry, struct configfs_buffer * buf count = attr->show(item, buffer->page); - buffer->needs_read_fill = 0; BUG_ON(count > (ssize_t)SIMPLE_ATTR_SIZE); - if (count >= 0) + if (count >= 0) { + buffer->needs_read_fill = 0; buffer->count = count; - else + } else ret = count; return ret; } |