diff options
author | Arnd Bergmann <arnd@arndb.de> | 2018-06-19 17:27:58 +0200 |
---|---|---|
committer | Steve French <stfrench@microsoft.com> | 2018-08-07 21:15:41 +0200 |
commit | 95390201e7d8dd1eb764a3cbd50ae538a17fcd02 (patch) | |
tree | dd5d0428de988c059ff84ef286c05c393dee1e0d /fs/cifs/cifsencrypt.c | |
parent | cifs: Silence uninitialized variable warning (diff) | |
download | linux-95390201e7d8dd1eb764a3cbd50ae538a17fcd02.tar.xz linux-95390201e7d8dd1eb764a3cbd50ae538a17fcd02.zip |
cifs: use timespec64 internally
In cifs, the timestamps are stored in memory in the cifs_fattr structure,
which uses the deprecated 'timespec' structure. Now that the VFS code
has moved on to 'timespec64', the next step is to change over the fattr
as well.
This also makes 32-bit and 64-bit systems behave the same way, and
no longer overflow the 32-bit time_t in year 2038.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Paulo Alcantara <palcantara@suse.de>
Signed-off-by: Steve French <stfrench@microsoft.com>
Diffstat (limited to 'fs/cifs/cifsencrypt.c')
-rw-r--r-- | fs/cifs/cifsencrypt.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/cifs/cifsencrypt.c b/fs/cifs/cifsencrypt.c index ee2a8ec70056..b4672eafc5bf 100644 --- a/fs/cifs/cifsencrypt.c +++ b/fs/cifs/cifsencrypt.c @@ -452,7 +452,7 @@ find_timestamp(struct cifs_ses *ses) unsigned char *blobptr; unsigned char *blobend; struct ntlmssp2_name *attrptr; - struct timespec ts; + struct timespec64 ts; if (!ses->auth_key.len || !ses->auth_key.response) return 0; @@ -477,7 +477,7 @@ find_timestamp(struct cifs_ses *ses) blobptr += attrsize; /* advance attr value */ } - ktime_get_real_ts(&ts); + ktime_get_real_ts64(&ts); return cpu_to_le64(cifs_UnixTimeToNT(ts)); } |