Print this page
7127  remove -Wno-missing-braces from Makefile.uts


3526 /*
3527  * Module loading and removing entry points.
3528  */
3529 DDI_DEFINE_STREAM_OPS(hxge_dev_ops, nulldev, nulldev, hxge_attach, hxge_detach,
3530     nodev, NULL, D_MP, NULL, NULL);
3531 
3532 extern struct mod_ops mod_driverops;
3533 
3534 #define HXGE_DESC_VER   "HXGE 10Gb Ethernet Driver"
3535 
3536 /*
3537  * Module linkage information for the kernel.
3538  */
3539 static struct modldrv hxge_modldrv = {
3540         &mod_driverops,
3541         HXGE_DESC_VER,
3542         &hxge_dev_ops
3543 };
3544 
3545 static struct modlinkage modlinkage = {
3546         MODREV_1, (void *) &hxge_modldrv, NULL
3547 };
3548 
3549 int
3550 _init(void)
3551 {
3552         int status;
3553 
3554         HXGE_DEBUG_MSG((NULL, MOD_CTL, "==> _init"));
3555         mac_init_ops(&hxge_dev_ops, "hxge");
3556         status = ddi_soft_state_init(&hxge_list, sizeof (hxge_t), 0);
3557         if (status != 0) {
3558                 HXGE_ERROR_MSG((NULL, HXGE_ERR_CTL,
3559                     "failed to init device soft state"));
3560                 mac_fini_ops(&hxge_dev_ops);
3561                 goto _init_exit;
3562         }
3563 
3564         status = mod_install(&modlinkage);
3565         if (status != 0) {
3566                 ddi_soft_state_fini(&hxge_list);




3526 /*
3527  * Module loading and removing entry points.
3528  */
3529 DDI_DEFINE_STREAM_OPS(hxge_dev_ops, nulldev, nulldev, hxge_attach, hxge_detach,
3530     nodev, NULL, D_MP, NULL, NULL);
3531 
3532 extern struct mod_ops mod_driverops;
3533 
3534 #define HXGE_DESC_VER   "HXGE 10Gb Ethernet Driver"
3535 
3536 /*
3537  * Module linkage information for the kernel.
3538  */
3539 static struct modldrv hxge_modldrv = {
3540         &mod_driverops,
3541         HXGE_DESC_VER,
3542         &hxge_dev_ops
3543 };
3544 
3545 static struct modlinkage modlinkage = {
3546         MODREV_1, { (void *) &hxge_modldrv, NULL }
3547 };
3548 
3549 int
3550 _init(void)
3551 {
3552         int status;
3553 
3554         HXGE_DEBUG_MSG((NULL, MOD_CTL, "==> _init"));
3555         mac_init_ops(&hxge_dev_ops, "hxge");
3556         status = ddi_soft_state_init(&hxge_list, sizeof (hxge_t), 0);
3557         if (status != 0) {
3558                 HXGE_ERROR_MSG((NULL, HXGE_ERR_CTL,
3559                     "failed to init device soft state"));
3560                 mac_fini_ops(&hxge_dev_ops);
3561                 goto _init_exit;
3562         }
3563 
3564         status = mod_install(&modlinkage);
3565         if (status != 0) {
3566                 ddi_soft_state_fini(&hxge_list);