Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 15 Dec 2002 14:56:25 +0100
From:      Michael Ranner <mranner@inode.at>
To:        freebsd-hackers@freebsd.org
Subject:   Re: setattr() syscall as proposed by phk
Message-ID:  <200212151455.35023.mranner@inode.at>
In-Reply-To: <200212141624.46162.mranner@inode.at>
References:  <200212141624.46162.mranner@inode.at>

next in thread | previous in thread | raw e-mail | index | archive | help
Am Samstag, 14. Dezember 2002 16:24 schrieb Michael Ranner:
> Hi there!
>
> I have implemented the setattr(), lsetattr() and fsetattr() syscalls for
> 4.7 and 5.0. You can review my code on
> http://www.ranner.jawa.at/freebsd.php.
>

In between I have modfied 5.0 restore to use setattr(). Because of
the new UFS2 birth time attribute, I have to call utimes() before
setattr(). Struct stat has no member for the file birth time. Any
suggestions to improve setattr() in respect of the new UFS2.

The systime of 5.0 restore decreases around 9%.

from man utimes

 For filesystems that support file birth (creation) times (such as UFS2) the
 birth time will be set to the value of the second element if the second
 element is older than the currently set birth time.  To set both a birth
 time and a modification time, two calls are required; the first to set
 the birth time and the second to set the (presumably newer) modification
 time.  Ideally a new system call will be added that allows the setting of
 all three times at once.

I'm also willing to implement the proposed new syscall, any suggestions for
name and type of arguments (probably an array of struct timespec). The kernel 
code already supports an array with all three time stamps.

Regards,

/\/\ichael Ranner

mranner@jawa.at - mranner@bitonline.cc - webmaster@mariazell.at
----------------------------------------------------------------------
JAWA Management Software GmbH - http://www.jawa.at/
  Liebenauer Hauptstrasse 2oo - A-8041 Graz
        Tel +43 316 403274 21 - Fax +43 316 403274 10
----------------------------------------------------------------------
             Mariazell Online - http://www.mariazell.at/
----------------------------------------------------------------------

-----BEGIN GEEK CODE BLOCK-----
GIT/CS/AT dx(-) s+:(++:) a- C++ UBLVS++++$ P++>+++$ L-(+)$ E---
W+++$ N+(++) o-- K- w--()$ O-(--) M@ V-(--) PS+>++ PE(-) Y+ PGP(-)
t+ 5+ X+++(++++) R* tv++ b+(++) DI++ D-(--) G- e h--(*) r++ y?
------END GEEK CODE BLOCK------


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200212151455.35023.mranner>