⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ee_wstrt.c,v

📁 用TCP/IP进行网际互连这本书得源代码,偶得,希望大家喜欢.推荐下载
💻 C,V
字号:
head	1.3;access;symbols;locks	dls:1.3; strict;comment	@ * @;1.3date	97.09.21.19.25.55;	author dls;	state Dist;branches;next	1.2;1.2date	95.02.05.21.42.57;	author dls;	state Broken;branches;next	1.1;1.1date	94.09.24.01.00.41;	author dls;	state Works;branches;next	;desc@@1.3log@pre-3e code@text@/* ee_wstrt.c - ee_wstrt */#include <conf.h>#include <kernel.h>#include <network.h>#include <ee.h>static count = 0;/*------------------------------------------------------------------------ * ee_wstrt - start output on an Intel EtherExpress *------------------------------------------------------------------------ */intee_wstrt(ped)struct etdev	*ped;{	STATWORD	ps;	struct tbd	*ptdb;	unsigned int	csr;	struct ep	*pep;	int		len, isbcast;	disable(ps);	if (ped->ed_xpending) {		restore(ps);		return OK;	}	ped->ed_xpending++;	pep = (struct ep *)deq(ped->ed_outq);	switch ((int)pep) {	case 0:		ped->ed_xpending--;		restore(ps);		return OK;	case EE_SETMULTI:		restore(ps);		return ee_cmd(ped, EECMD_MCSET|EECMD_I, ped->ed_mca,			ped->ed_mcc);	default:		break;	}	isbcast = blkequ(pep->ep_dst, ped->ed_bcast, EP_ALEN);	len = pep->ep_len;	/* this version supports one packet per interrupt only */	blkcopy(ped->ed_xmbuf, &pep->ep_eh, pep->ep_len);	ptdb = ped->ed_tbd;	ptdb->tbd_count = len;	ptdb->tbd_eof = 1;	freebuf(pep);	restore(ps);	if (isbcast)		nif[ped->ed_ifnum].ni_onucast++;	else		nif[ped->ed_ifnum].ni_oucast++;	nif[ped->ed_ifnum].ni_ooctets += len;	return ee_cmd(ped, EECMD_TX|EECMD_I);}@1.2log@*** empty log message ***@text@d20 1d25 1a25 5	wait(ped->ed_cmutex);	if (ped->ed_mcset) {kprintf("calling eecmd\n");		ped->ed_mcset = 0;		ee_cmd(ped, EECMD_MCSET|EECMD_I, ped->ed_mca, ped->ed_mcc);d29 1d31 3a33 2	if (pep == 0) {		signal(ped->ed_cmutex);d36 6a47 1	freebuf(pep);d51 1a51 1	ee_cmd(ped, EECMD_TX|EECMD_I);d58 1@1.1log@Initial revision@text@a19 1	unsigned int	csr;d24 5a28 1	if (ped->ed_xpending) {a31 1	ped->ed_xpending++;d34 1a34 1		ped->ed_xpending--;d43 1d47 1a47 1	freebuf(pep);a53 1	ee_cmd(ped, EECMD_TX|EECMD_I);@

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -