From owner-freebsd-hackers Mon Jul 9 0:18:31 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from bugz.infotecs.ru (bugz.infotecs.ru [195.210.139.22]) by hub.freebsd.org (Postfix) with ESMTP id CBAA737B403 for ; Mon, 9 Jul 2001 00:18:27 -0700 (PDT) (envelope-from vel@bugz.infotecs.ru) Received: (from vel@localhost) by bugz.infotecs.ru (8.11.1/8.11.1) id f697WdR00493 for freebsd-hackers@freebsd.org; Mon, 9 Jul 2001 11:32:39 +0400 (MSD) (envelope-from vel) From: "Eugene L. Vorokov" Message-Id: <200107090732.f697WdR00493@bugz.infotecs.ru> Subject: panic when returning error on MOD_LOAD To: freebsd-hackers@freebsd.org Date: Mon, 9 Jul 2001 11:32:39 +0400 (MSD) X-Mailer: ELM [version 2.4ME+ PL82 (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hello, I'm pretty confused with the fact that kernel panics when my module's event handler returns something greater than zero on MOD_LOAD. I wanted module to refuse to load when it can't find it's config file, so I thought I can return error code and it will not be loaded, and behaviour of module_register_init() and other related functions after quick look seems to be intended to do just that. That look very ugly ... what could I do wrong ? What is the proper way of doing what I wanted ? And oh yes, it's 4.2 system. Regards, Eugene To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message