again: if (!fscache_cache_is_live(cookie->volume->cache)) {
_leave(" [broken]"); returnfalse;
}
state = fscache_cookie_state(cookie);
_enter("c=%08x{%u},%x", cookie->debug_id, state, want_state);
switch (state) { case FSCACHE_COOKIE_STATE_CREATING: case FSCACHE_COOKIE_STATE_INVALIDATING: if (want_state == FSCACHE_WANT_PARAMS) goto ready; /* There can be no content */
fallthrough; case FSCACHE_COOKIE_STATE_LOOKING_UP: case FSCACHE_COOKIE_STATE_LRU_DISCARDING:
wait_var_event(&cookie->state,
fscache_cookie_state(cookie) != state); goto again;
case FSCACHE_COOKIE_STATE_ACTIVE: goto ready; case FSCACHE_COOKIE_STATE_DROPPED: case FSCACHE_COOKIE_STATE_RELINQUISHING: default:
_leave(" [not live]"); returnfalse;
}
ready: if (!cres->cache_priv2) return cookie->volume->cache->ops->begin_operation(cres, want_state); returntrue;
}
EXPORT_SYMBOL(fscache_wait_for_operation);
if (!fscache_begin_cookie_access(cookie, why)) {
cres->cache_priv = NULL; return -ENOBUFS;
}
again:
spin_lock(&cookie->lock);
state = fscache_cookie_state(cookie);
_enter("c=%08x{%u},%x", cookie->debug_id, state, want_state);
switch (state) { case FSCACHE_COOKIE_STATE_LOOKING_UP: case FSCACHE_COOKIE_STATE_LRU_DISCARDING: case FSCACHE_COOKIE_STATE_INVALIDATING: goto wait_for_file_wrangling; case FSCACHE_COOKIE_STATE_CREATING: if (want_state == FSCACHE_WANT_PARAMS) goto ready; /* There can be no content */ goto wait_for_file_wrangling; case FSCACHE_COOKIE_STATE_ACTIVE: goto ready; case FSCACHE_COOKIE_STATE_DROPPED: case FSCACHE_COOKIE_STATE_RELINQUISHING:
WARN(1, "Can't use cookie in state %u\n", cookie->state); goto not_live; default: goto not_live;
}
ready:
spin_unlock(&cookie->lock); if (!cookie->volume->cache->ops->begin_operation(cres, want_state)) goto failed; return0;
/* We cannot defer a resize as we need to do it inside the *netfs'sinodelocksothatwe'reserialisedwithrespectto *writes.
*/
cookie->volume->cache->ops->resize_cookie(&cres, new_size);
fscache_end_operation(&cres);
} else {
fscache_stat(&fscache_n_resizes_null);
}
}
EXPORT_SYMBOL(__fscache_resize_cookie);
Messung V0.5 in Prozent
¤ Dauer der Verarbeitung: 0.9 Sekunden
(vorverarbeitet am 2026-09-29)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.