Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/Makefile.tinet
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/Makefile.tinet	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/Makefile.tinet	(revision 364)
@@ -93,4 +93,5 @@
                in_subr.o route_cfg.o
 TINET_CFG_COBJS := $(TINET_CFG_COBJS) tinet_cfg.o
+TINET_CFG2_OUT_SRCS := $(TINET_CFG2_OUT_SRCS) tinet_cfg.h tinet_cfg.c
 
 #  IPv6
@@ -328,4 +329,5 @@
 
 	CFG_COBJS := $(CFG_COBJS) $(TINET_CFG_COBJS)
+	CFG2_OUT_SRCS := $(CFG2_OUT_SRCS) $(TINET_CFG2_OUT_SRCS)
 
 	CLEAN_FILES := $(CLEAN_FILES) $(TINET_CFG_OUT) $(MAKE_TINET_LIB)
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/net/ethernet.h
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/net/ethernet.h	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/net/ethernet.h	(revision 364)
@@ -98,10 +98,12 @@
 #endif	/* of #ifndef IF_ETHER_NIC_HDR_ALIGN */
 
-#if defined(__RX) || defined(_MSC_VER)
 #if defined(__RX)
 #pragma pack
-#else
+#elif defined(_MSC_VER)
 #pragma pack(push, 1)
 #endif
+
+#if defined(__RX) || defined(_MSC_VER)
+
 typedef struct t_ether_header {
 
@@ -116,9 +118,4 @@
 	uint16_t	type;
 	} T_ETHER_HDR;
-#if defined(__RX)
-#pragma packoption
-#else
-#pragma pack(pop)
-#endif
 
 #elif defined(TOPPERS_S810_CLG3_85)	/* of #if defined(__RX) */
@@ -166,4 +163,10 @@
 	uint8_t		lladdr[ETHER_ADDR_LEN];
 	} __attribute__((packed, aligned(2))) T_ETHER_ADDR;
+
+#if defined(__RX)
+#pragma packoption
+#elif defined(_MSC_VER)
+#pragma pack(pop)
+#endif
 
 /*
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/net/net_asp.cfg
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/net/net_asp.cfg	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/net/net_asp.cfg	(revision 364)
@@ -41,4 +41,6 @@
 
 INCLUDE("net/net.cfg");
+
+#ifndef NOUSE_MPF_NET_BUF
 
 /*
@@ -169,2 +171,4 @@
 		});
 #endif	/* of #if defined(NUM_MPF_NET_BUF6_65536) && NUM_MPF_NET_BUF6_65536 > 0 */
+
+#endif
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/net/net_buf.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/net/net_buf.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/net/net_buf.c	(revision 364)
@@ -68,4 +68,6 @@
 #include <netinet/tcp_var.h>
 
+#ifndef NOUSE_MPF_NET_BUF
+
 /*
  *  関数
@@ -226,5 +228,21 @@
 #endif	/* of #if defined(NUM_MPF_NET_BUF_128) && NUM_MPF_NET_BUF_128 > 0 */
 
-#if defined(_IP4_CFG)
+#if defined(_IP6_CFG)
+
+#if defined(NUM_MPF_NET_BUF_CSEG) && NUM_MPF_NET_BUF_CSEG > 0
+	{
+		MPF_NET_BUF_CSEG,
+		IF_HDR_SIZE + IP_HDR_SIZE + TCP_HDR_SIZE,
+
+#if NET_COUNT_ENABLE & PROTO_FLG_NET_BUF
+
+		NUM_MPF_NET_BUF_CSEG,
+
+#endif	/* of #if NET_COUNT_ENABLE & PROTO_FLG_NET_BUF */
+
+		},
+#endif	/* of #if defined(NUM_MPF_NET_BUF_CSEG) && NUM_MPF_NET_BUF_CSEG > 0 */
+
+#endif	/* of #if defined(_IP6_CFG) */
 
 #if defined(NUM_MPF_NET_BUF_64) && NUM_MPF_NET_BUF_64 > 0
