locks: fix fcntl_setlease/getlease return when !CONFIG_FILE_LOCKING
[firefly-linux-kernel-4.4.55.git] / fs / lockd / mon.c
index 1812f026960c4229dd4c3d198b129f9554eb6fc4..daa8e7514eae7b4d23e485bd94b46ea7f8b8e35d 100644 (file)
@@ -306,11 +306,9 @@ static struct nsm_handle *nsm_lookup_priv(const struct nsm_private *priv)
 static void nsm_init_private(struct nsm_handle *nsm)
 {
        u64 *p = (u64 *)&nsm->sm_priv.data;
-       struct timespec ts;
        s64 ns;
 
-       ktime_get_ts(&ts);
-       ns = timespec_to_ns(&ts);
+       ns = ktime_get_ns();
        put_unaligned(ns, p);
        put_unaligned((unsigned long)nsm, p + 1);
 }