diff options
| -rw-r--r-- | fs/adfs/inode.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/fs/adfs/inode.c b/fs/adfs/inode.c index e91028d4340a..66621e96f9af 100644 --- a/fs/adfs/inode.c +++ b/fs/adfs/inode.c | |||
| @@ -167,7 +167,7 @@ adfs_mode2atts(struct super_block *sb, struct inode *inode) | |||
| 167 | * of time to convert from RISC OS epoch to Unix epoch. | 167 | * of time to convert from RISC OS epoch to Unix epoch. |
| 168 | */ | 168 | */ |
| 169 | static void | 169 | static void |
| 170 | adfs_adfs2unix_time(struct timespec *tv, struct inode *inode) | 170 | adfs_adfs2unix_time(struct timespec64 *tv, struct inode *inode) |
| 171 | { | 171 | { |
| 172 | unsigned int high, low; | 172 | unsigned int high, low; |
| 173 | /* 01 Jan 1970 00:00:00 (Unix epoch) as nanoseconds since | 173 | /* 01 Jan 1970 00:00:00 (Unix epoch) as nanoseconds since |
| @@ -195,11 +195,11 @@ adfs_adfs2unix_time(struct timespec *tv, struct inode *inode) | |||
| 195 | /* convert from RISC OS to Unix epoch */ | 195 | /* convert from RISC OS to Unix epoch */ |
| 196 | nsec -= nsec_unix_epoch_diff_risc_os_epoch; | 196 | nsec -= nsec_unix_epoch_diff_risc_os_epoch; |
| 197 | 197 | ||
| 198 | *tv = ns_to_timespec(nsec); | 198 | *tv = ns_to_timespec64(nsec); |
| 199 | return; | 199 | return; |
| 200 | 200 | ||
| 201 | cur_time: | 201 | cur_time: |
| 202 | *tv = timespec64_to_timespec(current_time(inode)); | 202 | *tv = current_time(inode); |
| 203 | return; | 203 | return; |
| 204 | 204 | ||
| 205 | too_early: | 205 | too_early: |
| @@ -242,7 +242,6 @@ adfs_unix2adfs_time(struct inode *inode, unsigned int secs) | |||
| 242 | struct inode * | 242 | struct inode * |
| 243 | adfs_iget(struct super_block *sb, struct object_info *obj) | 243 | adfs_iget(struct super_block *sb, struct object_info *obj) |
| 244 | { | 244 | { |
| 245 | struct timespec ts; | ||
| 246 | struct inode *inode; | 245 | struct inode *inode; |
| 247 | 246 | ||
| 248 | inode = new_inode(sb); | 247 | inode = new_inode(sb); |
| @@ -271,9 +270,7 @@ adfs_iget(struct super_block *sb, struct object_info *obj) | |||
| 271 | ADFS_I(inode)->stamped = ((obj->loadaddr & 0xfff00000) == 0xfff00000); | 270 | ADFS_I(inode)->stamped = ((obj->loadaddr & 0xfff00000) == 0xfff00000); |
| 272 | 271 | ||
| 273 | inode->i_mode = adfs_atts2mode(sb, inode); | 272 | inode->i_mode = adfs_atts2mode(sb, inode); |
| 274 | ts = timespec64_to_timespec(inode->i_mtime); | 273 | adfs_adfs2unix_time(&inode->i_mtime, inode); |
| 275 | adfs_adfs2unix_time(&ts, inode); | ||
| 276 | inode->i_mtime = timespec_to_timespec64(ts); | ||
| 277 | inode->i_atime = inode->i_mtime; | 274 | inode->i_atime = inode->i_mtime; |
| 278 | inode->i_ctime = inode->i_mtime; | 275 | inode->i_ctime = inode->i_mtime; |
| 279 | 276 | ||