@@ -242,5 +260,5 @@
 #endif	/* of #if defined(NUM_MPF_NET_BUF_64) && NUM_MPF_NET_BUF_64 > 0 */
 
-#endif	/* of #if defined(_IP4_CFG) */
+#if defined(_IP4_CFG) && !defined(_IP6_CFG)
 
 #if defined(NUM_MPF_NET_BUF_CSEG) && NUM_MPF_NET_BUF_CSEG > 0
@@ -257,4 +275,6 @@
 		},
 #endif	/* of #if defined(NUM_MPF_NET_BUF_CSEG) && NUM_MPF_NET_BUF_CSEG > 0 */
+
+#endif	/* of #if defined(_IP4_CFG) && !defined(_IP6_CFG) */
 
 	};
@@ -307,5 +327,5 @@
 
 	while (1) {
-		if ((error = tget_mpf((ID)net_buf_table[ix].index, (void*)buf, ix == 0 ? tmout : TMO_POL)) == E_OK) {
+		if ((error = tget_mpf((ID)net_buf_table[ix].index, (void **)buf, ix == 0 ? tmout : TMO_POL)) == E_OK) {
 			(*buf)->idix  = (uint8_t)ix;
 			(*buf)->len   = (uint16_t)minlen;
@@ -320,7 +340,7 @@
 			return error;
 			}
-		else if (ix == 0 || net_buf_table[ix].size > maxlen)
+		ix --;
+		if (ix < 0 || net_buf_table[ix].size > maxlen)
 			break;
-		ix --;
 		}
 
@@ -351,5 +371,5 @@
 
 	while (1) {
-		if ((error = tget_mpf((ID)net_buf_table[ix].index, (void*)buf,
+		if ((error = tget_mpf((ID)net_buf_table[ix].index, (void **)buf,
 		                      ix == sizeof(net_buf_table) / sizeof(T_NET_BUF_ENTRY) - 1 ? tmout : TMO_POL)) == E_OK) {
 			(*buf)->idix  = (uint8_t)ix;
@@ -359,4 +379,5 @@
 			(*buf)->conn_pos = 0;
 #endif
+
 #if NET_COUNT_ENABLE & PROTO_FLG_NET_BUF
 			NET_COUNT_NET_BUF(net_buf_table[ix].allocs, 1);
@@ -454,9 +475,10 @@
 		/* 固定メモリプールに返す。*/
 
-#if NET_COUNT_ENABLE & PROTO_FLG_NET_BUF
-		net_buf_table[buf->idix].busies --;
-#endif
-		if ((error = rel_mpf((ID)net_buf_table[buf->idix].index, buf)) != E_OK) {
-			syslog(LOG_WARNING, "[NET BUF] %s, ID=%d.", itron_strerror(error), buf->idix);
+		int idix = buf->idix;
+#if NET_COUNT_ENABLE & PROTO_FLG_NET_BUF
+		net_buf_table[idix].busies --;
+#endif
+		if ((error = rel_mpf((ID)net_buf_table[idix].index, buf)) != E_OK) {
+			syslog(LOG_WARNING, "[NET BUF] %s, ID=%d.", itron_strerror(error), idix);
 			}
 		}
@@ -509,2 +531,63 @@
 	return (uint_t)net_buf_table[0].size;
 	}
+
+#else
+#include <stdlib.h>
+
+/*
+ *  tget_net_buf_ex -- ネットワークバッファを獲得する（拡張機能）。
+ */
+
+ER
+tget_net_buf_ex (T_NET_BUF **buf, uint_t minlen, uint_t maxlen, ATR nbatr, TMO tmout)
+{
+	uint_t len = (minlen > maxlen) ? minlen : maxlen;
+	*buf = (T_NET_BUF *)malloc(sizeof(T_NET_BUF) - sizeof(((T_NET_BUF *)0)->buf) + len);
+	if (*buf == NULL)
+		return E_NOMEM;
+
+	(*buf)->idix = 0;
+	(*buf)->len = (uint16_t)len;
+	(*buf)->flags = 0;
+#ifdef IF_ETHER_MULTI_NIC
+	(*buf)->conn_pos = 0;
+#endif
+
+	return E_OK;
+	}
+
+/*
+ *  tget_net_buf -- ネットワークバッファを獲得する（互換）。
+ */
+
+ER
+tget_net_buf (T_NET_BUF **buf, uint_t len, TMO tmout)
+{
+	return tget_net_buf_ex(buf, len, len, NBA_SEARCH_ASCENT, tmout);
+	}
+
+
+/*
+ * rel_net_buf -- ネットワークバッファを返却する。
+ */
+
+ER
+rel_net_buf (T_NET_BUF *buf)
+{
+	free(buf);
+
+	return E_OK;
+	}
+
+
+/*
+ * net_buf_max_siz -- ネットワークバッファの最大サイズを返す。
+ */
+
+uint_t
+net_buf_max_siz (void)
+{
+	return (uint_t)IF_PDU_SIZE;
+	}
+
+#endif
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netapp/dbg_cons.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netapp/dbg_cons.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netapp/dbg_cons.c	(revision 364)
@@ -666,5 +666,5 @@
 	            "IX Expire State      MAC Address       IP Address\n");
 
-	/* expire の単位は [ms]。*/
+	/* expire の単位は [us]。*/
 	get_tim(&now);
 	cache = nd6_get_cache();
@@ -705,5 +705,5 @@
 	            "IX Expire MAC Address       IP Address\n");
 
-	/* expire の単位は [ms]。*/
+	/* expire の単位は [us]。*/
 	cache = arp_get_cache();
 	for (ix = 0; ix < NUM_ARP_ENTRY; ix ++) {
@@ -753,5 +753,5 @@
 	WAI_NET_CONS_PRINTF();
 	get_tim(&now);
-	cons_printf(portid, "ネットワーク統計情報\t経過時間[ms]\t%lu\t", now);
+	cons_printf(portid, "ネットワーク統計情報\t経過時間[us]\t%lu\t", now);
 	if (now > (1000 * 3600 * 24))
 		cons_printf(portid, "%3lu日 %2lu時間 %2lu分 %2lu秒\n",
@@ -938,5 +938,5 @@
 		}
 
-	cons_printf(portid, "\nネットワーク統計情報\t経過時間[ms]\t%lu\t", now);
+	cons_printf(portid, "\nネットワーク統計情報\t経過時間[us]\t%lu\t", now);
 	if (now > (1000 * 3600 * 24))
 		cons_printf(portid, "%3lu日 %2lu時間 %2lu分 %2lu秒\n",
@@ -1065,5 +1065,5 @@
 	WAI_NET_CONS_PRINTF();
 	get_tim(&now);
-	cons_printf(portid, "ネットワークバッファ情報\t経過時間[ms]\t%u\n", now);
+	cons_printf(portid, "ネットワークバッファ情報\t経過時間[us]\t%u\n", now);
 
 #if NET_COUNT_ENABLE
@@ -1577,5 +1577,5 @@
 	cons_printf(portid, " IP Address\n");
 
-	/* expire の単位は [ms]。*/
+	/* expire の単位は [us]。*/
 	get_tim(&now);
 	dr = nd6_get_drl(&count);
@@ -2298,6 +2298,6 @@
 
 	cons_printf(portid, "ND:\n");
-	cons_printf(portid, "  TMO_ND6_RTR_SOL_DELAY:    %5d[ms]\n", TMO_ND6_RTR_SOL_DELAY);
-	cons_printf(portid, "  TMO_ND6_RTR_SOL_INTERVAL: %5d[ms]\n", TMO_ND6_RTR_SOL_INTERVAL);
+	cons_printf(portid, "  TMO_ND6_RTR_SOL_DELAY:    %5d[us]\n", TMO_ND6_RTR_SOL_DELAY);
+	cons_printf(portid, "  TMO_ND6_RTR_SOL_INTERVAL: %5d[us]\n", TMO_ND6_RTR_SOL_INTERVAL);
 	cons_printf(portid, "  NUM_IP6_DAD_COUNT:        %5d\n",     NUM_IP6_DAD_COUNT);
 	cons_printf(portid, "  NUM_ND6_CACHE_ENTRY:      %5d\n",     NUM_ND6_CACHE_ENTRY);
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netapp/dhcp4_cli.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netapp/dhcp4_cli.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netapp/dhcp4_cli.c	(revision 364)
@@ -2031,6 +2031,8 @@
 
 			/* 休止する。*/
-			if (error == E_OK)
-				syslog(LOG_NOTICE, "[DHCP4C] lease released, go to sleep.");
+			if (error == E_OK) {
+				if (ct->fsm != DHCP4_FSM_SLEEP)
+					syslog(LOG_NOTICE, "[DHCP4C] lease released, go to sleep.");
+			}
 			else {
 				syslog(LOG_NOTICE, "[DHCP4C] server not available, go to sleep, error: %s.", itron_strerror(error));
@@ -2158,6 +2160,8 @@
 
 			/* 休止する。*/
-			if (ct->error == E_OK)
-				syslog(LOG_NOTICE, "[DHCP4C] lease released, go to sleep.");
+			if (ct->error == E_OK) {
+				if (ct->fsm != DHCP4_FSM_SLEEP)
+					syslog(LOG_NOTICE, "[DHCP4C] lease released, go to sleep.");
+			}
 			else {
 				syslog(LOG_NOTICE, "[DHCP4C] server not available, go to sleep, error: %s.", itron_strerror(ct->error));
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netapp/wwws.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netapp/wwws.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netapp/wwws.c	(revision 364)
@@ -708,5 +708,5 @@
 	len += put_str(cepid, srbuf, response);
 	get_tim(&finish);
-	syslog(LOG_NOTICE, "[WWWn:%02u SND] send: index.html, len: %4u, time: %lu [ms]",
+	syslog(LOG_NOTICE, "[WWWn:%02u SND] send: index.html, len: %4u, time: %lu [us]",
 	                   cepid, len, (finish - start) * 1000 / SYSTIM_HZ);
 	return E_OK;
@@ -1609,5 +1609,5 @@
 
 	get_tim(&finish);
-	syslog(LOG_NOTICE, "[WWWn:%02u SND]send: stat.html,  len: %4u, time: %lu [ms]",
+	syslog(LOG_NOTICE, "[WWWn:%02u SND]send: stat.html,  len: %4u, time: %lu [us]",
 	                   cepid, len, (finish - start) * 1000 / SYSTIM_HZ);
 	return E_OK;
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/icmp6.h
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/icmp6.h	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/icmp6.h	(revision 364)
@@ -291,6 +291,6 @@
 typedef struct t_router_advert_hdr {
 	T_ICMP6_HDR	hdr;
-	uint32_t	reachable;		/* [ms] 到達可能時間	*/
-	uint32_t	retransmit;		/* [ms] 近隣要請送信間隔	*/
+	uint32_t	reachable;		/* [us] 到達可能時間	*/
+	uint32_t	retransmit;		/* [us] 近隣要請送信間隔	*/
 	/* この後にオプションが続く */
 	} __attribute__((packed, aligned(2))) T_ROUTER_ADVERT_HDR;
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/in4_subr.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/in4_subr.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/in4_subr.c	(revision 364)
@@ -287,6 +287,9 @@
 
 	/* IP ヘッダを設定する。*/
-	if ((error = in4_set_header(*nbuf, len, dstaddr, srcaddr, proto, ttl)) != E_OK)
+	if ((error = in4_set_header(*nbuf, len, dstaddr, srcaddr, proto, ttl)) != E_OK) {
+		syscall(rel_net_buf(*nbuf));
+		*nbuf = NULL;
 		return error;
+		}
 
 	/* 4 オクテット境界までパディングで埋める。*/
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/in_itron.h
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/in_itron.h	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/in_itron.h	(revision 364)
@@ -62,5 +62,5 @@
 #define TFN_TCP_ALL		(0)
 
-#define TEV_TCP_RCV_OOB		(-0x201)
+#define TEV_TCP_RCV_OOB		(0x201)
 
 /* UDP 関係 */
@@ -75,5 +75,5 @@
 #define TFN_UDP_ALL		(0)
 
-#define TEV_UDP_RCV_DAT		(-0x221)
+#define TEV_UDP_RCV_DAT		(0x221)
 
 /* 一般 */
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/tcp_input.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/tcp_input.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/tcp_input.c	(revision 364)
@@ -1364,4 +1364,8 @@
 	NTOHS(tcph->dport);
 
+	/* SDU 長 より 緊急ポインタが大きい場合 */
+	if (tcph->urp > tcph->sum)
+		goto drop;
+
 find_cep:
 
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/tcp_output.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/tcp_output.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/tcp_output.c	(revision 364)
@@ -369,6 +369,8 @@
 		tcph->flags |= TCP_FLG_URG;
 		}
-	else
+	else {
+		tcph->urp = 0;
 		cep->snd_up  = cep->snd_una;
+		}
 
 #endif	/* of #ifdef TCP_CFG_EXTENTIONS */
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/tcp_usrreq.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/tcp_usrreq.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/tcp_usrreq.c	(revision 364)
@@ -897,5 +897,5 @@
 
 	/* tcp_rcv_buf の割当て長をリセットする。*/
-	cep->rcv_buf_len = 0;
+	cep->rcv_buf_len -= len;
 
 	/* 通信端点のロックを解除する。*/
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udp_var.h
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udp_var.h	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udp_var.h	(revision 364)
@@ -101,4 +101,14 @@
 typedef ER	(*t_udp_callback)(ID cepid, FN fncd, void *p_parblk);
 
+typedef struct t_udp_rcv_dat_para {
+	uint_t		len;
+	T_NET_BUF	*input;
+	uint_t		off;
+	union {
+		T_IPV4EP rep4;
+		T_IPV6EP rep6;
+	};
+	} T_UDP_RCV_DAT_PARA;
+
 /*
  *  UDP 通信端点
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udpn_input.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udpn_input.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udpn_input.c	(revision 364)
@@ -75,8 +75,8 @@
 {
 	T_UDP_HDR	*udph;
-	uint_t		len;
+	T_UDP_RCV_DAT_PARA para;
 
 	udph = (T_UDP_HDR *)(input->buf + off);
-	len  = (uint_t)(ntohs(udph->ulen) - UDP_HDR_SIZE);
+	para.len  = (uint_t)(ntohs(udph->ulen) - UDP_HDR_SIZE);
 
 	if (cep->rcv_tskid != TA_NULL) {	/* 非ノンブロッキングコールでペンディング中 */
@@ -98,5 +98,5 @@
 		/* データをバッファに移す。*/
 		memcpy(cep->rcv_data, GET_UDP_SDU(input, off),
-		       (size_t)(len < cep->rcv_len ? len : cep->rcv_len));
+		       (size_t)(para.len < cep->rcv_len ? para.len : cep->rcv_len));
 		syscall(rel_net_buf(input));
 
@@ -104,7 +104,7 @@
 
 #ifdef TCP_CFG_NON_BLOCKING_COMPAT14
-			(*cep->callback)(GET_UDP_CEPID(cep), TFN_UDP_RCV_DAT, (void*)(uint32_t)len);
+			(*cep->callback)(GET_UDP_CEPID(cep), TFN_UDP_RCV_DAT, (void*)(uint32_t)para.len);
 #else
-			(*cep->callback)(GET_UDP_CEPID(cep), TFN_UDP_RCV_DAT, (void*)&len);
+			(*cep->callback)(GET_UDP_CEPID(cep), TFN_UDP_RCV_DAT, (void*)&para.len);
 #endif
 		else
@@ -121,7 +121,16 @@
 
 #ifdef TCP_CFG_NON_BLOCKING_COMPAT14
-		(*cep->callback)(GET_UDP_CEPID(cep), TEV_UDP_RCV_DAT, (void*)(uint32_t)len);
+		(*cep->callback)(GET_UDP_CEPID(cep), TEV_UDP_RCV_DAT, (void*)(uint32_t)para.len);
 #else
-		(*cep->callback)(GET_UDP_CEPID(cep), TEV_UDP_RCV_DAT, (void*)&len);
+		para.input = input;
+		para.off = off;
+#if API_PROTO == API_PROTO_IPV4
+		para.rep4.portno = ntohs(udph->sport);
+		IN_COPY_TO_HOST(&para.rep4.ipaddr, input);
+#else
+		para.rep6.portno = ntohs(udph->sport);
+		IN_COPY_TO_HOST(&para.rep6.ipaddr, input);
+#endif
+		(*cep->callback)(GET_UDP_CEPID(cep), TEV_UDP_RCV_DAT, (void*)&para.len);
 #endif
 		/*
@@ -129,6 +138,9 @@
 		 *  データを読み出さなかったことになるので、捨てる。
 		 */
-		if (cep->cb_netbuf != NULL)
-			syscall(rel_net_buf(cep->cb_netbuf));
+		if (cep->cb_netbuf != NULL) {
+			if ((input->flags & NB_FLG_NOREL_IFOUT) == 0)
+				syscall(rel_net_buf(cep->cb_netbuf));
+			cep->cb_netbuf = NULL;
+			}
 		}
 	else {
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udpn_usrreq.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udpn_usrreq.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udpn_usrreq.c	(revision 364)
@@ -411,6 +411,5 @@
 		return E_NOEXS;
 #if defined(SUPPORT_INET6)
-#endif
-#if defined(SUPPORT_INET4) && defined(SUPPORT_IGMP) && TNUM_UDP4_CEPID > 0
+#elif defined(SUPPORT_INET4) && defined(SUPPORT_IGMP) && TNUM_UDP4_CEPID > 0
 	switch (optname) {
 	case IP_MULTICAST_LOOP:
@@ -488,6 +487,5 @@
 		return E_NOEXS;
 #if defined(SUPPORT_INET6)
-#endif
-#if defined(SUPPORT_INET4) && defined(SUPPORT_IGMP) && TNUM_UDP4_CEPID > 0
+#elif defined(SUPPORT_INET4) && defined(SUPPORT_IGMP) && TNUM_UDP4_CEPID > 0
 	switch (optname) {
 	case IP_MULTICAST_LOOP:
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udpn_usrreq_nblk.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udpn_usrreq_nblk.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet/udpn_usrreq_nblk.c	(revision 364)
@@ -122,7 +122,7 @@
 
 #ifdef TCP_CFG_NON_BLOCKING_COMPAT14
-			(*cep->callback)(GET_UDP_CEPID(cep), TFN_UDP_RCV_DAT, (void*)error);
+			(*cep->callback)(GET_UDP_CEPID(cep), TFN_UDP_CAN_CEP, (void*)error);
 #else
-			(*cep->callback)(GET_UDP_CEPID(cep), TFN_UDP_RCV_DAT, (void*)&error);
+			(*cep->callback)(GET_UDP_CEPID(cep), TFN_UDP_CAN_CEP, (void*)&error);
 #endif
 		else
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/in6_subr.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/in6_subr.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/in6_subr.c	(revision 364)
@@ -369,6 +369,9 @@
 
 	/* IPv6 ヘッダを設定する。*/
-	if ((error = in6_set_header(*nbuf, len, dstaddr, srcaddr, next, hlim)) != E_OK)
+	if ((error = in6_set_header(*nbuf, len, dstaddr, srcaddr, next, hlim)) != E_OK) {
+		syscall(rel_net_buf(*nbuf));
+		*nbuf = NULL;
 		return error;
+		}
 
 	/* 4 オクテット境界までパディングで埋める。*/
@@ -662,5 +665,5 @@
  *  in6_rtredirect -- ルーティング表にエントリを登録する。
  *
- *    注意: 引数 tmo の単位は [ms]。
+ *    注意: 引数 tmo の単位は [us]。
  */
 
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/in6_var.h
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/in6_var.h	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/in6_var.h	(revision 364)
@@ -184,6 +184,6 @@
 	 * vltime と pltime は、追加/変更してからの相対時間
 	 */
-	uint32_t	vltime;		/* 有効時間 [ms]			*/
-	uint32_t	pltime;		/* 推奨有効時間 [ms]		*/
+	uint32_t	vltime;		/* 有効時間 [us]			*/
+	uint32_t	pltime;		/* 推奨有効時間 [us]		*/
 	} __attribute__((packed, aligned(2)))T_IN6_ADDR_LIFETIME;
 
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/nd6.c
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/nd6.c	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/nd6.c	(revision 364)
@@ -353,4 +353,5 @@
 			if (nd6_cache[mix].hold != NULL) {
 				syscall(rel_net_buf(nd6_cache[mix].hold));
+				nd6_cache[mix].hold = NULL;
 				}
 			fix = mix;
@@ -562,4 +563,5 @@
 			if (ln->hold != NULL) {
 				syscall(rel_net_buf(ln->hold));
+				ln->hold = NULL;
 				}
 
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/nd6.h
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/nd6.h	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/netinet6/nd6.h	(revision 364)
@@ -81,5 +81,5 @@
 	T_NET_BUF	*hold;
 	TMO		tmout;
-	SYSTIM		expire;		/* [ms] 有効時間が切れる時刻	*/
+	SYSTIM		expire;		/* [us] 有効時間が切れる時刻	*/
 	T_IF_ADDR	ifaddr;
 	uint8_t		state;
@@ -183,6 +183,6 @@
 typedef struct t_def_router {
 	T_IN6_ADDR	addr;
-	SYSTIM		expire;		/* [ms] 有効時間が切れる時刻	*/
-	uint32_t	lifetime;	/* [ms] 有効時間			*/
+	SYSTIM		expire;		/* [us] 有効時間が切れる時刻	*/
+	uint32_t	lifetime;	/* [us] 有効時間			*/
 	uint16_t	plistmap;	/* プレフィックスマップ		*/
 	uint8_t		flags;		/* ルータ通知のフラグ		*/
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/tcpip_sym.def
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/tcpip_sym.def	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/tcpip_sym.def	(revision 364)
@@ -15,4 +15,5 @@
 TMO_UDP_OUTPUT
 TMO_ICMP_OUTPUT
+TMO_IGMP_OUTPUT
 TMO_ND6_NS_OUTPUT
 TMO_ND6_NA_OUTPUT
Index: asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/tinet_asp.cfg
===================================================================
--- asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/tinet_asp.cfg	(revision 352)
+++ asp3_tinet_ecnl_arm/trunk/asp3_dcre/tinet/tinet_asp.cfg	(revision 364)
@@ -73,4 +73,5 @@
 INCLUDE("netinet/if_ether.cfg");
 INCLUDE("netinet/ip.cfg");
+INCLUDE("netinet/ip_igmp.cfg");
 INCLUDE("netinet/tcp.cfg");
 INCLUDE("netinet/udp.cfg");
