lkml.org 
[lkml]   [2011]   [Aug]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH 4/7] VFS: Add generic_file_llseek_size
Date
On Monday 22 August 2011, Andi Kleen wrote:
> From: Andi Kleen <ak@linux.intel.com>
>
> Add a generic_file_llseek variant to the VFS that allows passing in
> the current file size, instead of always using inode->i_size.
> This can be used to eliminate some cut'n'paste seek code in ext4.
>
> Signed-off-by: Andi Kleen <ak@linux.intel.com>

Ah, very nice. I think you can use the same trick to remove duplication
in default_llseek by always setting the limit to MAX_LFS_FILESIZE.

Arnd


\
 
 \ /
  Last update: 2011-08-23 14:55    [W:0.111 / U:0.480 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site