Skip to content

Commit

Permalink
splice: always updated atime in direct splice
Browse files Browse the repository at this point in the history
Andre Majorel <[email protected]> points out that if we only updated
the atime when we transfer some data, we deviate from the standard
of always updating the atime. So change splice to always call
file_accessed() even if splice_direct_to_actor() didn't transfer
any data.

Signed-off-by: Jens Axboe <[email protected]>
  • Loading branch information
Jens Axboe committed Feb 1, 2008
1 parent 13f09b9 commit 8084870
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions fs/splice.c
Original file line number Diff line number Diff line change
Expand Up @@ -1033,9 +1033,7 @@ ssize_t splice_direct_to_actor(struct file *in, struct splice_desc *sd,

done:
pipe->nrbufs = pipe->curbuf = 0;
if (bytes > 0)
file_accessed(in);

file_accessed(in);
return bytes;

out_release:
Expand Down

0 comments on commit 8084870

Please sign in to comment.