MCPcopy Create free account
hub / github.com/F-Stack/f-stack / cache_fpl_aborted_impl

Function cache_fpl_aborted_impl

freebsd/kern/vfs_cache.c:3889–3917  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3887#define cache_fpl_aborted_early(x) cache_fpl_aborted_early_impl((x), __LINE__)
3888
3889static int __noinline
3890cache_fpl_aborted_impl(struct cache_fpl *fpl, int line)
3891{
3892 struct nameidata *ndp;
3893 struct componentname *cnp;
3894
3895 ndp = fpl->ndp;
3896 cnp = fpl->cnp;
3897
3898 if (fpl->status != CACHE_FPL_STATUS_UNSET) {
3899 KASSERT(fpl->status == CACHE_FPL_STATUS_PARTIAL,
3900 ("%s: converting to abort from %d at %d, set at %d\n",
3901 __func__, fpl->status, line, fpl->line));
3902 }
3903 fpl->status = CACHE_FPL_STATUS_ABORTED;
3904 fpl->line = line;
3905 if (fpl->in_smr)
3906 cache_fpl_smr_exit(fpl);
3907 cache_fpl_restore_abort(fpl);
3908 /*
3909 * Resolving symlinks overwrites data passed by the caller.
3910 * Let namei know.
3911 */
3912 if (ndp->ni_loopcnt > 0) {
3913 fpl->status = CACHE_FPL_STATUS_DESTROYED;
3914 cache_fpl_cleanup_cnp(cnp);
3915 }
3916 return (CACHE_FPL_FAILED);
3917}
3918
3919#define cache_fpl_aborted(x) cache_fpl_aborted_impl((x), __LINE__)
3920

Callers

nothing calls this directly

Calls 2

cache_fpl_restore_abortFunction · 0.85
cache_fpl_cleanup_cnpFunction · 0.85

Tested by

no test coverage detected