Whamcloud - gitweb
LU-7896: do not call lu_site_purge() for single object exceed
[fs/lustre-release.git] / lustre / include / lu_object.h
index 18f1ad6..e8e4cf4 100644 (file)
@@ -729,8 +729,14 @@ static inline int lu_object_is_dying(const struct lu_object_header *h)
 void lu_object_put(const struct lu_env *env, struct lu_object *o);
 void lu_object_put_nocache(const struct lu_env *env, struct lu_object *o);
 void lu_object_unhash(const struct lu_env *env, struct lu_object *o);
+int lu_site_purge_objects(const struct lu_env *env, struct lu_site *s, int nr,
+                         int canblock);
 
-int lu_site_purge(const struct lu_env *env, struct lu_site *s, int nr);
+static inline int lu_site_purge(const struct lu_env *env, struct lu_site *s,
+                               int nr)
+{
+       return lu_site_purge_objects(env, s, nr, 1);
+}
 
 void lu_site_print(const struct lu_env *env, struct lu_site *s, void *cookie,
                    lu_printer_t printer);