* obd_osfs_age */
#define OBD_STATFS_FOR_MDT0 0x0004 /* The statfs is only for retrieving
* information from MDT0. */
+#define OBD_STATFS_SUM 0x0008 /* get aggregated statfs from MDT */
extern rwlock_t obd_dev_lock;
CDEBUG(D_SUPER, "osfs %lld, max_age %lld\n",
obd->obd_osfs_age, max_age);
- if (obd->obd_osfs_age < max_age) {
+ /* ignore cache if aggregated isn't expected */
+ if (obd->obd_osfs_age < max_age ||
+ ((obd->obd_osfs.os_state & OS_STATE_SUM) &&
+ !(flags & OBD_STATFS_SUM))) {
rc = OBP(obd, statfs)(env, exp, osfs, max_age, flags);
if (rc == 0) {
spin_lock(&obd->obd_osfs_lock);