Hi All, I wanted to add a psuedo network driver can any one tell me what else needs to be done here to provide a simple psuedo interface
test_modevent(module_t mod, int type, void *data) { switch (type) { case MOD_LOAD: uprintf("The psuedo driver loaded\n"); //attach a ifnet structure ip=(struct inet *)malloc(sizeof(struct ifnet),M_DEVBUF,M_WAITOK); ip->if_dname="test"; ip->if_flags = IFF_UP| IFF_RUNNING| IFF_POINTOPOINT | IFF_MULTICAST | IFF_NEEDSGIANT; ip->if_ioctl = test_sioctl; ip->if_start = test_ifstart; ip->if_watchdog = test_ifwatchdog; ip->if_init = test_initialize; strlcpy(ip->if_xname, "test",5); if_attach (ip); break; case MOD_UNLOAD: uprintf("test_ps module unload - not possible for this module type\n"); if_detach (ip); free(ip,M_DEVBUF); return EINVAL; default: return EOPNOTSUPP; } return 0; } Thanks and Regards, Rashmi.N.S _______________________________________________ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"