Whamcloud - gitweb
LU-3938 osd-zfs: Account for ZAP when shrinking an xattr
[fs/lustre-release.git] / lustre / lov / lov_io.c
index 5d2b455..c163cfa 100644 (file)
@@ -197,6 +197,7 @@ static int lov_io_sub_init(const struct lu_env *env, struct lov_io *lio,
                 sub_io->ci_lockreq = io->ci_lockreq;
                 sub_io->ci_type    = io->ci_type;
                 sub_io->ci_no_srvlock = io->ci_no_srvlock;
+               sub_io->ci_noatime = io->ci_noatime;
 
                 lov_sub_enter(sub);
                 result = cl_io_sub_init(sub->sub_env, sub_io,
@@ -278,11 +279,12 @@ struct lov_io_sub *lov_page_subio(const struct lu_env *env, struct lov_io *lio,
 static int lov_io_subio_init(const struct lu_env *env, struct lov_io *lio,
                              struct cl_io *io)
 {
-       struct lov_stripe_md *lsm = lio->lis_object->lo_lsm;
+       struct lov_stripe_md *lsm;
        int result;
+       ENTRY;
 
-        LASSERT(lio->lis_object != NULL);
-        ENTRY;
+       LASSERT(lio->lis_object != NULL);
+       lsm = lio->lis_object->lo_lsm;
 
         /*
          * Need to be optimized, we can't afford to allocate a piece of memory
@@ -374,7 +376,7 @@ static void lov_io_fini(const struct lu_env *env, const struct cl_io_slice *ios)
 
        LASSERT(cfs_atomic_read(&lov->lo_active_ios) > 0);
        if (cfs_atomic_dec_and_test(&lov->lo_active_ios))
-               cfs_waitq_broadcast(&lov->lo_waitq);
+               wake_up_all(&lov->lo_waitq);
        EXIT;
 }
 
@@ -846,7 +848,7 @@ static void lov_empty_io_fini(const struct lu_env *env,
         ENTRY;
 
        if (cfs_atomic_dec_and_test(&lov->lo_active_ios))
-               cfs_waitq_broadcast(&lov->lo_waitq);
+               wake_up_all(&lov->lo_waitq);
         EXIT;
 }