亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? ppp.c

?? 前段時間把lwip和ucos移植在44b0平臺上,用的是hfrk44b0開發板.已經調試通過,并且在板子上運行正常.
?? C
?? 第 1 頁 / 共 4 頁
字號:
    int mtu,    u32_t asyncmap,    int pcomp,     int accomp){    PPPControl *pc = &pppControl[unit];    int i;        pc->mtu = mtu;    pc->pcomp = pcomp;    pc->accomp = accomp;        /* Load the ACCM bits for the 32 control codes. */    for (i = 0; i < 32/8; i++)        pc->outACCM[i] = (u_char)((asyncmap >> (8 * i)) & 0xFF);    PPPDEBUG((LOG_INFO, "ppp_send_config[%d]: outACCM=%X %X %X %X\n",                unit,                pc->outACCM[0], pc->outACCM[1], pc->outACCM[2], pc->outACCM[3]));}/* * ppp_set_xaccm - set the extended transmit ACCM for the interface. */void ppp_set_xaccm(int unit, ext_accm *accm){    memcpy(pppControl[unit].outACCM, accm, sizeof(ext_accm));    PPPDEBUG((LOG_INFO, "ppp_set_xaccm[%d]: outACCM=%X %X %X %X\n",                unit,                pppControl[unit].outACCM[0],                pppControl[unit].outACCM[1],                pppControl[unit].outACCM[2],                pppControl[unit].outACCM[3]));}/* * ppp_recv_config - configure the receive-side characteristics of * the ppp interface. */void ppp_recv_config(    int unit,     int mru,    u32_t asyncmap,    int pcomp,     int accomp){    PPPControl *pc = &pppControl[unit];    int i;    	(void)accomp;	(void)pcomp;	(void)mru;    /* Load the ACCM bits for the 32 control codes. */    for (i = 0; i < 32 / 8; i++)        pc->inACCM[i] = (u_char)(asyncmap >> (i * 8));    PPPDEBUG((LOG_INFO, "ppp_recv_config[%d]: inACCM=%X %X %X %X\n",                unit,                pc->inACCM[0], pc->inACCM[1], pc->inACCM[2], pc->inACCM[3]));}#if 0/* * ccp_test - ask kernel whether a given compression method * is acceptable for use.  Returns 1 if the method and parameters * are OK, 0 if the method is known but the parameters are not OK * (e.g. code size should be reduced), or -1 if the method is unknown. */int ccp_test(    int unit,     int opt_len,     int for_transmit,    u_char *opt_ptr){    return 0;   /* XXX Currently no compression. */}/* * ccp_flags_set - inform kernel about the current state of CCP. */void ccp_flags_set(int unit, int isopen, int isup){    /* XXX */}/* * ccp_fatal_error - returns 1 if decompression was disabled as a * result of an error detected after decompression of a packet, * 0 otherwise.  This is necessary because of patent nonsense. */int ccp_fatal_error(int unit){    /* XXX */    return 0;}#endif/* * get_idle_time - return how long the link has been idle. */int get_idle_time(int u, struct ppp_idle *ip){       /* XXX */	(void)u;	(void)ip;    return 0;}/* * Return user specified netmask, modified by any mask we might determine * for address `addr' (in network byte order). * Here we scan through the system's list of interfaces, looking for * any non-point-to-point interfaces which might appear to be on the same * network as `addr'.  If we find any, we OR in their netmask to the * user-specified netmask. */u32_t GetMask(u32_t addr){    u32_t mask, nmask;        htonl(addr);    if (IN_CLASSA(addr))    /* determine network mask for address class */        nmask = IN_CLASSA_NET;    else if (IN_CLASSB(addr))        nmask = IN_CLASSB_NET;    else        nmask = IN_CLASSC_NET;    /* class D nets are disallowed by bad_ip_adrs */    mask = subnetMask | htonl(nmask);        /* XXX     * Scan through the system's network interfaces.     * Get each netmask and OR them into our mask.     */        return mask;}/* * sifvjcomp - config tcp header compression */int sifvjcomp(    int pd,     int vjcomp,     int cidcomp,     int maxcid){#if VJ_SUPPORT > 0    PPPControl *pc = &pppControl[pd];        pc->vjEnabled = vjcomp;    pc->vjComp.compressSlot = cidcomp;    pc->vjComp.maxSlotIndex = maxcid;    PPPDEBUG((LOG_INFO, "sifvjcomp: VJ compress enable=%d slot=%d max slot=%d\n",                vjcomp, cidcomp, maxcid));#endif    return 0;}/* * pppifNetifInit - netif init callback */static err_t pppifNetifInit(struct netif *netif){	netif->name[0] = 'p';	netif->name[1] = 'p';	netif->output = pppifOutput;	netif->mtu = pppMTU((int)netif->state);	return ERR_OK;}/* * sifup - Config the interface up and enable IP packets to pass. */int sifup(int pd){    PPPControl *pc = &pppControl[pd];    int st = 1;        if (pd < 0 || pd >= NUM_PPP || !pc->openFlag) {        st = 0;        PPPDEBUG((LOG_WARNING, "sifup[%d]: bad parms\n", pd));    } else {		netif_remove(&pc->netif);		if (netif_add(&pc->netif, &pc->addrs.our_ipaddr, &pc->addrs.netmask, &pc->addrs.his_ipaddr, (void *)pd, pppifNetifInit, ip_input)) {        		pc->if_up = 1;        		pc->errCode = PPPERR_NONE;			PPPDEBUG((LOG_DEBUG, "sifup: unit %d: linkStatusCB=%lx errCode=%d\n", pd, pc->linkStatusCB, pc->errCode));			if(pc->linkStatusCB)				pc->linkStatusCB(pc->linkStatusCtx, pc->errCode, &pc->addrs);		} else {        	st = 0;        	PPPDEBUG((LOG_ERR, "sifup[%d]: netif_add failed\n", pd));		}    }    return st;}/* * sifnpmode - Set the mode for handling packets for a given NP. */int sifnpmode(int u, int proto, enum NPmode mode){	(void)u;	(void)proto;	(void)mode;    return 0;}/* * sifdown - Config the interface down and disable IP. */int sifdown(int pd){    PPPControl *pc = &pppControl[pd];    int st = 1;        if (pd < 0 || pd >= NUM_PPP || !pc->openFlag) {        st = 0;        PPPDEBUG((LOG_WARNING, "sifdown[%d]: bad parms\n", pd));    } else {        pc->if_up = 0;	netif_remove(&pc->netif);	PPPDEBUG((LOG_DEBUG, "sifdown: unit %d: linkStatusCB=%lx errCode=%d\n", pd, pc->linkStatusCB, pc->errCode));	if(pc->linkStatusCB)		pc->linkStatusCB(pc->linkStatusCtx, PPPERR_CONNECT, NULL);	}    return st;}/* * sifaddr - Config the interface IP addresses and netmask. */int sifaddr(    int pd,             /* Interface unit ??? */    u32_t o,        /* Our IP address ??? */    u32_t h,        /* His IP address ??? */    u32_t m,        /* IP subnet mask ??? */    u32_t ns1,      /* Primary DNS */    u32_t ns2       /* Secondary DNS */){    PPPControl *pc = &pppControl[pd];    int st = 1;        if (pd < 0 || pd >= NUM_PPP || !pc->openFlag) {        st = 0;        PPPDEBUG((LOG_WARNING, "sifup[%d]: bad parms\n", pd));    } else {		memcpy(&pc->addrs.our_ipaddr, &o, sizeof(o));		memcpy(&pc->addrs.his_ipaddr, &h, sizeof(h));		memcpy(&pc->addrs.netmask, &m, sizeof(m));		memcpy(&pc->addrs.dns1, &ns1, sizeof(ns1));		memcpy(&pc->addrs.dns2, &ns2, sizeof(ns2));    }    return st;}/* * cifaddr - Clear the interface IP addresses, and delete routes * through the interface if possible. */int cifaddr(    int pd,         /* Interface unit ??? */    u32_t o,    /* Our IP address ??? */    u32_t h     /* IP broadcast address ??? */){    PPPControl *pc = &pppControl[pd];    int st = 1;    	(void)o;	(void)h;    if (pd < 0 || pd >= NUM_PPP || !pc->openFlag) {        st = 0;        PPPDEBUG((LOG_WARNING, "sifup[%d]: bad parms\n", pd));    } else {		IP4_ADDR(&pc->addrs.our_ipaddr, 0,0,0,0);		IP4_ADDR(&pc->addrs.his_ipaddr, 0,0,0,0);		IP4_ADDR(&pc->addrs.netmask, 255,255,255,0);		IP4_ADDR(&pc->addrs.dns1, 0,0,0,0);		IP4_ADDR(&pc->addrs.dns2, 0,0,0,0);    }    return st;}/* * sifdefaultroute - assign a default route through the address given. */int sifdefaultroute(int pd, u32_t l, u32_t g){    PPPControl *pc = &pppControl[pd];    int st = 1;    	(void)l;	(void)g;    if (pd < 0 || pd >= NUM_PPP || !pc->openFlag) {        st = 0;        PPPDEBUG((LOG_WARNING, "sifup[%d]: bad parms\n", pd));    } else {		netif_set_default(&pc->netif);    }    /* TODO: check how PPP handled the netMask, previously not set by ipSetDefault */    return st;}/* * cifdefaultroute - delete a default route through the address given. */int cifdefaultroute(int pd, u32_t l, u32_t g){    PPPControl *pc = &pppControl[pd];    int st = 1;    	(void)l;	(void)g;    if (pd < 0 || pd >= NUM_PPP || !pc->openFlag) {        st = 0;        PPPDEBUG((LOG_WARNING, "sifup[%d]: bad parms\n", pd));    } else {		netif_set_default(NULL);    }    return st;}voidpppMainWakeup(int pd){	PPPDEBUG((LOG_DEBUG, "pppMainWakeup: unit %d\n", pd));	sio_read_abort(pppControl[pd].fd);}/* these callbacks are necessary because lcp_* functions   must be called in the same context as pppInput(),   namely the tcpip_thread(), essentially because   they manipulate timeouts which are thread-private*/static voidpppStartCB(void *arg){    int pd = (int)arg;	PPPDEBUG((LOG_DEBUG, "pppStartCB: unit %d\n", pd));    lcp_lowerup(pd);    lcp_open(pd);      /* Start protocol */}static voidpppStopCB(void *arg){    int pd = (int)arg;	PPPDEBUG((LOG_DEBUG, "pppStopCB: unit %d\n", pd));    lcp_close(pd, "User request");}static voidpppHupCB(void *arg){    int pd = (int)arg;	PPPDEBUG((LOG_DEBUG, "pppHupCB: unit %d\n", pd));    lcp_lowerdown(pd);    link_terminated(pd);}/**********************************//*** LOCAL FUNCTION DEFINITIONS ***//**********************************//* The main PPP process function.  This implements the state machine according * to section 4 of RFC 1661: The Point-To-Point Protocol. */static void pppMain(void *arg){    int pd = (int)arg;    struct pbuf *p;    PPPControl* pc;    pc = &pppControl[pd];    p = pbuf_alloc(PBUF_RAW, PPP_MRU+PPP_HDRLEN, PBUF_RAM);    if(!p) {		LWIP_ASSERT("p != NULL", p);		pc->errCode = PPPERR_ALLOC;		goto out;    }    /*     * Start the connection and handle incoming events (packet or timeout).     */	PPPDEBUG((LOG_INFO, "pppMain: unit %d: Connecting\n", pd));    tcpip_callback(pppStartCB, arg);    while (lcp_phase[pd] != PHASE_DEAD) {

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品一二三四五| 亚洲高清中文字幕| 有坂深雪av一区二区精品| 亚洲一区二区三区中文字幕| 日韩精品国产欧美| 午夜精品视频一区| 国产91在线观看| 欧美美女黄视频| 中文字幕乱码一区二区免费| 亚洲成年人影院| 盗摄精品av一区二区三区| 欧美图片一区二区三区| 久久久久国色av免费看影院| 亚洲综合色区另类av| 成人免费视频免费观看| 日韩一级精品视频在线观看| 国产精品国产三级国产有无不卡| 日精品一区二区| 色婷婷久久综合| 视频在线观看一区二区三区| 麻豆精品精品国产自在97香蕉| 欧美日韩在线播| 奇米影视一区二区三区小说| 国产亚洲短视频| 天堂va蜜桃一区二区三区| 欧美一级精品在线| 国产精品一区二区无线| 国产精品久久久久永久免费观看 | 亚洲综合激情另类小说区| 色婷婷狠狠综合| 日韩黄色片在线观看| 精品成人一区二区三区四区| 免费成人av资源网| a4yy欧美一区二区三区| 成人免费毛片嘿嘿连载视频| 亚洲欧美日韩在线播放| 秋霞av亚洲一区二区三| 欧美日韩一区二区三区免费看| 日韩欧美国产一二三区| 亚洲人成网站色在线观看| 懂色av一区二区三区蜜臀 | 欧美卡1卡2卡| 极品少妇xxxx精品少妇偷拍| 樱桃视频在线观看一区| 久久综合九色综合97婷婷女人 | 色婷婷激情久久| 精品一区二区三区蜜桃| 亚洲一区二区三区中文字幕 | 日韩一区二区三免费高清| 91麻豆蜜桃一区二区三区| 国产一区二区视频在线| 日韩精品久久久久久| 亚洲天堂av一区| 国产视频一区在线播放| 日韩一区二区影院| 欧美视频一区在线| 裸体在线国模精品偷拍| 337p亚洲精品色噜噜噜| 日本三级亚洲精品| 欧美国产日本韩| 在线精品视频一区二区| 极品少妇xxxx精品少妇| 中文字幕乱码亚洲精品一区| 91亚洲精品久久久蜜桃网站| 亚洲国产欧美一区二区三区丁香婷| 91久久久免费一区二区| 老司机午夜精品| 国产精品丝袜久久久久久app| 色哟哟日韩精品| 久久精品国产精品亚洲精品| 亚洲猫色日本管| 欧美最猛性xxxxx直播| 亚洲综合一区二区精品导航| 欧美午夜在线一二页| 高清在线不卡av| 美女视频一区二区| 日韩欧美在线1卡| 麻豆91精品视频| 国产偷国产偷精品高清尤物 | 欧美videossexotv100| 国产麻豆精品theporn| 国产精品久久福利| 国产精品视频一二三区| 国产午夜亚洲精品理论片色戒| 久久一区二区视频| 国产色产综合产在线视频| 久久久精品欧美丰满| 国产一区二区三区免费观看 | 色综合久久综合网97色综合| 91蜜桃在线观看| 成人av资源下载| 91在线视频播放地址| 不卡的电视剧免费网站有什么| 97精品视频在线观看自产线路二| 91麻豆免费看片| 欧美专区日韩专区| 日韩女同互慰一区二区| 亚洲日穴在线视频| 久久久久亚洲蜜桃| 亚洲国产精品久久艾草纯爱| 欧美一区二区三区免费| 精品久久久久久久久久久久包黑料 | 精品日本一线二线三线不卡| 久久亚洲综合色一区二区三区| 国产偷国产偷精品高清尤物 | 国产精品剧情在线亚洲| 亚洲免费观看高清| 天堂一区二区在线免费观看| 狠狠色丁香久久婷婷综合丁香| 99麻豆久久久国产精品免费优播| 欧美手机在线视频| 精品国产免费一区二区三区香蕉| 久久久久国产成人精品亚洲午夜| 中文字幕乱码亚洲精品一区| 亚洲一区二区三区四区在线| 麻豆久久久久久| 色综合一区二区三区| 日韩一区二区中文字幕| 中文字幕在线一区免费| 偷拍一区二区三区四区| 国产精品88888| 欧美三级一区二区| 国产亚洲成年网址在线观看| 亚洲成人av资源| 国产成人av影院| 欧美日韩国产高清一区二区三区| 久久精品亚洲精品国产欧美kt∨| 亚洲乱码精品一二三四区日韩在线| 美女国产一区二区三区| 91色|porny| 久久蜜桃av一区二区天堂| 亚洲午夜久久久久久久久电影网| 国产成人免费在线观看不卡| 欧美中文字幕一二三区视频| 久久蜜桃av一区精品变态类天堂| 亚洲成av人片观看| 97国产一区二区| 久久亚洲一区二区三区明星换脸| 亚洲福利一二三区| 91蝌蚪porny| 国产日韩欧美不卡| 玖玖九九国产精品| 欧美三级电影网| 自拍偷拍亚洲欧美日韩| 国产激情视频一区二区三区欧美 | 91免费视频网| 国产午夜亚洲精品午夜鲁丝片 | 日韩一区二区电影| 亚洲小说欧美激情另类| 一本到一区二区三区| 中文字幕精品一区二区三区精品| 奇米亚洲午夜久久精品| 337p亚洲精品色噜噜噜| 亚洲午夜电影在线| 91欧美激情一区二区三区成人| 亚洲国产高清在线| 国产成人99久久亚洲综合精品| 精品乱码亚洲一区二区不卡| 日韩高清在线观看| 欧美精品第1页| 欧美三级蜜桃2在线观看| 亚洲日本韩国一区| 91福利小视频| 日本不卡在线视频| 中文字幕国产一区| 欧美手机在线视频| 国产精品一二三四| 亚洲综合免费观看高清完整版在线| 久久se这里有精品| 亚洲精品乱码久久久久久日本蜜臀| 在线精品国精品国产尤物884a| 五月婷婷色综合| 中文字幕乱码久久午夜不卡| 欧美日韩一级视频| 成人午夜精品在线| 日韩av一区二区三区四区| 国产人妖乱国产精品人妖| 欧美在线色视频| www.亚洲色图| 精品一区二区三区av| 中文字幕亚洲电影| 一区二区三区四区国产精品| 国产欧美视频一区二区| 自拍偷在线精品自拍偷无码专区| 自拍偷在线精品自拍偷无码专区 | 亚洲男同性视频| 欧美一区二区精品久久911| 99re6这里只有精品视频在线观看| 95精品视频在线| 亚洲欧美电影院| 成人av先锋影音| 日韩成人免费在线| 日韩欧美国产不卡| 成人在线视频一区二区| 一区二区三区四区精品在线视频| 欧美性猛交xxxx黑人交| 午夜精品123| xnxx国产精品| 国产成人在线视频播放| 亚洲男人的天堂一区二区|