xfs
[Top] [All Lists]

Re: Interface for the new fallocate() system call

To: "linux-os (Dick Johnson)" <linux-os@xxxxxxxxxxxx>
Subject: Re: Interface for the new fallocate() system call
From: Jan Engelhardt <jengelh@xxxxxxxxxxxxxxx>
Date: Thu, 29 Mar 2007 20:05:24 +0200 (MEST)
Cc: "Amit K. Arora" <aarora@xxxxxxxxxxxxxxxxxx>, torvalds@xxxxxxxx, akpm@xxxxxxxxxxxxxxxxxxxx, linux-fsdevel@xxxxxxxxxxxxxxx, linux-kernel@xxxxxxxxxxxxxxx, linux-ext4@xxxxxxxxxxxxxxx, xfs@xxxxxxxxxxx, suparna@xxxxxxxxxx, cmm@xxxxxxxxxx
In-reply-to: <Pine.LNX.4.61.0703291314330.4366@xxxxxxxxxxxxxxxxxx>
References: <20070117094658.GA17390@xxxxxxxxxxxxxxxxxxxx> <20070225022326.137b4875.akpm@xxxxxxxxxxxxxxxxxxxx> <20070301183445.GA7911@xxxxxxxxxxxxxxxxxxxx> <20070316143101.GA10152@xxxxxxxxxxxxxxxxxxxx> <20070316161704.GE8525@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> <20070317111036.GC29931@xxxxxxxxxxxxxxxx> <20070321120425.GA27273@xxxxxxxxxxxxxxxxxxxx> <20070329115126.GB7374@xxxxxxxxxxxxxxxxxxxx> <Pine.LNX.4.61.0703291854000.31834@xxxxxxxxxxxxxxx> <Pine.LNX.4.61.0703291314330.4366@xxxxxxxxxxxxxxxxxx>
Sender: xfs-bounce@xxxxxxxxxxx
 
On Mar 29 2007 13:18, linux-os (Dick Johnson) wrote:
>
>I think it's always better to put only a pointer on the stack as
>above.

I have to disagree, since wrapping it into a struct and copying the struct
in kernelspace from userspace requires more code. Pointers only become
useful at 3 (rarely) or 4 (yeah, more likely) and 5+ (definitely)
arguments, (3) see above about copying, (4) middle thing and (5) tons of
arguments like mmap() should be wrapped up... for simplicity of dealing
with it later.


Jan
-- 


<Prev in Thread] Current Thread [Next in Thread>