Date: Sun, 18 Dec 2011 01:07:51 +0200 From: Andriy Gapon <avg@FreeBSD.org> To: hackers@FreeBSD.org Subject: RB_NOSYNC -> no device_shutdown ? Message-ID: <4EED20C7.1090704@FreeBSD.org>
next in thread | raw e-mail | index | archive | help
I look at the following code: static void module_init(void *arg) { sx_init(&modules_sx, "module subsystem sx lock"); TAILQ_INIT(&modules); EVENTHANDLER_REGISTER(shutdown_final, module_shutdown, NULL, SHUTDOWN_PRI_DEFAULT); } SYSINIT(module, SI_SUB_KLD, SI_ORDER_FIRST, module_init, 0); static void module_shutdown(void *arg1, int arg2) { module_t mod; if (arg2 & RB_NOSYNC) return; mtx_lock(&Giant); MOD_SLOCK; TAILQ_FOREACH_REVERSE(mod, &modules, modulelist, link) MOD_EVENT(mod, MOD_SHUTDOWN); MOD_SUNLOCK; mtx_unlock(&Giant); } and wonder why RB_NOSYNC is overloaded to mean that no MOD_SHUTDOWN/device_shutdown cleanup should be done? -- Andriy Gapon
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4EED20C7.1090704>