FreeBSD/sys/compat/linux/linux_mib.c
/*
 * Find a prison with Linux info.
 * Return the Linux info and the (locked) prison.
 */
Find a prison with Linux info.
Return the Linux info and the (locked) prison.
Find a prison with Linux info . Return the Linux info and the ( locked ) prison .
static struct linux_prison *
linux_find_prison(struct prison *spr, struct prison **prp)
{
	struct prison *pr;
	struct linux_prison *lpr;
	for (pr = spr;; pr = pr->pr_parent) {
		mtx_lock(&pr->pr_mtx);
		lpr = (pr == &prison0)
		    ? &lprison0
		    : osd_jail_get(pr, linux_osd_jail_slot);
		if (lpr != NULL)
			break;
		mtx_unlock(&pr->pr_mtx);
	}
	*prp = pr;
	return (lpr);
}
static struct linux_prison * linux_find_prison ( struct prison * spr , struct prison * * prp ) { struct prison * pr ; struct linux_prison * lpr ; for ( pr = spr ; ; pr = pr -> pr_parent ) { mtx_lock ( & pr -> pr_mtx ) ; lpr = ( pr == & prison0 ) ? & lprison0 : osd_jail_get ( pr , linux_osd_jail_slot ) ; if ( lpr != NULL ) break ; mtx_unlock ( & pr -> pr_mtx ) ; } * prp = pr ; return ( lpr ) ; }
Find a prison with Linux info.
Find a prison with Linux info .