2682 return (DDI_SUCCESS);
2683 }
2684
2685
2686
2687 /*
2688 * ========== Module Loading Data & Entry Points ==========
2689 */
2690
2691 DDI_DEFINE_STREAM_OPS(nge_dev_ops, nulldev, nulldev, nge_attach, nge_detach,
2692 NULL, NULL, D_MP, NULL, nge_quiesce);
2693
2694
2695 static struct modldrv nge_modldrv = {
2696 &mod_driverops, /* Type of module. This one is a driver */
2697 nge_ident, /* short description */
2698 &nge_dev_ops /* driver specific ops */
2699 };
2700
2701 static struct modlinkage modlinkage = {
2702 MODREV_1, (void *)&nge_modldrv, NULL
2703 };
2704
2705
2706 int
2707 _info(struct modinfo *modinfop)
2708 {
2709 return (mod_info(&modlinkage, modinfop));
2710 }
2711
2712 int
2713 _init(void)
2714 {
2715 int status;
2716
2717 mac_init_ops(&nge_dev_ops, "nge");
2718 status = mod_install(&modlinkage);
2719 if (status != DDI_SUCCESS)
2720 mac_fini_ops(&nge_dev_ops);
2721 else
2722 mutex_init(nge_log_mutex, NULL, MUTEX_DRIVER, NULL);
|
2682 return (DDI_SUCCESS);
2683 }
2684
2685
2686
2687 /*
2688 * ========== Module Loading Data & Entry Points ==========
2689 */
2690
2691 DDI_DEFINE_STREAM_OPS(nge_dev_ops, nulldev, nulldev, nge_attach, nge_detach,
2692 NULL, NULL, D_MP, NULL, nge_quiesce);
2693
2694
2695 static struct modldrv nge_modldrv = {
2696 &mod_driverops, /* Type of module. This one is a driver */
2697 nge_ident, /* short description */
2698 &nge_dev_ops /* driver specific ops */
2699 };
2700
2701 static struct modlinkage modlinkage = {
2702 MODREV_1, { (void *)&nge_modldrv, NULL }
2703 };
2704
2705
2706 int
2707 _info(struct modinfo *modinfop)
2708 {
2709 return (mod_info(&modlinkage, modinfop));
2710 }
2711
2712 int
2713 _init(void)
2714 {
2715 int status;
2716
2717 mac_init_ops(&nge_dev_ops, "nge");
2718 status = mod_install(&modlinkage);
2719 if (status != DDI_SUCCESS)
2720 mac_fini_ops(&nge_dev_ops);
2721 else
2722 mutex_init(nge_log_mutex, NULL, MUTEX_DRIVER, NULL);
|