lkml.org 
[lkml]   [2020]   [Nov]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 4/6] proc/stat: switch to ->read_iter
    Date
    Implement ->read_iter so that splice can be used on this file.

    Suggested-by: Linus Torvalds <torvalds@linux-foundation.org>
    Signed-off-by: Christoph Hellwig <hch@lst.de>
    ---
    fs/proc/stat.c | 2 +-
    1 file changed, 1 insertion(+), 1 deletion(-)

    diff --git a/fs/proc/stat.c b/fs/proc/stat.c
    index 46b3293015fe61..4695b6de315129 100644
    --- a/fs/proc/stat.c
    +++ b/fs/proc/stat.c
    @@ -226,7 +226,7 @@ static int stat_open(struct inode *inode, struct file *file)
    static const struct proc_ops stat_proc_ops = {
    .proc_flags = PROC_ENTRY_PERMANENT,
    .proc_open = stat_open,
    - .proc_read = seq_read,
    + .proc_read_iter = seq_read_iter,
    .proc_lseek = seq_lseek,
    .proc_release = single_release,
    };
    --
    2.28.0
    \
     
     \ /
      Last update: 2020-11-04 09:39    [W:4.152 / U:0.088 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site