// SPDX-License-Identifier: GPL-2.0-only /* * 9P entry point * * Copyright (C) 2007 by Latchesar Ionkov <lucho@ionkov.net> * Copyright (C) 2004 by Eric Van Hensbergen <ericvh@gmail.com> * Copyright (C) 2002 by Ron Minnich <rminnich@lanl.gov>
*/
/** * v9fs_register_trans - register a new transport with 9p * @m: structure describing the transport module and entry points *
*/ void v9fs_register_trans(struct p9_trans_module *m)
{
spin_lock(&v9fs_trans_lock);
list_add_tail(&m->list, &v9fs_trans_list);
spin_unlock(&v9fs_trans_lock);
}
EXPORT_SYMBOL(v9fs_register_trans);
/** * v9fs_unregister_trans - unregister a 9p transport * @m: the transport to remove *
*/ void v9fs_unregister_trans(struct p9_trans_module *m)
{
spin_lock(&v9fs_trans_lock);
list_del_init(&m->list);
spin_unlock(&v9fs_trans_lock);
}
EXPORT_SYMBOL(v9fs_unregister_trans);
list_for_each_entry(t, &v9fs_trans_list, list) if (strcmp(t->name, s) == 0 &&
try_module_get(t->owner)) {
found = t; break;
}
spin_unlock(&v9fs_trans_lock);
return found;
}
/** * v9fs_get_trans_by_name - get transport with the matching name * @s: string identifying transport *
*/ struct p9_trans_module *v9fs_get_trans_by_name(constchar *s)
{ struct p9_trans_module *found = NULL;
found = _p9_get_trans_by_name(s);
#ifdef CONFIG_MODULES if (!found) {
request_module("9p-%s", s);
found = _p9_get_trans_by_name(s);
} #endif
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.