經濟部中央揉準局貝工消費合作社印聚 A7 B7___ 五、發明説明 發明背景: (本發明係一種能自動檢査及過減IP ( Internet Protocol,以下簡稱IP)封包且直接啓動回應程序之網路介 面卡結構及其方法,尤指一種在一般網路介面卡上加設自 動檢査IP封包及ARP ( Address Reso丨ution Protocal ’ 以下 簡稱ARP)封包之功能,以在本發明之網路介面卡發現甩 接收之該等封包係屬要求封包時,可直接啓動ARP或PING 之自動回應程序,發送回應訊息,且可直接由該網路介面 卡過瀘逾時、錯誤或IP位址不符之封包,並予以丟棄,而 不致因該等封包對電腦之中央處理器產生中斷,故可有效 提高電腦之中央處理器(即CPU)及網路系統之處理效能。 先前技藝: 按,一般乙太網路封包之框架結構,如第1圓所示,其 前8個位元組爲前文(preamble)與框架起始欄(SFD),接 著12個位元組爲目的位址與起始位址禰位,再接著爲2個位 元組之資料型態或長度檷位,其後爲資料區段與資訊段榇 測序列(CRC) · 在傅統之網路系統中,如第2圖所示,其網路介面卡11 主要包含網路控制器112及資料轉換器111 ( transceiver) 等單元,該種網路介面卡11之網路資料傳輸原理係由該資 料轉換器111接收傳輸線10所傳來之封包(Packet),並透過 該資料轉換器111將所接收之封包資料轉換成適當格式 後,再送至該網路控制器112,該網路控制器112主要包括 1^ I - i n^i ^^1 HI n ^^1 m ——I --- 111 n、一_5J (請先閲讀背面之注意事項再填寫本頁) 2 本紙張尺度適用中國國家標準(CNS)A4規格(210X297公釐) 4 4S3 7 ] 經濟部中央標率局貝工消費合作社印装 A7 B7 五、發明説明Lzi) 網路界面邏輯電路113 (network interface logic)、中斷信 號控制邏輯電路 114 (interrupt threshold contro 丨 logic)、 資料暫存記憶體115 (buffer memory)及系統界面邏輯電 路 116 (host system interface logic)等單元,該網路控制 器112之中斷信號控制邏輯電路114先檢査由該資料轉換器 111所傳來之封包之目的位址是否與來源位址相符,若不相 符•則該控制器112即不再處理後績資料,若符合,則該網 路控制器112即透過網路界面遁輯電路113之控制,將該封 包資料依序存至該資料暫存記憶體115,待該封包資料完全 存入該資料暫存記憶體115後,該中斷信號控制邏輯電路 114將檢査該封包之資訊段檢測序列(CRC)是否正確,若正 確,則表示已收入一正常封包•該中斷信號控制邏辑電路 114即發出中斷信號,透過該系統界面邏輯電路116,通知 主機12之中央處理器處理該筆封包資料。 此外,在傳統之網路系統中,網路介面卡11每接收一 封包,無論該封包係靥要求封包或回應封包,均必須發出 一中_號,通知主機12之中央處理器判斷處理該封包, 若主機12之中央處理器判斷該封包係一要求封包時,中央 處理器將啓動ARP或PING之自動回應程序,發送回應訊 息。 此種傳統網路系統之中斷信號係在整個封包進入該資 料暫存記億|115時,才由網路控制器112發出,意即在一 個正常之封隹(packet)被完全接收後,才產生中斷信號,如 第3圖所示之A點,通知主機I2之中央處理器讀取該封包資 3 本紙張尺度適用中圉國家標準(CNS ) Α4規格(210X297公釐) (請先Μ讀背面之注意事項再填寫本頁) 裝* ^48371 A7 ____B7 五、發明説明(二) 經濟部中央樣準局貝工消費合作杜印装 料。由此可知,在傳統網路系統中,網路介面卡11每接收 一封包,即必須發出一中斷信號,通知主機12之中央處理 器處理該封包*而由發出中斷信號到中央處理器開始處理 資料間,一般均存在有一段時間之延遲At。 尤須注意者,乃現今電腦網路之傳輸速度愈來愈农, 以髙速乙太網路爲例,其封包傳輸量最快可達每秒復碧 148,800之封包數(Gigabit之乙太網路每秒傳送之封包數更 將十倍於此),倘網路介面卡在接收到每一封包時,均對電 腦主機之中央處理器發出一中斷信號|以產生中斷,而中 央處理器對每一中斷,又需耗費10微秒(jti sec)之時間來 處理,如此,中央處理器在接收網路介面卡每秒所傳送之 封包數時,至少另需耗費約1.5秒之時間來處理中斷信號, 致該種傳統網路介面卡始終無法有效提髙電腦之中央處理 器及網路系統之處理效能•由此可知,如何有效減少網路 介面卡對電腦主機發出中斷訊號之次數,實乃提升網路效 能之一重要課題· 此外,理論上,電腦常用之PCI擴充槽之頻寬約爲133 MByte,該頻寬係被其上所有之介面卡所分享,而網路介 面卡在傳送數量龐大之封包時,又需耗費大量頻宽(髙速乙 太網路全雙功爲25 M Byte,Gigabit ΖΓ太網則爲250 Μ Byte),故欲有效提升電腦中央處理器之整體效能,將有賴 於是否能有效減少網路封包逋過擴充槽之數量。 發明網要: {請先閲讀背面之注意事項再填寫本頁) -訂 4 本紙張尺度適用中國闺家標準^阳)八4規格(210><297公釐) 4483 7 A7 _;_B7 五、發明説明 (四) 有鑑於前述傳統網路系統在設計上所衍生出之中斷次 數頻繁及時間延遲等問題,發明人乃硏究發明出一種能自 動檢査及過濾ip封包之網路介面卡結構及其方法,期利用 網路系統中網路層(Network Layer)之IP通信協定特性•在 網路介面卡上加設一通信協定偵測電路,以在網路封包進 入網路介面卡時,直接偵測所收到之封包1是否爲標準之 IP封包,如確實是IP封包,則檢査IP表頭內之存活時間是 否大於零,及其表頭檢査碼是否正確,並比較其目的1P位 址是否與一 IP位址記錄器內預設之IP位址相符’如檢査無 誤且目的IP位址相符,網路介面卡即依處理一般封包之方 式,發出中斷訊號,經電腦擴充槽,通知電腦之中央處理 器,自網路介面卡提領所收到之封包’否則’網路介面卡 將過濾逾時、錯誤或1P位址不符之IP封包,予以丟棄,以 避免因該等不符1P通信協定之封包而對電腦中央處理器產 生中斷* 經濟部中央標準局男工消費合作社印製 (請先閱讀背面之注意事項再填寫本頁) 本發明之另一目的,係當該通信協定偵測電路進一步 偵測出該IP封包之ICMP型態檷位表示PING之要求訊息 時,將啓動PING之自動回應程序,直接發送回應訊息’而 無須發出一中斷信號通知主機之中央處理器處理該封包’ 有效減輕電腦擴充槽及中央處理器之負擔,俾大輻提昇網 路系統資料處理之速率及效能· 本發明之又一目的,係利用網路系統之ARP通信篮定 特性,在網路介面卡上加設一通信協定偵測電路,以在網 路封包進入網路介面卡時,直接偵辱11_收到之封包,是否 5 本紙張尺度適用中國國家標率(CNS ) A4規格(210X297公釐) 經濟部中央樣準局貝工消费合作社印装 A7 B7 五、發明説明lSj 爲標準之ARP回鹰封包,並比較其目的IP位址是否與一 IP 位址記錄器內預設之IP位址相符,如檢査無誤且目的^位 址相符*則依一般封包之傅送方式,發出中斷訊號,經由 電腦之擴充槽,通知電腦之中央處理器•自網路介面卡提 領所收到之該封包;若該ARP封包係一要求封包,則啓動 ARP自動回應程序,直接發送回應訊息;否則,將錯誤之 封包丟棄,以有效減少產生中斷之次數,縮短中斷訊號所 造成之時間延遲。 圖式說明: 第1圖乃乙太網路中封包之框架結構示意圖; 第2圖乃傳統網路系統之硬體架構方塊示意圖; 第3圖乃傳統網路系統在中斷信號發出與中央處理器進行 資料處理間時間延遲情形之示意圖; 第4圖乃國際標準組織(Internationa丨 Standard Organizer, 簡稱ISO)所建議之OSI (Open Systems Interconnection)電 腦通信標準模式中七個功能層次之示意圖; 第5圖乃本發明之硬體架構方塊示意圖: 第6圖乃乙太網路中IP封包之框架結構示意圖: 第7圔乃本發明之動作流程示意圖。 主要元件編號: 網路介面卡 21 網路控制器 22 資料轉換器 23 6 本纸張尺度適用中固國家樣準(CNS ) A4規格(210X 297公釐) ...............—I—I I r ί i -i ^1.1 (請先鬩讀背面之注意事項再填寫本頁) 4483 7 1 A7 ___B7五、發明説明 (六) 通訊協定偵測器 24 網路界面蘧輯電路 221 中斷信號控制邏輯電路 222 資料暫存記憶體 223 系統界面暹輯電路 224 通訊協定偵測電路 242 IP位址記錄器 244 經濟部中央揉準局貝工消費合作社印掣 詳細說明z 在網路系統上,爲使所連接之不同電腦間,彼此得以 相互連接溝通及傳遞訊息,必需藉由一彼此能相互遵循之 通信協定,令一電腦所發出之訊息,可經由該通信協定, 而正確地傳送至網路系統上與其相連線之其它電腦•且彼 此所發出之訊息,皆可相互瞭解,而達到互通訊息之目的。 一般言,通信協定係將通信活動上所應有之一切功能及規 格,予以結構化分•成爲若干垂直關連之層次,每一層都 有其完成通訊工作所應具備之功能,各層次間彼此職權分 明,分層負貴,以依序完成建構互通訊息之各項工作· 根據國際標準組織(Internationa丨 Standard Organizer, 簡稱ISO)建議作爲電腦通信標準模式之〇SI (Open Systems Interconnection)模式,參閲第4圖所示,主要分 成下列七個功能層次* (一) 實館控制屉(The Pyscia丨 Coiitrol Layer); (二) 資料鍵控制層(The Data Link Contrl Layer); ^^1 ^^1 ^^1 ^^1 ^^1 ^^1 ^^1 In 03 、vs (請先閱讀背面之注意事項再填寫本頁) 7 本紙張尺度適用中國國家標準(CNS > A4规格(210X297公釐) 經濟部中央標準局貝工消费合作社印* 4483 71 A7 B7__ 五、發明説明(^) (三) 網路層(Network Layer); (四) 傳輸控制層(The Transport Layer); (五) 會談層(The Session Layer); (六) 表達層(The Presentation Layer); (七) 應用層(The Application Layer) » 在 OSI (Open Systems Interconnection)模式之七個功 能層次中,較低之三置主要係指與數位通信網路有醑之功 能,較高之四層則係指與通信系統及各種應用有關之功 能,而其中第一層之實體控制層及第二層之資料鏈控制層 之功能主要係藉由硬體完成· 以一般網路介面卡爲例,其中各電子元件主要係爲實 現電子工程師協會(Inst〗tute Electrical and Electronics Engineers,簡稱IEEE)網路模型中之通輯連結(Logical Link Control,簡稱 LLC)及媒體存取控制(Media Access Control, 簡稱MAC)之功能,亦即相當於國際標準組織(International Standard Organizer,簡稱 ISO)中之實體暦(Physical)和資 料鏈層(Data Link}之功能·至於,OSI模式中第三層之網 路層之大部份功能及其它較髙四層之功能則完全係藉由軟 體予以完成。 由於,根據國際標準組織(InternationaI StandardThe Central Government Bureau of the Ministry of Economic Affairs of the Central Bureau of Shellfish Consumer Cooperatives Printed A7 B7___ 5. Description of the Invention Background of the Invention: (The present invention is a network that can automatically check and reduce IP (Internet Protocol, IP for short) packets and directly start the response process. Interface card structure and method, especially a function of automatically checking IP packets and ARP (Address Resoution Protocal 'hereinafter) packets on a general network interface card to discover the network interface card of the present invention When the received packets are required packets, the ARP or PING automatic response procedure can be directly started to send a response message, and the network interface card can be used for timeouts, errors, or IP addresses that do not match. And discard them without causing these packets to interrupt the computer's central processing unit, so it can effectively improve the computer's central processing unit (ie, CPU) and network system processing performance. Previous skills: Press, general Ethernet The frame structure of the packet, as shown in the first circle, the first 8 bytes are the preamble and the frame start column (SFD), and the next 12 bytes are the destination address. The starting address bit, then the two-byte data type or length bit, followed by the data segment and information segment speculative sequence (CRC) · In Futong's network system, such as the second As shown in the figure, the network interface card 11 mainly includes a network controller 112 and a data converter 111 (transceiver). The network data transmission principle of the network interface card 11 is that the data converter 111 receives a transmission line. Packets sent from 10, and the received packet data is converted into an appropriate format by the data converter 111, and then sent to the network controller 112. The network controller 112 mainly includes 1 ^ I- in ^ i ^^ 1 HI n ^^ 1 m ——I --- 111 n 、 一 _5J (Please read the precautions on the back before filling this page) 2 This paper size applies to China National Standard (CNS) A4 (210X297 mm) 4 4S3 7] Printed by A7 B7, Shellfish Consumer Cooperative, Central Standards Bureau, Ministry of Economic Affairs 5. Description of the Invention Lzi) Network interface logic 113 (network interface logic), interrupt signal control logic 114 (interrupt threshold) contro 丨 logic), data temporary memory 115 (b (uffer memory) and system interface logic circuit 116 (host system interface logic). The interrupt signal control logic circuit 114 of the network controller 112 first checks whether the destination address of the packet sent by the data converter 111 is the same as the destination address of the packet. The source addresses match. If they do not match, the controller 112 will no longer process the post-history data. If they match, the network controller 112 will control the packet data in sequence through the control of the network interface editing circuit 113. Save to the data temporary storage memory 115. After the packet data is completely stored in the data temporary storage memory 115, the interrupt signal control logic circuit 114 will check whether the information segment detection sequence (CRC) of the packet is correct. , It indicates that a normal packet has been received. The interrupt signal control logic circuit 114 issues an interrupt signal, and via the system interface logic circuit 116, notifies the central processor of the host 12 to process the packet data. In addition, in the traditional network system, each time the network interface card 11 receives a packet, whether the packet is a request packet or a response packet, it must issue a medium _ number to notify the central processor of the host 12 to judge and process the packet. If the central processor of the host 12 determines that the packet is a request packet, the central processor will start an automatic response procedure of ARP or PING and send a response message. The interruption signal of this traditional network system is sent by the network controller 112 when the entire packet enters the data temporary storage | 115, which means that after a normal packet is completely received, Generate an interrupt signal, as shown in point A in Figure 3, and notify the central processor of host I2 to read the packet. 3 The paper size is applicable to the China National Standard (CNS) A4 specification (210X297 mm) (please read it first) Note on the back, please fill in this page again) Packing * ^ 48371 A7 ____B7 V. Description of the Invention (2) The Central Bureau of Procurement, Ministry of Economic Affairs, Shellfisher Consumer Cooperative Du printed materials. It can be seen that in the traditional network system, each time the network interface card 11 receives a packet, it must send an interrupt signal to notify the central processor of the host 12 to process the packet *, and the interrupt signal is sent to the central processor to start processing. There is usually a delay, At, between the data. It is particularly important to note that the transmission speed of today's computer networks is getting more and more agricultural. Taking the high-speed Ethernet as an example, the fastest packet transmission rate can reach 148,800 packets per second (Gigabit's Ethernet). The number of packets transmitted per second will be ten times this). If the network interface card receives each packet, it will send an interrupt signal to the central processor of the computer host to generate an interrupt, and the central processor will Each interrupt takes 10 microseconds (jti sec) to process. In this way, when the central processor receives the number of packets transmitted by the network interface card per second, it takes at least another 1.5 seconds to process The interruption signal caused the traditional network interface card to fail to effectively improve the processing performance of the computer's central processor and network system. From this, we can know how to effectively reduce the number of interrupt signals sent by the network interface card to the computer host. It is an important issue to improve network performance. In addition, in theory, the bandwidth of a PCI expansion slot commonly used in computers is about 133 MByte. This bandwidth is shared by all the interface cards on it, and the network interface card is transmitting. When a large number of packets are used, a large amount of bandwidth is required (25 M Byte for full-speed dual-speed Ethernet and 250 Byte for Gigabit ZΓ Ethernet). Therefore, to effectively improve the overall performance of the computer's central processing unit, It will depend on whether the number of expansion slots in the network packet can be effectively reduced. The invention of the network to: (Please read the notes on the back before filling out this page)-Order 4 paper standards applicable to Chinese standards ^ Yang) 8 4 specifications (210 > < 297 mm) 4483 7 A7 _; _ B7 5 (4) In view of the problems of frequent interruptions and time delays derived from the design of the aforementioned traditional network system, the inventor has invented a network interface card structure that can automatically check and filter IP packets. And its method, using the characteristics of the IP communication protocol of the Network Layer in the network system. • Adding a protocol detection circuit to the network interface card, when the network packet enters the network interface card, Directly detect whether the received packet 1 is a standard IP packet. If it is indeed an IP packet, check whether the time-to-live in the IP header is greater than zero and its header check code is correct, and compare its destination 1P bit Does the address match the preset IP address in an IP address recorder? If it is checked correctly and the destination IP address matches, the network interface card sends an interrupt signal in the same way as a normal packet, and the computer expands the slot to notify computer The central processing unit will withdraw the received packets from the network interface card. Otherwise, the network interface card will filter the IP packets with timeout, error or 1P address inconsistency, and discard them to avoid these inconsistent 1P communication protocols. Packet interrupts the CPU of the computer Further detecting that the ICMP type bit of the IP packet indicates a PING request message, the PING automatic response procedure will be started, and a response message will be sent directly, without the need to send an interrupt signal to notify the host's central processor to process the packet. Valid Reduce the burden of computer expansion slot and central processing unit, and greatly increase the speed and performance of data processing in network systems. Another object of the present invention is to use the ARP communication basket of the network system to set the characteristics on the network interface card. Add a protocol detection circuit to detect the packet received when the network packet enters the network interface card. Is the 5 paper size applicable? National Standard Rate (CNS) A4 specification (210X297 mm) Printed on the A7 B7 by the Shell Cooperative Consumer Cooperative of the Central Bureau of Standards of the Ministry of Economic Affairs 5. Description of the invention lSj is the standard ARP return hawk packet and compares whether the destination IP address is the same as The preset IP address in an IP address recorder matches. If the check is correct and the destination ^ address matches *, an interrupt signal is sent according to the normal sending method of the packet, and the computer's expansion slot is used to notify the computer's CPU. • Withdraw the packet received from the network interface card; if the ARP packet is a request packet, start the ARP automatic response procedure and send the response message directly; otherwise, discard the wrong packet to effectively reduce the interruption This reduces the time delay caused by the interrupt signal. Schematic description: Figure 1 is a schematic diagram of the frame structure of a packet in an Ethernet network; Figure 2 is a block diagram of the hardware architecture of a traditional network system; Figure 3 is a traditional network system that sends interrupt signals to the CPU Schematic diagram of the time delay between data processing; Figure 4 is a schematic diagram of the seven functional levels in the OSI (Open Systems Interconnection) computer communication standard mode recommended by the International Standards Organization (ISO); Block diagram of the hardware architecture of the present invention: FIG. 6 is a schematic diagram of the frame structure of IP packets in an Ethernet network. FIG. 7 is a schematic diagram of the operation flow of the present invention. Main component number: Network interface card 21 Network controller 22 Data converter 23 6 This paper size is applicable to China Solid State Standard (CNS) A4 specification (210X 297 mm) .......... .....— I—II r ί i -i ^ 1.1 (Please read the notes on the back before filling this page) 4483 7 1 A7 ___B7 V. Description of the invention (6) Protocol detector 24 Network Interface editing circuit 221 Interrupt signal control logic circuit 222 Data temporary storage memory 223 System interface Siam circuit 224 Protocol detection circuit 242 IP address recorder 244 Central Government Bureau of the Ministry of Economic Affairs, Printing and Printing Co., Ltd. On the network system, in order for the different computers connected to each other to communicate and communicate with each other, it is necessary to use a communication protocol that can follow each other, so that the messages sent by a computer can pass through the communication protocol, The messages sent to other computers connected to the network system and connected to each other can be understood by each other, so as to achieve the purpose of mutual communication. Generally speaking, the communication agreement is to structure all the functions and specifications that are necessary for communication activities. It is structured into a number of vertically related layers. Each layer has its own functions to complete the communication work. Clear, layered and expensive, in order to complete the construction of intercommunication information in order · According to the International Standards Organization (Internationa 丨 Standard Organizer (ISO) recommended as the computer communication standard model 〇SI (Open Systems Interconnection) mode, see As shown in Figure 4, it is mainly divided into the following seven functional layers * (1) The Pyscia 丨 Coiitrol Layer; (2) The Data Link Contrl Layer; ^^ 1 ^^ 1 ^^ 1 ^^ 1 ^^ 1 ^^ 1 ^^ 1 In 03, vs (please read the notes on the back before filling this page) 7 This paper size applies to Chinese national standards (CNS > A4 size (210X297 mm) ) Printed by the Shellfish Consumer Cooperative of the Central Standards Bureau of the Ministry of Economic Affairs * 4483 71 A7 B7__ V. Description of the Invention (^) (3) Network Layer; (4) The Transport Layer; (5) Talks The Ses sion Layer); (6) The Presentation Layer; (7) The Application Layer »Of the seven functional layers of the OSI (Open Systems Interconnection) model, the lower three are mainly related to Digital communication networks have functions, the higher four layers refer to functions related to communication systems and various applications, and the functions of the first layer of the physical control layer and the second layer of the data chain control layer are mainly borrowed. Completed by hardware. Take a general network interface card as an example, in which each electronic component is mainly used to implement the logical link control (Logical Link Control) in the network model of the Institute of Electronic Engineers (Inst) tute Electrical and Electronics Engineers (IEEE). The functions of LLC) and Media Access Control (MAC) are equivalent to the functions of Physical and Data Link in the International Standard Organizer (ISO). Functions. As for most of the functions of the third layer of the network layer in OSI mode and other functions of the upper four layers are completely completed by software. Because, according to the International Standards Organization (InternationaI Standard
Organizer,簡稱 ISO)所建議之 〇SI (Open Systems Interconnection)模式中七個功能層次之協定架構,每一層 彼此職權分明,分層負責,具有獨立性及模組化之特性’ 因此,各硏究團體或組織亦各自依其所建構之系統發展每 8 本紙張尺度逋用中國國家橾率(CNS ) A4规格(210X297公釐) (請先«讀背面之注意事項再填寫本頁) 订 4483 71 經濟部中央櫺率局負工消費合作杜印裝 A7 B7 五、發明説明(/sj 一層次之協定。在諸多通訊協定中V美國國防部髙深硏究 企畫署(DARPA)所硏訂之傳输控制協定/網際網路協定 (Transmission Control Protocol/Internet Protocol ,簡稱 TCP/IP)乃目前被廣泛採用之標準,該項協定中IP乃屬 iso之第三層,具有網際網路(Internetworking)之功能,係 一種網際網路協定(Internetworking protoco丨):TCP乃靥 OSI之第四層,具備傳送服務功能,係一種端至端傳輸控 制協定(End-to-end transport protocol);此兩者乃構成傳 送網路(Transport network)之主角,其中ΪΡ又係網路屠之 基本傳送協定· 本發明乃一種能自動檢査及過濾IP封包且直接啓動回 應程序之網路介面卡結構及其方法,主要係針對該網際網 路協定(IP)中IP封包之特性,利用在網路介面卡上加設 一通信協定偵測電路,以在網路封包進入網路介面卡時, 令網路介面卡可根據網際網路協定(IP)及位址轉換協定 (ARP),偵測所收到之封包,是否爲標準之1P封包或ARP 之回應封包,並比較其目的IP位址是否與一IP位址記錄器 內預設之IP位址相符,如檢査無誤且目的IP位址相符,則 依處理一般封包之方式,發出中斷訊號,經由電腦之擴充 槽,通知電腦之中央處理器,自網路介面卡提領所收到之 封包;若該IP封包之ICMP型態欄位係表示PING之要求訊 息或該ARP封包係一要求封包,則本發明將啓動ARP或 PING之自動回應程序,直接發送回應訊息:否則,即將封 包丟棄· 9 本紙張尺度適用中國國家標準(CNS ) A4規格(210X297公釐) ---------袭------·訂-----;^ (請先S讀背面之注意事項再填寫本頁) 4483 71 A7 __B7 五、發明説明(九) 經濟部中央橾半局貝工消费合作社印製 因此*本發明可令ISO第三層(網路層)之網際網路協 定(Internet Protocol,即IP)中I需透過主機中央處理器, 藉軟體完成之大部份功能|均能直接由本發明之網路介面 卡完成,以直接過濾逾時、錯誤或IP位址不符之ΪΡ封包, 並在該IP封包之ICMP型態檷位係表示PING之要求訊息或 該ARP封包係一要求封包時,直接啓動ARP或PING之自動 回應程序|發送回應訊息,以縮短因網路介面卡產生中斷 訊號所造成之時間延遲,減輕電腦擴充槽及中央處理器之 負擔,以大輻提昇網路系統資料處理之速度及效率》 本發明之網路介面卡21主要包含網路控制器22、資料 轉換器23 (transceiver)及通訊協定偵測器24等單元,參 閲第5圖所示《其中由傳输線10傳來之封包(Packet)係透過 該資料轉換器23轉換成適當格式後,再分別送至該網路控 制器22及通訊協定偵測器24,其中該網路控制器22主要包 括一網路界面邏輯電路221 ( network interface logic )、一 中斷信號控制邏輯電路222 (interrupt threshold control logic)、一資料暫存記億體223 (buffer memory)及一系 統界面薄輯電路224( host system interface logic)等單元, 該通訊協定偵測器24則包含一通訊協定偵測電路242及一 IP位址記錄器244等單元•該網路控制器22之網路界面邏輯 電路221在接收到由該資料轉換器23所傳來之封包後,係先 將該封包傳送至該通訊協定偵測電路242 · 該通訊協定偵測電路242將檢査該封包之型態欄位是 否爲0800 *參閲第6及7圓所示,若不是*則該封包不是一 n. I- i 1--- - - - - - - - - 11 n J 衣 I..... - --- --1 ^^1 (請先聞讀背面之注$項再填寫本頁) 10 本紙張尺度逋3中國國家標準(〇嗯)八4規格(210父297公釐) 4483 7 1 經濟部+央標準局員工消費合作社印装Organizer (referred to as ISO) proposes an agreement structure of the seven functional levels in the 0SI (Open Systems Interconnection) model. Each layer has clear powers, layers of responsibility, and independence and modularity. Groups or organizations also develop Chinese papers according to the system they construct, using the Chinese National Standard (CNS) A4 size (210X297 mm) (please «read the precautions on the back before filling this page). Order 4483 71 Department of Economics, Central Bureau of Economics, Work and Consumption Cooperation Du Yinzhuang A7 B7 V. Description of Invention (/ sj level agreement. Among many communication agreements, the United States Department of Defense has deliberately set it down under the Planning Department (DARPA) Transmission Control Protocol / Internet Protocol (TCP / IP) is a widely used standard. IP is the third layer of iso in this protocol and has Internetworking. The function is an Internetworking protocol: TCP is the fourth layer of IOSI and has the function of transmission service. It is an end-to-end transmission control protocol (End-to- end transport protocol); these two are the protagonists of the transport network, of which ip is the basic transport protocol of the network. The present invention is a network that can automatically check and filter IP packets and directly start the response process. The structure and method of the road interface card are mainly aimed at the characteristics of the IP packet in the Internet Protocol (IP). A communication protocol detection circuit is added to the network interface card so that the network packet enters the network interface. When the card is used, the network interface card can detect whether the received packet is a standard 1P packet or an ARP response packet according to the Internet Protocol (IP) and Address Translation Protocol (ARP), and compare its purpose Whether the IP address matches the preset IP address in an IP address recorder. If it is checked correctly and the destination IP address matches, then an interrupt signal is sent according to the general packet processing method, and the computer is notified via the expansion slot of the computer. The central processing unit retrieves the received packet from the network interface card; if the ICMP type field of the IP packet indicates a PING request message or the ARP packet is a request packet, the present invention will start AR P or PING's automatic response procedure, directly send a response message: Otherwise, the packet will be discarded. 9 This paper size applies the Chinese National Standard (CNS) A4 specification (210X297 mm) --------- Raid --- --- · Order -----; ^ (Please read the precautions on the back before filling out this page) 4483 71 A7 __B7 V. Description of Invention (9) Printed by the Bayou Consumer Cooperative of the Central Government Bureau of the Ministry of Economic Affairs * The present invention can make most of the functions in the Internet Protocol (IP) of the ISO layer 3 (Internet layer) through the host CPU, which can be completed directly by the software. The network interface card is completed to directly filter time-out, error, or IP address packets that do not match. When the ICMP type of the IP packet is a PING request message or the ARP packet is a request packet, Start the automatic response process of ARP or PING | Send a response message to reduce the time delay caused by the interrupt signal generated by the network interface card, reduce the burden on the computer expansion slot and central processing unit, and greatly improve the processing of network system data Speed and efficiency The network interface card 21 mainly includes units such as a network controller 22, a data converter 23 (transceiver), and a communication protocol detector 24. Refer to FIG. 5 where “Packets from the transmission line 10 (Packet ) Is converted into an appropriate format by the data converter 23, and then sent to the network controller 22 and the protocol detector 24 respectively, where the network controller 22 mainly includes a network interface logic circuit 221 (network interface logic), an interrupt signal control logic circuit 222 (interrupt threshold control logic), a data buffer memory 223 (buffer memory) and a system interface book circuit 224 (host system interface logic) and other units, the communication protocol The detector 24 includes a communication protocol detection circuit 242 and an IP address recorder 244. The network interface logic circuit 221 of the network controller 22 receives the information transmitted by the data converter 23. After the packet is sent, the packet is first transmitted to the communication protocol detection circuit 242. The communication protocol detection circuit 242 will check whether the type field of the packet is 0800. * See circles 6 and 7, if not *then The packet is not a n. I- i 1 -----------11 n J clothing I .....---- --1 ^^ 1 (Fill in this page again.) 10 Paper sizes: 3 Chinese National Standards (Oh), 8 Specifications (210 mm, 297 mm), 4483 7 1 Printed by the Ministry of Economic Affairs + Central Standards Bureau, Consumer Consumption Cooperative.
A7 _B7五、發明説明(f) IP封包,嗣再檢査該封包之型態檷位是否爲0806,若不是, - 則該封包亦不是一ARP封包,此時,該通訊協定偵測電路 242將依一般封包處理程序,將該封包交由該中斷信號控制 邏輯電路222檢査其目的位址是否與來源位址相符,若不相 符,則該控制器22即不再處理後續資料,若符合,則該網 路控制器22即將該封包資料依序存至該資料暫存記憶體 223,待該封包資料完全存入該資料暫存記憶體223後,該 中斷信號控制邏輯電路222將檢査該封包之資訊段檢測序 列(CRC)是否正確,若正確,則表示已收入一正常封包, 該中斷信號控制邏輯電路222即發出中斷信號,透過該系統 界面邏輯電路224,通知主機I2之中央處理器處理該筆封包 資料。 復參閱第7圖所示,若該通訊協定偵測電路242檢査該 封包之型態檷位確爲0800,即表示該封包爲一IP封包,此 時,該通訊協定偵測電路242即根據該IP封包之資料框架結 構,參閱第6圖所示,依序檢査該IP封包之存活時間(TTL) 是否等於零?若是,則丟棄該封包,而結束處理.動作;若 大於零,繼績檢査該IP封包之表頭檢査碼是否正確?若 否,則丟棄該封包,結束處理動作;若該IP封包之表頭檢 査碼正確,則再檢査該IP封包之目的IP位址是否與該通訊 協定偵測器24之IP位址記錄器244中預設之目的IP位址相 符?若不符合,則丟棄該封包,結束處理動作;若IP位址 符合,該通訊協定偵測電路242將檢査該IP封包之ICMP型 態欄位是否表示PING之要求訊息,若是,即直接啓動PING (請先閲讀背面之注意事項再填寫本頁) 11 本紙張尺度適用中國闺家標準(〇灿>八^格(210父297公釐) 4483 A7 B7 經濟部中央標準局負工消費合作社印裝 五、發明説明(+) 之自動回應程序,直接發送回應訊息,否則,即依一般封 包處理程序,將該封包交由該主機U之中央處理器處理》 若該通訊協定偵測電路242檢査該封包之型態檷位爲 0806時,則表示該封包係一ARP封包|此時,該通訊協定 偵測電路242將再檢査該封包是否爲一要求(request)封 包,若該封包係一ARP要求封包,則再檢査該ARP封包之 目的IP位址是否與該通訊協定偵測器24之IP位址記錄器 244中預設之目的IP位址相符?若不符合,則丟棄該封包, 結束處理動作;若目的IP位址符合,即直接啓動PING之自 動回應程序,直接發送回應訊息。若該封包係一ARP回應 (reply)封包,即依一般封包處理程序,將該封包交由該 主機12之中央處理器處理· 在本發明中,該通訊協定偵測器24之IP位址記錄器244 中所記錄之IP位址,係可由網路系統使用者或管理人透過 主機I2並經該系統界通累輯電路224予以預先設定者。 由此可知,本發明之網路介面卡可有效過濾逾時、錯 誤或IP位址不符之IP封包或ARP封包,並予以丟棄,若該 IP封包之ICMP型態檷位係表示P1NG之要求訊息或該ARP 封包係一要求封包,則本發明將啓動ARP或PING之自動回 應程序,直接發送回應訊息,以避免網路介面卡對電腦中 央處理器發出中斷訊號,產生中斷,造成中央處理器之負 擔及處理時間之延遲,且避免該等不符IP通信協定之封旬 通過擴充槽,造成電腦擴充槽之負荷,故本發明確實可大 辐提昇網路系統資料處理之速率及效能· -*· · 12 本紙張尺度逍用中國國家橾準(CNS ) A4说格(210X297公釐) ^^1- m 1 - - - I I E nt -------- ^J (請先聞tl背面之注意事項再填寫本頁)A7 _B7 V. Description of the invention (f) IP packet, and then check if the type of the packet is 0806, if not,-the packet is not an ARP packet. At this time, the protocol detection circuit 242 will According to the general packet processing program, the packet is handed over to the interrupt signal control logic circuit 222 to check whether its destination address matches the source address. If it does not match, the controller 22 does not process subsequent data. If it does, then The network controller 22 sequentially stores the packet data in the data temporary memory 223. After the packet data is completely stored in the data temporary memory 223, the interrupt signal control logic circuit 222 will check the packet data. Whether the information segment detection sequence (CRC) is correct. If it is correct, it indicates that a normal packet has been received. The interrupt signal control logic circuit 222 issues an interrupt signal, and via the system interface logic circuit 224, notifies the central processor of the host I2 to process the packet. Packet information. Referring to FIG. 7 again, if the communication protocol detection circuit 242 checks that the type of the packet is 0800, it means that the packet is an IP packet. At this time, the communication protocol detection circuit 242 is based on the For the data frame structure of the IP packet, refer to Figure 6 to check whether the time-to-live (TTL) of the IP packet is equal to zero? If it is, then discard the packet and end the processing. If it is greater than zero, check the header check code of the IP packet. If not, discard the packet and end the processing action; if the header check code of the IP packet is correct, then check whether the destination IP address of the IP packet is the same as the IP address recorder 244 of the protocol detector 24 Do the preset destination IP addresses match? If not, discard the packet and end the processing action; if the IP address matches, the protocol detection circuit 242 will check whether the ICMP type field of the IP packet indicates a PING request message, and if it is, directly start PING (Please read the precautions on the reverse side before filling out this page) 11 This paper size applies to Chinese standards (0 Can > octagonal (210 father 297 mm) 4483 A7 B7 Printed by the Central Standards Bureau of the Ministry of Economic Affairs and Consumer Cooperatives 5. The automatic response procedure of the invention description (+) will send the response message directly, otherwise, according to the general packet processing procedure, the packet will be processed by the central processor of the host U. If the protocol detection circuit 242 checks When the type bit of the packet is 0806, it indicates that the packet is an ARP packet. At this time, the communication protocol detection circuit 242 will check whether the packet is a request packet. If the packet is an ARP packet, If a packet is required, then check whether the destination IP address of the ARP packet matches the destination IP address preset in the IP address recorder 244 of the protocol detector 24. If not, discard the packet. End the processing action; if the destination IP address matches, it will directly start the PING automatic response procedure and directly send a response message. If the packet is an ARP reply packet, the packet will be delivered to the packet according to the general packet processing procedure Processing by the central processor of the host 12 In the present invention, the IP address recorded in the IP address recorder 244 of the protocol detector 24 can be used by a network system user or administrator through host I2 and The system circuit pre-set circuit 224 sets it in advance. It can be known that the network interface card of the present invention can effectively filter time-out, error, or IP packets or ARP packets that do not match the IP address, and discard them. The ICMP type bit of the packet indicates the request message of P1NG or the ARP packet is a request packet. The present invention will start the automatic response procedure of ARP or PING and directly send a response message to prevent the network interface card from centrally processing the computer. The processor sends an interrupt signal to generate an interrupt, which causes a burden on the central processing unit and a delay in processing time, and avoids such non-compliant IP communication protocols from passing through expansion slots and causing the computer The loading capacity of the tank, so the present invention can indeed greatly increase the speed and efficiency of data processing in the network system.-* · · 12 paper standards use the Chinese National Standard (CNS) A4 grid (210X297 mm) ^^ 1- m 1---IIE nt -------- ^ J (please listen to the notes on the back of tl before filling this page)
4 48 3 T Α7 Β7 五、發明説明rjj) _ _ 以上所述,僅係本發明之較.隹_實施例,惟,本發明所 主張之權利籰圍,並不局限於此,按热悉麗項技術人士, 依搛本發明所掲霣之技術內容,可輕易思及之等效變化, 均應靥不脫離本發明之保護範疇。 (請先聞讀背面之注意事項再填寫本頁} 訂 經濟部中央標準局員工消費合作社印装 本紙張尺度適用中國國家標準(CNS) A4规210X297公釐)4 48 3 T Α7 Β7 V. Description of the invention rjj) _ _ The above is only a comparison of the present invention. __ Examples, but the scope of the rights claimed by the present invention is not limited to this. Those skilled in the art of beauty, depending on the technical content of the present invention, can easily consider the equivalent changes, and should not depart from the protection scope of the present invention. (Please read the notes on the back before filling out this page.) Order Printed by the Consumer Cooperatives of the Central Standards Bureau of the Ministry of Economic Affairs This paper applies the Chinese National Standard (CNS) A4 Regulation 210X297 mm