X-Git-Url: https://yaffs.net/gitweb/?a=blobdiff_plain;f=rtems%2Frtems_yaffs.c;h=bb6edf1467871feed61567b09a14c24d2118816c;hb=ebc54da9e29be1de79d77c72c0d8eb91833c641b;hp=8ee0b899baecb1d51d3a8dcf257803bbccf88095;hpb=8921e0e0ebe4265c5549a790e166c54a826ad512;p=yaffs2.git diff --git a/rtems/rtems_yaffs.c b/rtems/rtems_yaffs.c index 8ee0b89..bb6edf1 100644 --- a/rtems/rtems_yaffs.c +++ b/rtems/rtems_yaffs.c @@ -281,9 +281,9 @@ static int ryfs_utime( obj = yaffs_get_equivalent_obj(obj); if (obj != NULL) { obj->dirty = 1; - obj->yst_atime = (u32) actime; - obj->yst_mtime = (u32) modtime; - obj->yst_ctime = (u32) time(NULL); + obj->yst_atime = actime; + obj->yst_mtime = modtime; + obj->yst_ctime = time(NULL); } else { errno = EIO; rv = -1; @@ -680,18 +680,10 @@ static int ryfs_symlink(const rtems_filesystem_location_info_t *parent_loc, mode = S_IFLNK | ((S_IRWXU | S_IRWXG | S_IRWXO) & ~rtems_filesystem_umask); - created_link = yaffs_create_symlink(parent_dir, name, mode, + created_link = yaffs_create_symlink(parent_dir, name, mode, geteuid(), getegid(), target); if (created_link != NULL) { - // In RTEMS VFS, there is no filesytem-wide sync(), only per-file - // flushes. Filesystem-wide sync is implemented by looping over all of - // the open files and individually fsync()ing them. That's part of why - // every close() in RTEMS-yaffs is accompanied by an implicit fsync(). - // There is no such close() call associated with the symlink's creation, - // since it wasn't created via open(). Therefore, flush it immediately - // instead. - yaffs_flush_file(created_link, 0, 0, 0); ret = 0; } else { errno = EINVAL;