CN102546348A - Method for network processor to achieve various three-layer interfaces and network processor - Google Patents

Method for network processor to achieve various three-layer interfaces and network processor Download PDF

Info

Publication number
CN102546348A
CN102546348A CN2012100270726A CN201210027072A CN102546348A CN 102546348 A CN102546348 A CN 102546348A CN 2012100270726 A CN2012100270726 A CN 2012100270726A CN 201210027072 A CN201210027072 A CN 201210027072A CN 102546348 A CN102546348 A CN 102546348A
Authority
CN
China
Prior art keywords
vlan
layer
value
layer interface
inner vlan
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN2012100270726A
Other languages
Chinese (zh)
Other versions
CN102546348B (en
Inventor
孙蓓
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
ZTE Corp
Original Assignee
ZTE Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by ZTE Corp filed Critical ZTE Corp
Priority to CN201210027072.6A priority Critical patent/CN102546348B/en
Publication of CN102546348A publication Critical patent/CN102546348A/en
Application granted granted Critical
Publication of CN102546348B publication Critical patent/CN102546348B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention discloses a method for a network processor to achieve various three-layer interfaces and a network processor, which are applied to the field of data communication. The method includes: arranging internal virtual local area network (VLAN) values, building an internal VLAN mapping index table and an interface property sheet, determining the corresponding internal VLAN values after messages are received, searching the interface property sheet according to the corresponding internal VLAN values to obtain interface properties, and then finishing three-layer processing and forwarding. The network processor is composed of a configuration module, an analysis module, a searching module and a forwarding module which can achieve the processing method. The method and the network processor not only achieve support to various three-layer interfaces simultaneously, improve networking and application flexibility of a packet transport network (PTN) device, but also tremendously save instruction space and table resources of the network processor, and improve performance of the PTN device.

Description

A kind of network processing unit is realized the method and the network processing unit of multiple three layer interfaces
Technical field
The present invention relates to data communication field, relate in particular to method and network processing unit that a kind of network processing unit is realized multiple three layer interfaces.
Background technology
Along with development of internet technology; PTN (Packet Transport Network) has become the main flow of present development; PTN equipment is the often integrated correlation function of transmission, switch and router; Become the equipment of a fusion, network processing unit has the characteristics of programmability and high handling property flexibly, and PTN equipment often realizes that with network processing unit hardware transmits.
In order to satisfy different service and networking demand; Existing route mouth also has switching port on the PTN equipment; As shown in Figure 1, have at the same time under the situation of route mouth and switching port, PTN equipment need be supported multiple three layer interfaces; If port arrangement is a switching port, then need support three layer interfaces and QinQ three layer interfaces based on VLAN (VLAN); If port arrangement is the route mouth; Then route mouth itself is one three layer interface; Simultaneously can dispose route openning interface as three layer interfaces, route openning interface is the sub-interface of route mouth based on the VLAN division, can be divided into route mouth vlan sub-interface and route mouth QinQ sub-interface.Network processing unit need be realized VLAN three layer interfaces, QinQ three layer interfaces, route mouth, route mouth vlan sub-interface and multiple three layer interfaces of route mouth QinQ sub-interface simultaneously in the limited instruction space.
In implementation procedure in the past, often can not support multiple three layer interfaces simultaneously, greatly reduce PTN equipment network and application flexibility; Perhaps supported also need the realization of multiple three layer interfaces be handled respectively, designed different list item and handling process, taken resource greatly, wasted the network processing unit instruction space, influenced the performance of PTN equipment.
Summary of the invention
The technical problem underlying that the present invention will solve is; The method and the networking processor that provide a kind of network processing unit to realize multiple three layer interfaces; It can realize the support to multiple three layer interfaces simultaneously; Improve the networking and the application flexibility of PTN equipment, and saved the instruction space and the list item resource of network processing unit greatly, improved the performance of PTN equipment.
For solving the problems of the technologies described above, method and network processing unit that the present invention provides a kind of network processing unit to realize multiple three layer interfaces comprise:
A kind of network processing unit is realized the method for multiple three layer interfaces, comprising:
Inner VLAN value is set, and the VLAN value of using himself for VLAN three layer interfaces is as inner VLAN value, for inner VLAN value of non-VLAN three layer interface applications; Set up the inside VLAN map index table of non-VLAN three layer interfaces and inner VLAN value, and the inside VLAN three layer interface attribute lists of all three layer interfaces; After receiving message,, confirm corresponding inside VLAN value, and search said inner VLAN three layer interface attribute lists in view of the above, obtain three layer interface attributes, accomplish three layers and handle and transmit the message that needs carry out three layers of forwarding.
Said inner VLAN map index table comprises: port, inner VLAN, outside VLAN are as table index, and inner VLAN value is as the table content; Said inner VLAN three layer interface attribute lists comprise: inner VLAN value is as table index, and three layer interface attributes are as the table content.
Described non-VLAN three layer interfaces comprise: QinQ three layer interfaces, route mouth, route mouth vlan sub-interface, route mouth QinQ sub-interface.
For VLAN three layer interfaces, as inner VLAN value, the three layer interface attributes that directly will dispose write in the inner VLAN three layer interface attribute lists with himself VLAN value; For non-VLAN three layer interfaces; Be inner VLAN value of its application; Set up inner VLAN map index list item with port, inner VLAN, outside VLAN as table index; The inside VLAN value of application is write in the inner VLAN map index table, and the three layer interface attributes that will dispose simultaneously write inner VLAN three layer interface attribute lists.
For the three-tier message that gets into from switching port; If message carries one deck VLAN, with this VLAN as inner VLAN value, if message is not with VLAN; Then with the PVID of port as inner VLAN value; Search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes, accomplish three layers and handle and transmit; For getting into from switching port and with the three-tier message of two-layer VLAN or the three-tier message that gets into from the route mouth; Search inner VLAN map index table according to port, inner VLAN, outside VLAN; Obtain inner VLAN value; Search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes, accomplish three layers and handle and transmit.
A kind of network processing unit is characterized in that, comprises following four sub-module:
Configuration module is used to be provided with inner VLAN value, and the VLAN value of using himself for VLAN three layer interfaces is as inner VLAN value, for inner VLAN value of non-VLAN three layer interface applications; Set up the inside VLAN map index table of non-VLAN three layer interfaces and inner VLAN value, and the inside VLAN three layer interface attribute lists of all three layer interfaces;
Parsing module is used to resolve the message that receives, and judges whether to carry out three layers of forwarding, and the VLAN analysis result that simultaneously port information and message is carried is exported to and searched module;
Search module, be used for confirming the inside VLAN value that message is corresponding, search said inner VLAN three layer interface attribute lists, obtain three layer interface attributes, export to forwarding module according to port information and the vlan information that parses;
Forwarding module is used for carrying out three layers according to the message information and the three layer interface attributes that obtain and handles and transmit.
The inside VLAN map index table that said configuration module is set up comprises: port, inner VLAN, outside VLAN are as table index, and inner VLAN value is as the table content; The inside VLAN three layer interface attribute lists that said configuration module is set up comprise: inner VLAN value is as table index, and three layer interface attributes are as the table content.
Described non-VLAN three layer interfaces comprise: QinQ three layer interfaces, route mouth, route mouth vlan sub-interface, route mouth QinQ sub-interface.
Said configuration module is used for: for VLAN three layer interfaces, as inner VLAN value, the three layer interface attributes that directly will dispose write in the inner VLAN three layer interface attribute lists with himself VLAN value; For non-VLAN three layer interfaces; Be inner VLAN value of its application; Set up inner VLAN map index list item with port, inner VLAN, outside VLAN as table index; The inside VLAN value of application is write in the inner VLAN map index table, and the three layer interface attributes that will dispose simultaneously write inner VLAN three layer interface attribute lists.
The said module of searching; Be used for: confirm when handling from three-tier message that switching port gets into, if message carries one deck VLAN, with this VLAN as inner VLAN value; If message is not with VLAN; Then with the PVID of port as inner VLAN value, search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes; Confirm to get into and during handling with the three-tier message of two-layer VLAN or from three-tier message that the route mouth gets into from switching port; Search inner VLAN map index table according to port, inner VLAN, outside VLAN; Obtain inner VLAN value; Search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes.
The invention has the beneficial effects as follows:
A kind of network processing unit realizes that the method for multiple three layer interfaces and network processing unit have proposed a kind of based on enlarging the method that inner VLAN realizes multiple three layer interfaces; Simultaneously that the list item design and the handling process of multiple three layer interfaces is unified; It is through being provided with inner VLAN value; The VLAN value of using himself for VLAN three layer interfaces is as inner VLAN value; For inner VLAN value of non-VLAN three layer interface applications, set up the inside VLAN map index table of non-VLAN three layer interfaces and inner VLAN value, and the inside VLAN three layer interface attribute lists of all three layer interfaces; After receiving message,, confirm corresponding inside VLAN value, and search said inner VLAN three layer interface attribute lists in view of the above, obtain three layer interface attributes, accomplish three layers and handle and transmit the message that needs carry out three layers of forwarding.
A kind of network processing unit, its by configuration module, parsing module, search module and forwarding module is formed, it can realize the aforementioned processing method; The inventive method and equipment have not only been realized the support to multiple three layer interfaces simultaneously; Improve the networking and the application flexibility of PTN equipment, and saved the instruction space and the list item resource of network processing unit greatly, improved the performance of PTN equipment.
Description of drawings
Fig. 1 is the sketch map of VLAN three layer interfaces, QinQ three layer interfaces, route mouth, route mouth vlan sub-interface and multiple three layer interfaces of route mouth QinQ sub-interface;
Fig. 2 is the embodiment that a kind of network processing unit of the present invention is realized the method for multiple three layer interfaces, the inside VLAN of expansion;
Fig. 3 is the embodiment that a kind of network processing unit of the present invention is realized the method for multiple three layer interfaces, multiple three layer interface Unified Treatment flow processs;
Fig. 4 realizes the network processing unit sketch map of multiple three layer interfaces for the present invention.
Embodiment
Combine accompanying drawing that the present invention is done further explain through embodiment below.
Like Fig. 2 and Fig. 3; A kind of network processing unit is realized the embodiment of the method for multiple three layer interfaces; Existing route mouth also has switching port on the PTN equipment; Need to support multiple three layer interfaces, comprise VLAN three layer interfaces, QinQ three layer interfaces, route mouth, route mouth vlan sub-interface, route mouth QinQ sub-interface.Traditional VLAN range size is 4K, and the present invention enlarges inner VLAN, and is as shown in Figure 2; The scope of 0-4K-1 is used by VLAN three layer interfaces; The above VLAN of 4K and 4K is used by QinQ three layer interfaces, route mouth, route mouth vlan sub-interface, route mouth QinQ sub-interface, for this four type of three layer interface, extracts three key factors: port, inner VLAN, outside VLAN; Designed inner VLAN map index table, with reference to following table:
The inner VLAN map index of table 1 table
Port Inner VLAN Outside VLAN Inner VLAN
gei_1/1 X1 Y1 4K+1
gei_1/2 0xFFF 0xFFF 4K+2
gei_1/2 0xFFF Y2 4K+3
gei_1/2 X3 Y3 4K+4
As above shown in the table (table 1), inquire about inner VLAN map index table according to port and vlan information and obtain inner VLAN.
The attribute of all three layer interfaces all is kept in the inner VLAN three layer interface attribute lists.Inner VLAN three layer interface attribute lists are with reference to following table:
The inner VLAN three layer interface attribute lists of table 2
VLAN ID (inner VLAN) Three layer interface attributes
?0 Interface attributes
?1 Interface attributes
?... Interface attributes
?4K Interface attributes
?4K+1 Interface attributes
?4K+2 Interface attributes
?4K+3 Interface attributes
?4K+4 Interface attributes
?... Interface attributes
The scope of inner VLAN can be provided with according to the performance index and the internal memory situation of equipment.
For the three-tier message that gets into from switching port; If message carries one deck VLAN, with this VLAN as inner VLAN value, if message is not with VLAN; Then with the PVID of port as inner VLAN value; Search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes, accomplish three layers and handle and transmit; For getting into from switching port and with the three-tier message of two-layer VLAN or the three-tier message that gets into from the route mouth; Search inner VLAN map index table according to port, inner VLAN, outside VLAN; Obtain inner VLAN value; Search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes, accomplish three layers and handle and transmit.
As shown in Figure 3, a kind of network processing unit is realized the embodiment of the method for multiple three layer interfaces, and its workflow may further comprise the steps:
Step 301: equipment receives message.
Step 302: analytic message.
Step 303: according to the situation of packet parsing, if the target MAC (Media Access Control) address of message is the MAC Address of three layer interfaces, and message is the IPV4 message, explains that message need carry out three layers of forwarding, goes step 304, otherwise goes other handling processes.
Step 304: according to the configuring ports that receives message,, go step 306,, then go step 305 if port is a switching port if port is the route mouth.
Step 305:,, then go step 306, otherwise go step 308 if message gets into and is with two-layer vlan information from switching port according to the packet parsing situation.
Step 306:, look into inner VLAN map index table with port information and vlan information according to the situation of packet parsing.If message gets into and be with two-layer VLAN from the route mouth, just remove to look into inner VLAN map index table with port, inner VLAN that message is with, the outside VLAN of being with; If message gets into and message band one deck VLAN from the route mouth, just remove to look into inner VLAN map index table with port, inner VLAN 0xFFF, the outside VLAN of being with; If message gets into and be not with VLAN from the route mouth, just remove to look into inner VLAN map index table with port, inner VLAN 0xFFF, outside VLAN 0xFFF.If message is from the switching port entering and be with two-layer VLAN, remove to look into inner VLAN map index table with port, inner VLAN that message is with, outside VLAN.
Step 307: if find inner VLAN map index table, explain and disposed this three layer interface, go step 308, otherwise with packet loss.
Step 308: look into inner VLAN three layer interface attribute lists.If the three-tier message that gets into from switching port; If message band one deck VLAN, then with this VLAN value as inner VLAN value, if message is not with VLAN; Then with the PVID of port as inner VLAN value; Search inner VLAN three layer interface attribute lists with this inside VLAN value, if message that gets into from switching port and the two-layer VLAN of message band or the three-tier message that gets into from the route mouth, then be used in the inside VLAN value that step 306 finds and search inner VLAN three layer interface attribute lists.
Step 309: obtain three layer interface attributes, carry out three layers and handle and transmit.
The present invention invents the method that a kind of network processing unit is realized multiple three layer interfaces, and it realizes multiple three layer interfaces through enlarging inner VLAN, and is simultaneously that the list item design and the handling process of multiple three layer interfaces is unified, effectively realizes multiple three layer interfaces.For some details in this method, can be with reference to the description of following network processing unit.
As shown in Figure 4, and with reference to figure 2 and Fig. 3, the embodiment of a kind of network processing unit of the present invention, the device of its network processor-based also comprise following four sub-module: as configuration module, parsing module, to search module, forwarding module.Device port includes switching port and route mouth (with reference to shown in Figure 1).Describe with reference to preceding method simultaneously.
Each module is concrete:
Configuration module: be used to be provided with inner VLAN value, the VLAN value of using himself for VLAN three layer interfaces is as inner VLAN value, for inner VLAN value of non-VLAN three layer interface applications; Set up the inside VLAN map index table of non-VLAN three layer interfaces and inner VLAN value, and the inside VLAN three layer interface attribute lists of all three layer interfaces
Particularly, if three layer interfaces of configuration are VLAN three layer interfaces, as inner VLAN value, directly three layer interface information are write in the inner VLAN three layer interface attribute lists with himself VLAN.As shown in table 2, if three layer interfaces of configuration VLAN 1 directly write three layer interface attributes in the inside VLAN three layer interface attribute lists of inner VLAN 1 correspondence.
If three layer interfaces of configuration are QinQ three layer interfaces; Then be inner VLAN values of these QinQ three layer interface applications; Port information, inner VLAN, outside VLAN with configuration are set up inner VLAN map index list item as table index; The inside VLAN value of application is write in the inner VLAN map index table, and the three layer interface attributes that will dispose simultaneously write inner VLAN three layer interface attribute lists.As shown in table 1; Dispose Q inQ three layer interfaces of inner VLAN X1, outside VLAN Y1 and be tied to port gei_1/1, then apply for inner VLAN 4K+1, with port gei_1/1, inner VLAN X1; Outside VLAN Y1 sets up inner VLAN map index list item as table index; 4K+1 is write in the table, and as shown in table 2, the three layer interface attributes that will dispose simultaneously write in the corresponding inside VLAN three layer interface attribute lists of inner VLAN 4K+1.
If three layer interfaces of configuration are the route mouths; It then is inner VLAN value of this route mouth application; Set up inner VLAN map index list item with port information, inner VLAN 0xFFF, outside VLAN 0xFFF as table index; The inside VLAN of application is write in the inner VLAN map index table, and the three layer interface attributes that will dispose simultaneously write inner VLAN three layer interface attribute lists.As shown in table 1; Configured port gei_1/2 is the route mouth, then applies for inner VLAN 4K+2, with port gei_1/2, inner VLAN 0xFFF; Outside VLAN 0xFFF sets up inner VLAN map index list item as table index; 4K+2 is write in the table, and as shown in table 2, the three layer interface attributes that will dispose simultaneously write in the corresponding inside VLAN three layer interface attribute lists of inner VLAN 4K+2.
If three layer interfaces of configuration are route mouth vlan sub-interfaces; It then is inner VLAN value of this route mouth vlan sub-interface application; Outside VLAN with port information, inner VLAN 0xFFF, configuration is set up inner VLAN map index list item as table index; The inside VLAN of application is write in the inner VLAN map index table, and the three layer interface attributes that will dispose simultaneously write inner VLAN three layer interface attribute lists.As shown in table 1; The route mouth vlan sub-interface of configuration port gei_1/2, outside VLAN Y2 is then applied for inner VLAN4K+3, with port gei_1/2, inner VLAN 0xFFF; Outside VLAN Y2 sets up inner VLAN map index list item as table index; 4K+3 is write in the table, and as shown in table 2, the three layer interface attributes that will dispose simultaneously write in the corresponding inside VLAN three layer interface attribute lists of inner VLAN 4K+3.
If three layer interfaces of configuration are route mouth QinQ sub-interfaces; It then is inner VLAN value of this route mouth QinQ sub-interface application; Inner VLAN, outside VLAN with port information, configuration are set up inner VLAN map index list item as table index; The inside VLAN of application is write in the inner VLAN map index table, and the three layer interface attributes that will dispose simultaneously write inner VLAN three layer interface attribute lists.As shown in table 1; The route mouth QinQ sub-interface of configuration port gei_1/2, inner VLAN X3, outside VLAN Y3 is then applied for inner VLAN 4K+4, with port gei_1/2, inner VLAN X3; Outside VLAN Y3 sets up inner VLAN map index list item as table index; 4K+4 is write in the table, and as shown in table 2, the three layer interface attributes that will dispose simultaneously write in the corresponding inside VLAN three layer interface attribute lists of inner VLAN 4K+4.
Parsing module: be used to resolve the message that receives, judge whether to carry out three layers of forwarding, the VLAN analysis result that simultaneously port information and message is carried is exported to and is searched module.
Particularly, if the target MAC (Media Access Control) address of message is three layer interface MAC Addresss, and message is the IPV4 message, and explanation need be walked three layers of forwarding process, otherwise goes other forwarding processes.Analytic message with vlan information, the situation that message carries VLAN has following several kinds: message is not with VLAN, message band one deck VLAN, the two-layer VLAN of message band.
Search module: be used for confirming the inside VLAN value that message is corresponding, search said inner VLAN three layer interface attribute lists, obtain three layer interface attributes, export to forwarding module according to port information and the vlan information that parses.
Concrete; For the three-tier message that gets into from switching port, if message carries one deck VLAN, with this VLAN as inner VLAN value; If message is not with VLAN; Then with the PVID of port as inner VLAN value, search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes.
For getting into from switching port and with the three-tier message of two-layer VLAN; Then needing to be with two-layer vlan information to inquire about inner VLAN map index table with port and message earlier obtains inner VLAN, inquires about inner VLAN three layer interface attribute lists with the inside VLAN that obtains again and obtain three layer interface attributes.
For the three-tier message that gets into from the route mouth; If message is not with vlan information; Just removing to inquire about inner VLAN map index table with port, inner VLAN 0xFFF, outside VLAN 0xFFF obtains inner VLAN, inquires about inner VLAN three layer interface attribute lists with the inside VLAN that obtains again and obtains three layer interface attributes; If message band one deck VLAN, with regard to port, inner VLAN 0xFFF, with outside VLAN remove to inquire about inner VLAN map index table and obtain inner VLAN, inquire about inner VLAN three layer interface attribute lists with the inside VLAN that obtains again and obtain three layer interface attributes; If the two-layer VLAN of message band, just with port, with inner VLAN, with outside VLAN remove to inquire about inner VLAN map index table and obtain inner VLAN, the inside VLAN that obtains of usefulness inquires about inner VLAN three layer interface attribute lists and obtains three layer interface attributes again.
Forwarding module: be used for carrying out three layers and handle and transmit according to the message information and the three layer interface attributes that obtain.
Need to prove that according to the regulation of 802.1Q, the VID of VLAN is 12bit altogether; VID0-VID 0xFFF represents 4096 VLAN altogether; Wherein VID 0 uses for keeping with VID 0xFFF, and VID1-VID4094 offers the user and uses, and therefore not having message carries VLAN 0xFFF; The user can not dispose the route openning interface of VLAN 0xFFF yet; Therefore when configuration route mouth, route openning interface, set up concordance list, can not overlap with user's configuration with inner VLAN 0xFFF or outside VLAN 0xFFF; When searching, search also with inner VLAN 0xFFF or outside VLAN 0xFFF and can not overlap with VLAN that normal message is with.
Above content is to combine concrete execution mode to the further explain that the present invention did, and can not assert that practical implementation of the present invention is confined to these explanations.For the those of ordinary skill of technical field under the present invention, under the prerequisite that does not break away from the present invention's design, can also make some simple deduction or replace, all should be regarded as belonging to protection scope of the present invention.

Claims (10)

1. a network processing unit is realized the method for multiple three layer interfaces, it is characterized in that, comprising:
Inner VLAN value is set, and the VLAN value of using himself for VLAN three layer interfaces is as inner VLAN value, for inner VLAN value of non-VLAN three layer interface applications;
Set up the inside VLAN map index table of non-VLAN three layer interfaces and inner VLAN value, and the inside VLAN three layer interface attribute lists of all three layer interfaces;
After receiving message,, confirm corresponding inside VLAN value, and search said inner VLAN three layer interface attribute lists in view of the above, obtain three layer interface attributes, accomplish three layers and handle and transmit the message that needs carry out three layers of forwarding.
2. the method for claim 1 is characterized in that, said inner VLAN map index table comprises: port, inner VLAN, outside VLAN are as table index, and inner VLAN value is as the table content; Said inner VLAN three layer interface attribute lists comprise: inner VLAN value is as table index, and three layer interface attributes are as the table content.
3. method according to claim 1 is characterized in that, described non-VLAN three layer interfaces comprise: QinQ three layer interfaces, route mouth, route mouth vlan sub-interface, route mouth QinQ sub-interface.
4. method according to claim 1 is characterized in that: for VLAN three layer interfaces, as inner VLAN value, the three layer interface attributes that directly will dispose write in the inner VLAN three layer interface attribute lists with himself VLAN value; For non-VLAN three layer interfaces; Be inner VLAN value of its application; Set up inner VLAN map index list item with port, inner VLAN, outside VLAN as table index; The inside VLAN value of application is write in the inner VLAN map index table, and the three layer interface attributes that will dispose simultaneously write inner VLAN three layer interface attribute lists.
5. method according to claim 1 is characterized in that, for the three-tier message that gets into from switching port; If message carries one deck VLAN, with this VLAN as inner VLAN value, if message is not with VLAN; Then with the PVID of port as inner VLAN value; Search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes, accomplish three layers and handle and transmit; For getting into from switching port and with the three-tier message of two-layer VLAN or the three-tier message that gets into from the route mouth; Search inner VLAN map index table according to port, inner VLAN, outside VLAN; Obtain inner VLAN value; Search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes, accomplish three layers and handle and transmit.
6. a network processing unit is characterized in that, comprises following four sub-module:
Configuration module is used to be provided with inner VLAN value, and the VLAN value of using himself for VLAN three layer interfaces is as inner VLAN value, for inner VLAN value of non-VLAN three layer interface applications; Set up the inside VLAN map index table of non-VLAN three layer interfaces and inner VLAN value, and the inside VLAN three layer interface attribute lists of all three layer interfaces;
Parsing module is used to resolve the message that receives, and judges whether to carry out three layers of forwarding, and the VLAN analysis result that simultaneously port information and message is carried is exported to and searched module;
Search module, be used for confirming the inside VLAN value that message is corresponding, search said inner VLAN three layer interface attribute lists, obtain three layer interface attributes, export to forwarding module according to port information and the vlan information that parses;
Forwarding module is used for carrying out three layers according to the message information and the three layer interface attributes that obtain and handles and transmit.
7. network processing unit according to claim 6 is characterized in that, the inside VLAN map index table that said configuration module is set up comprises: port, inner VLAN, outside VLAN are as table index, and inner VLAN value is as the table content; The inside VLAN three layer interface attribute lists that said configuration module is set up comprise: inner VLAN value is as table index, and three layer interface attributes are as the table content.
8. network processing unit according to claim 6 is characterized in that, described non-VLAN three layer interfaces comprise: QinQ three layer interfaces, route mouth, route mouth vlan sub-interface, route mouth QinQ sub-interface.
9. network processing unit according to claim 6; It is characterized in that said configuration module is used for: for VLAN three layer interfaces; As inner VLAN value, the three layer interface attributes that directly will dispose write in the inner VLAN three layer interface attribute lists with himself VLAN value; For non-VLAN three layer interfaces; Be inner VLAN value of its application; Set up inner VLAN map index list item with port, inner VLAN, outside VLAN as table index; The inside VLAN value of application is write in the inner VLAN map index table, and the three layer interface attributes that will dispose simultaneously write inner VLAN three layer interface attribute lists.
10. network processing unit according to claim 6 is characterized in that, the said module of searching; Be used for: confirm when handling from three-tier message that switching port gets into, if message carries one deck VLAN, with this VLAN as inner VLAN value; If message is not with VLAN; Then with the PVID of port as inner VLAN value, search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes; Confirm to get into and during handling with the three-tier message of two-layer VLAN or from three-tier message that the route mouth gets into from switching port; Search inner VLAN map index table according to port, inner VLAN, outside VLAN; Obtain inner VLAN value; Search said inner VLAN three layer interface attribute lists with this inside VLAN value, obtain three layer interface attributes.
CN201210027072.6A 2012-02-08 2012-02-08 Method for network processor to achieve various three-layer interfaces and network processor Active CN102546348B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210027072.6A CN102546348B (en) 2012-02-08 2012-02-08 Method for network processor to achieve various three-layer interfaces and network processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210027072.6A CN102546348B (en) 2012-02-08 2012-02-08 Method for network processor to achieve various three-layer interfaces and network processor

Publications (2)

Publication Number Publication Date
CN102546348A true CN102546348A (en) 2012-07-04
CN102546348B CN102546348B (en) 2015-06-03

Family

ID=46352347

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210027072.6A Active CN102546348B (en) 2012-02-08 2012-02-08 Method for network processor to achieve various three-layer interfaces and network processor

Country Status (1)

Country Link
CN (1) CN102546348B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104133919A (en) * 2014-08-22 2014-11-05 上海斐讯数据通信技术有限公司 Management information base index value and device index value converting method and converting system
WO2016138845A1 (en) * 2015-03-03 2016-09-09 中兴通讯股份有限公司 Method and device realizing upload of protocol packet to cpu
WO2016138813A1 (en) * 2015-03-05 2016-09-09 中兴通讯股份有限公司 Switch routing conflict processing method and apparatus
CN102611619B (en) * 2012-02-24 2018-03-20 中兴通讯股份有限公司 The method and routing device of a kind of forwarding data packets

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090073989A1 (en) * 2007-09-19 2009-03-19 Dezhong Cai Redundancy at a Virtual Provider Edge Node that faces a Tunneling Protocol Core Network for Virtual Private Local Area Network (LAN) Service (VPLS)
CN101820392A (en) * 2010-03-26 2010-09-01 中兴通讯股份有限公司 Method for realizing multi-service forwarding and network processor
CN101984607A (en) * 2010-11-16 2011-03-09 中兴通讯股份有限公司 Method of Ethernet interface to simultaneously support routing function and switching function
CN102158421A (en) * 2011-05-25 2011-08-17 杭州华三通信技术有限公司 Method and unit for creating layer three interface

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090073989A1 (en) * 2007-09-19 2009-03-19 Dezhong Cai Redundancy at a Virtual Provider Edge Node that faces a Tunneling Protocol Core Network for Virtual Private Local Area Network (LAN) Service (VPLS)
CN101820392A (en) * 2010-03-26 2010-09-01 中兴通讯股份有限公司 Method for realizing multi-service forwarding and network processor
CN101984607A (en) * 2010-11-16 2011-03-09 中兴通讯股份有限公司 Method of Ethernet interface to simultaneously support routing function and switching function
CN102158421A (en) * 2011-05-25 2011-08-17 杭州华三通信技术有限公司 Method and unit for creating layer three interface

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102611619B (en) * 2012-02-24 2018-03-20 中兴通讯股份有限公司 The method and routing device of a kind of forwarding data packets
CN104133919A (en) * 2014-08-22 2014-11-05 上海斐讯数据通信技术有限公司 Management information base index value and device index value converting method and converting system
WO2016138845A1 (en) * 2015-03-03 2016-09-09 中兴通讯股份有限公司 Method and device realizing upload of protocol packet to cpu
CN105991391A (en) * 2015-03-03 2016-10-05 中兴通讯股份有限公司 Method and device for uploading protocol message to CPU
WO2016138813A1 (en) * 2015-03-05 2016-09-09 中兴通讯股份有限公司 Switch routing conflict processing method and apparatus

Also Published As

Publication number Publication date
CN102546348B (en) 2015-06-03

Similar Documents

Publication Publication Date Title
CN101820392B (en) A kind of method and network processing unit realizing multi-service forwarding
WO2014032598A1 (en) Forward packet with edge device
CN102611634A (en) IP (Internet protocol) network access method and edge device
EP3292659B1 (en) Multicast data packet forwarding
CN109218301A (en) The method and apparatus of the frame head mapping of software definition between multi-protocols
CN104158718A (en) A message processing method and device
CN102377669B (en) Method for sending message and switch
CN102611619B (en) The method and routing device of a kind of forwarding data packets
CN105635332A (en) Method for multiple virtual machines to share IP of single external network
CN105515992A (en) Method and device for processing flow table items of VXLAN network
CN102546348A (en) Method for network processor to achieve various three-layer interfaces and network processor
EP3292663B1 (en) Packet forwarding
US10862850B2 (en) Network-address-to-identifier translation in virtualized computing environments
CN106027396B (en) A kind of route control method, device and system
CN105657078A (en) Data transmission method, data transmission device and multi-layer network manager
CN105991391A (en) Method and device for uploading protocol message to CPU
CN106034075B (en) Method and device for distributing label for VPN route
CN102447669A (en) Forwarding method of multimedia data streams and forwarding equipment
CN101834804B (en) Method and device for realizing speed limit for traffic of virtual private networks (VPN)
WO2016173196A1 (en) Method and apparatus for learning address mapping relationship
CN100479457C (en) Implementation method for transferring data in virtual private network
WO2016138813A1 (en) Switch routing conflict processing method and apparatus
US20130077530A1 (en) Scaling IPv6 on Multiple Devices Virtual Switching System with Port or Device Level Aggregation
CN116016448A (en) Service network access method, device, equipment and storage medium
CN105282055A (en) Method of identifying internal destinations of network packets and an apparatus thereof

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant