summaryrefslogtreecommitdiffstats
path: root/sys/modules/ibcs2
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1995-11-14 07:35:57 +0000
committerbde <bde@FreeBSD.org>1995-11-14 07:35:57 +0000
commitb9f0e11d4abfe9a7de37f6760080f135ad5b588b (patch)
tree9c94bad3e616d0070b577e174ae969aefd06ef32 /sys/modules/ibcs2
parentebb856464a36a3c0c1fc2d5a6646a7b7934ec4b0 (diff)
downloadFreeBSD-src-b9f0e11d4abfe9a7de37f6760080f135ad5b588b.zip
FreeBSD-src-b9f0e11d4abfe9a7de37f6760080f135ad5b588b.tar.gz
Changed the first (name) arg of MOD_DEV(), MOD_EXEC() and MOD_MISC()
from a string to an identifier so that it can be used to generate declarations and strings. It's much easier to stringize an identifier than to identifize a string. A uniform naming scheme must be used for the automatically generated things to apply. This is a feature. Used the module identifer to generate prototypes for the module load, unload and stat functions. Removed the few prototypes for these that already existed. Used the module identifier to generate a unique struct tag in MOD_DEV(). This should probably be done for all the MOD_*() macros. Moved the trailing semicolon from the MOD_*() macro definitions to the macro invocations that didn't already (bogusly) have it. Staticized the module load and unload functions. Added function return types for the module load, unload and stat functions. lkm/ibcs2/ibcs2.c: Included <sys/sysproto.h> to get everything prototyped. Cleaned up #includes. lkm/ibcs2/ipfw.c: Cleaned up #includes. lkm/linux/linux.c: The module name had to change from "linux_emulator" to "linux_mod" to be automatically generated. Cleaned up #includes. lkm/syscons/*/*_saver.c: Completed delcarations of function pointers. sys/i386/isa/atapi.c: The module name had to change from "atapi" to "atapi_mod" to be automatically generated. sys/i386/isa/wcd.c: Used the fixed MOD_DEV(). This module has two devices and expanded the macro in the source instead of fixing it. The module names had to change from "wcd" and "rwcd" to "wcd_mod" and "rwcd_mod" to be automatically generated. sys/pccard/pcic.c: The module name had to change from "pcic" to "pcic_mod" to be automatically generated.
Diffstat (limited to 'sys/modules/ibcs2')
-rw-r--r--sys/modules/ibcs2/ibcs2.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/sys/modules/ibcs2/ibcs2.c b/sys/modules/ibcs2/ibcs2.c
index 4db2adf..f7f9ec1 100644
--- a/sys/modules/ibcs2/ibcs2.c
+++ b/sys/modules/ibcs2/ibcs2.c
@@ -25,31 +25,27 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $Id: ibcs2.c,v 1.5 1995/10/28 12:35:03 peter Exp $
+ * $Id: ibcs2.c,v 1.6 1995/11/13 07:18:27 bde Exp $
*/
#include <sys/param.h>
#include <sys/systm.h>
+#include <sys/sysproto.h>
#include <sys/conf.h>
#include <sys/exec.h>
#include <sys/sysent.h>
#include <sys/lkm.h>
-#include <sys/errno.h>
-MOD_MISC("ibcs2_mod")
+MOD_MISC(ibcs2);
-int ibcs2_load __P((struct lkm_table *, int));
-int ibcs2_unload __P((struct lkm_table *, int));
-int ibcs2_init __P((struct lkm_table *, int, int));
-
-int
+static int
ibcs2_load(struct lkm_table *lkmtp, int cmd)
{
uprintf("ibcs2 emulator installed\n");
return 0;
}
-int
+static int
ibcs2_unload(struct lkm_table *lkmtp, int cmd)
{
uprintf("ibcs2 emulator removed\n");
OpenPOWER on IntegriCloud