CN1984025B - Method for releasing invalid-occupied resource and storage converter - Google Patents

Method for releasing invalid-occupied resource and storage converter Download PDF

Info

Publication number
CN1984025B
CN1984025B CN2006100783810A CN200610078381A CN1984025B CN 1984025 B CN1984025 B CN 1984025B CN 2006100783810 A CN2006100783810 A CN 2006100783810A CN 200610078381 A CN200610078381 A CN 200610078381A CN 1984025 B CN1984025 B CN 1984025B
Authority
CN
China
Prior art keywords
output port
timer
send
data
message
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.)
Expired - Fee Related
Application number
CN2006100783810A
Other languages
Chinese (zh)
Other versions
CN1984025A (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.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN2006100783810A priority Critical patent/CN1984025B/en
Publication of CN1984025A publication Critical patent/CN1984025A/en
Application granted granted Critical
Publication of CN1984025B publication Critical patent/CN1984025B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Computer And Data Communications (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

This invention relates to the method and store - and-forward device which can release void occupation resource. The core is: when detect there is no data message sent on the output end, it will start the timer which is set on the corresponding output end to record time; when the record time of the timer reaches regular cycle, it will release void occupation resource. Through this invention, when the work of output end is abnormal, it will not only release the allocation of resource timely, and it needn't the CPU participation and software running.

Description

Release is disabled the method and the storing and forwarding device of the resource that takies
Technical field
The present invention relates to the communications field, relate in particular to the storage retransmission technique.
Background technology
In the chip of data communication, use the structure of " storage-forwarding " as shown in Figure 1 usually, this structure comprises cache module, the forwarding processing module of receiving management module, message data and sends administration module.Said receiving management module comprises at least one receiving port, and said transmission administration module comprises at least one output port, and the output queue of corresponding said output port.
When carrying out data communication; Said receiving management module intactly receives message data through each receiving port; To the corresponding cache resources of message data cache module application,, then the message data that receives is discarded then if can not apply for corresponding cache resources; If can apply for corresponding cache resources; Then said receiving management module can obtain to store the memory address of the message data that receives; And according to said memory address with the storage that receives in the message data cache module; Simultaneously the partial content of said memory address and message data (comprise " destination address " information of being positioned at the message data head with " source address " information etc.) as the forwarding process information, is sent to said forwarding processing module; Said forwarding processing module is carried out analyzing and processing to transmitting process information, and confirms to comprise the forwarding information of message data whether message data need abandon, or be forwarded to which output port etc. according to analysis result.After said forwarding processing module draws the forwarding information of message data, will be written in the output queue of each output port corresponding " first in first out " according to the said forwarding information storage address information that message data is corresponding, wait to be sent then.Said transmission administration module reads the address information in the output queue according to the situation of output port dateout; And from the message data cache module, reading the message data of corresponding said address according to said address information, the output port through correspondence sends then.
After message data was exported from output port, said chip discharged by said message data shared cache resources and queue resource.
In the said process, when chip carried out analyzing and processing to the forwarding process information of current data message, receiving port may receive some data messages of follow-up arrival, and this moment, chip must distribute some cache resources to come message data is stored; Yet these storage resources and queue resource will be waited until just can be recovered after message data sends from output port once more and utilize.In addition; Carry out in the process of work at chip; The situation that occurs the unexpected link down of some output port sometimes, for example netting twine breaks off, power failure, user do not have the network equipment of stop butt joint according to the rules etc. suddenly, in chip, have had some buffer memorys or queue resource to distribute to this output port this moment; If it is normal that these ports can not in time recover; These buffer memorys that have been assigned with or queue resource will be taken for a long time so, can not be utilized by other port again, thereby the performance of chip is impacted.Therefore need often to detect the operating state of output port,, and when link down, can in time discharge the buffer memory or the queue resource that have been assigned with so that in time judge the connection status of link.
The prior art one relevant with the present invention provides the buffer memory that a kind of release has been assigned with or the method for queue resource, and its main thought is:
Send administration module and check that constantly the circuit on the output port connects signal, promptly the Link signal is known the connection status of the link of output port, and detected information is initiatively reported CPU; After said CPU is known output port generation link down according to the said information that reports; Controlling said transmission administration module constantly will send to this output port from corresponding formation, buffer memory data message abandons; The link-recovery that learns output port until said CPU connects; Then stop this discard processing, recover normal data message and send.
Prior art one needs CPU to handle, thereby can increase the burden of CPU.
The prior art two relevant with the present invention provides the buffer memory that another kind of release has been assigned with or the method for queue resource, and its main thought is:
Check periodically, constantly that through high layer software whether output port is sending data (the particularly data message of some protocol types), and judge according to detected information whether link is online always; After being checked through output port generation link down, the data message that constantly from corresponding formation, buffer memory, will send to this output port abandons, thereby realizes the recovery of occupied resource.Connect in case reexamine the link-recovery of port, then stop this discard processing, recover normal data message and send.
Prior art two needs high layer software to handle, and can cause the running software expense, has increased the burden of the CPU of operating software.
Summary of the invention
The purpose of this invention is to provide method and storing and forwarding device that a kind of release is disabled the resource that takies; Through the present invention; Solved in the prior art when the output port operation irregularity; For realizing the recovery of occupied resource, need the participation of CPU, maybe need move high layer software and drawback such as handle.
The objective of the invention is to realize through following technical scheme:
The present invention provides a kind of release to be disabled the method for the resource that takies, and it comprises:
A, when on detecting output port, not having data message to send, then start corresponding said output port and the timer that is provided with picks up counting;
B, when the timing time of said timer reaches timing cycle, discharge and to be disabled the data resource that takies.
Needed time when each data message sent when wherein, the timing cycle of said timer was greater than normal output.
Wherein, said steps A specifically comprises:
Send administration module and detect and whether have data message to send on each output port that sets within it, and when when detecting a certain output port on, not having the data message transmission, then start corresponding said output port and the timer that is provided with picks up counting;
Or,
Send administration module and detect to be arranged on its each outside output port and whether have data message to send, and when when detecting a certain output port on, not having the data message transmission, then corresponding said output port and the timer that is provided with picks up counting.
Wherein, specifically comprise at said step B:
B1, before the timing time no show timing cycle of said timer; Whether continue to detect on the said output port has data message normally to send; And when on detecting said output port, having data message to send; Then said timer is resetted, and stop timing, continue steps A then; When on detecting said output port, not having data message to send, execution in step B2 then;
B2, when the timing of said timer reaches timing cycle; Then read the memory address in the corresponding output queue of said output port; And from the message data cache module, read the message data of corresponding said memory address according to said memory address; Then it is discarded, and discharge said memory address corresponding queues resource and said message data corresponding cache resource; Simultaneously said timer is resetted, change steps A then over to.
The present invention provides a kind of storing and forwarding device; Comprise at least one output port, wherein, corresponding each output port also comprises a timer; Be used for when output port does not have data message to send; Then startup picks up counting, and when timing time reaches timing cycle, then triggers said storing and forwarding device release and be disabled the data resource that takies.
Needed time when each data message sent when wherein, the timing cycle of said timer was greater than normal output.
Wherein, said timer is positioned at output port inside, or is positioned at the outside of output port.
Wherein, described storing and forwarding device also comprises:
Sending administration module, whether have data message send, when not having data message to send, send the said timer of signal triggering if being used to detect said output port; And when the timing time of timer arrived timing cycle, release was disabled the data resource that takies.
Wherein, the said data resource that takies that is disabled comprises:
Queue resource in the output queue of having distributed to output port but can not in the timing cycle of timer, being sent out; Message resource with correspondence buffer memory in the message data cache module.
Wherein, it is inner that said output port is positioned at said transmission administration module, or it is outside to be positioned at said transmission administration module, and be connected with said transmission administration module.
Technical scheme by the invention described above provides can find out, among the present invention, when on detecting certain output port, not having data message to send, starts corresponding said output port and the timer that is provided with picks up counting; And when the timing time of said timer reached timing cycle, release was disabled the resource that takies.Therefore when the output port operation irregularity, the present invention not only can in time discharge the resource that has been assigned with, and does not need the participation of CPU, does not need the operation of software.
Description of drawings
Fig. 1 is the fundamental diagram of the chip of " storage-forwarding " structure of providing in the background technology;
Fig. 2 is the flow chart of first embodiment provided by the invention;
Fig. 3 is the schematic diagram of second embodiment provided by the invention;
Fig. 4 is for to send administration module outside when output port is arranged among the 3rd embodiment provided by the invention, and each timer is arranged on and sends in the administration module, and with the schematic diagram of each output port to seasonable storing and forwarding device.
Embodiment
Data communication chip to " storage-forwarding " structure; When it occurs the situation that some output port generation link interrupts suddenly (for example netting twine breaks off, has a power failure suddenly, user not program off-line etc. according to the rules) in the course of the work; Had some cache resources or queue resource to distribute to this output port this moment in chip; These resources are called as and are disabled the resource that takies, if these resources are discharged timely, Limited resources are fully utilized; Be not disabled the resource that takies if there is the participation of participation or the high layer software of CPU just can in time discharge, then even more ideal.
The invention provides first embodiment is not need the participation of CPU participation or high layer software just can in time discharge a kind of method that is disabled the resource that takies; Its core is: corresponding each output port is provided with a timer; When said transmission administration module detects when not having data message to send on certain output port, the timer that then starts on the corresponding said output port picks up counting.When the timing time of said timer reached timing cycle, then said transmission administration module discharged the resource of ineffective occupation.Its practical implementation process is as shown in Figure 2, comprises the steps:
Step 1, corresponding each output port is provided with a timer, and the timing cycle of setting said timer needed time when each data message sends during greater than normal output.
When said timer does not only have data message to send on the output port of correspondence, just pick up counting, when having data message normally to export on the output port of correspondence, then said timer is in reset mode, can not carry out timing and handle.
The timing cycle of said timer can be provided with different numerical, to adapt to the different working situation.
Step 2; Send administration module and detect and whether have data message to send on each output port, and when when detecting a certain output port on, not having the data message transmission, then execution in step 3; Promptly start the timer that is arranged on the said output port and pick up counting, execution in step 5 then; When detecting each output port and all have data message to send, then execution in step 4, are about to said timer and place reset mode, continue step 2 then.
Step 5; Whether before the timing time no show timing cycle of said timer, continue detecting on the said output port has data message normally to send, when said transmission administration module detects when having data message to send on the said output port; Then execution in step 6; Be about to said timer and reset, and stop timing, continue step 2 then; When on detecting said output port, not having data message to send, then execution in step 7.
Step 7; When the timing of said timer reaches timing cycle; Then said transmission administration module reads the storage address information in the output queue corresponding with said output port; And from the message data cache module, read the message data of corresponding said memory address according to said storage address information, and then it is discarded, discharge said storage address information corresponding queues resource and said message data corresponding cache resource.Simultaneously said timer is resetted, change step 2 then over to.
In case the link of output port interrupts, then will can not send data on the output port for a long time and protect literary composition, the timer on the at this moment said output port can reach the predetermined timing cycle.
Second embodiment provided by the invention is a kind of storing and forwarding device, and its operation principle is as shown in Figure 3, comprising:
Receiving management module, message data cache module, forwarding processing module and transmission administration module; Wherein said receiving management module comprises at least one receiving port, and said transmission administration module comprises the output queue of at least one output port, corresponding said output port and is arranged on the timer on each output port; The timing cycle of said timer needed time when each data message sends during greater than normal output.
When carrying out data communication; Said receiving management module intactly receives message data through said each receiving port; Then to the corresponding cache resources of said message data cache module application; If can not apply for corresponding cache resources, then the message data that receives is discarded; If can apply for corresponding cache resources; Then said receiving management module can obtain to store the memory address of the message data that receives; And according to said memory address with the storage that receives in said message data cache module; Simultaneously the partial content information in said memory address and the message data (comprise " destination address " information of being positioned at the message data head with " source address " information etc.) as the forwarding process information, is sent to said forwarding processing module.
Said forwarding processing module is carried out analyzing and processing to transmitting process information, and confirms to comprise the forwarding information of message data whether message data need abandon, or be forwarded to which output port etc. according to analysis result.After the forwarding processing module draws the forwarding information of message data; To be written in the output queue of " first in first out " of output port of the correspondence in the said transmission administration module according to the said forwarding information memory address that message data is corresponding, wait to be sent then.
Whether said transmission administration module detects has data message to send on the said output port; When on detecting said output port, having data message normally to send; Then constantly read the memory address in the corresponding output queue of said output port; And from the message data cache module, read the message data of corresponding said memory address according to said memory address, send through said output port then.
When said transmission administration module detects when not having data message to send on the said output port, then start the timer that is arranged on the said output port and pick up counting; If before the timing time no show timing cycle of said timer, and said transmission administration module detects when having data message to send on the said output port, and then said transmission administration module resets said timer, and stops timing.If before the timing time of said timer arrives timing cycle; All the time there is not data message on said output port, to send; Then the timing of said timer can reach timing cycle; Said timer can trigger said transmission administration module release and be disabled the resource that takies at this moment: that is to say that said transmission administration module then reads the memory address in the corresponding output queue of said output port, and from the message data cache module, read the message data of corresponding said memory address according to said memory address; Then it is discarded, and discharge said memory address corresponding queues resource and said message data corresponding cache resource.Subsequently said timer is resetted, restart timing, go round and begin again like this, when the timing time of said timer reaches its timing cycle, then abandon a data message, and discharge corresponding buffer memory and queue resource.When said transmission administration module detects when having data message to send on the said port, just stop to abandon.
In the foregoing description, said timer also can not be arranged on each output port, and is independent of each output port and is arranged on and sends in the administration module, but this moment, said each timer still needed corresponding each output port.
The 3rd embodiment provided by the invention is another kind of storing and forwarding device, and the difference of itself and second embodiment is, said output port is arranged on that to send administration module outside, and is connected with said transmission administration module.Each timer can be arranged on and send in the administration module this moment, and corresponding with each output port; Each timer also can be arranged on each corresponding output port.The output port that provided as shown in Figure 4 is arranged on that to send administration module outside, and each timer is arranged on and sends in the administration module, and with the schematic diagram of each output port to seasonable storing and forwarding device.
The information exchanging process among the 3rd embodiment between each module and timer and second embodiment are similar basically, are not described in detail here.
Specific embodiments by the invention described above can find out, when on detecting certain output port, not having data message to send among the present invention, starts corresponding said output port and the timer that is provided with picks up counting; And when the timing time of said timer reached timing cycle, release was disabled the resource that takies.Therefore when the output port operation irregularity, the present invention not only can in time discharge the resource that has been assigned with, and does not need the participation of CPU, does not need the operation of software.
The above; Be merely the preferable embodiment of the present invention, but protection scope of the present invention is not limited thereto, any technical staff who is familiar with the present technique field is in the technical scope that the present invention discloses; The variation that can expect easily or replacement all should be encompassed within protection scope of the present invention.Therefore, protection scope of the present invention should be as the criterion with the protection range of claim.

Claims (7)

1. a release is disabled the method for the resource that takies, and it is characterized in that, comprising:
A, when on detecting output port, not having data message to send, then start corresponding said output port and the timer that is provided with picks up counting;
B, when the timing time of said timer reaches timing cycle, discharge and to be disabled the data resource that takies;
Wherein, said step B comprises:
B1, before the timing time no show timing cycle of said timer; Whether continue to detect on the said output port has data message normally to send; And when on detecting said output port, having data message to send; Then said timer is resetted, and stop timing, continue steps A then; When on detecting said output port, not having data message to send, execution in step B2 then;
B2, when the timing of said timer reaches timing cycle; Then read the memory address in the corresponding output queue of said output port; And from the message data cache module, read the message data of corresponding said memory address according to said memory address; Then it is discarded, and discharge said memory address corresponding queues resource and said message data corresponding cache resource; Simultaneously said timer is resetted, change steps A then over to.
2. method according to claim 1 is characterized in that:
The timing cycle of said timer needed time when each data message sends during greater than normal output.
3. method according to claim 1 and 2 is characterized in that, said steps A specifically comprises:
Send administration module and detect and whether have data message to send on each output port that sets within it, and when when detecting a certain output port on, not having the data message transmission, then start corresponding said output port and the timer that is provided with picks up counting;
Or,
Send administration module and detect to be arranged on its each outside output port and whether have data message to send, and when when detecting a certain output port on, not having the data message transmission, then corresponding said output port and the timer that is provided with picks up counting.
4. storing and forwarding device; Comprise at least one output port, it is characterized in that corresponding each output port also comprises a timer; Be used for when output port does not have data message to send; Then startup picks up counting, and when timing time reaches timing cycle, then triggers said storing and forwarding device release and be disabled the data resource that takies;
Also comprise: sending administration module, whether have data message send, when not having data message to send, send the said timer of signal triggering if being used to detect said output port; And when the timing time of timer arrives timing cycle, discharge the queue resource in the output queue of having distributed to output port but can not in the timing cycle of timer, being sent out, and the message resource of correspondence buffer memory in the message data cache module.
5. storing and forwarding device according to claim 4 is characterized in that:
The timing cycle of said timer needed time when each data message sends during greater than normal output.
6. storing and forwarding device according to claim 4 is characterized in that:
Said timer is positioned at output port inside, or is positioned at the outside of output port.
7. storing and forwarding device according to claim 4 is characterized in that:
It is inner that said output port is positioned at said transmission administration module, or it is outside to be positioned at said transmission administration module, and be connected with said transmission administration module.
CN2006100783810A 2006-05-17 2006-05-17 Method for releasing invalid-occupied resource and storage converter Expired - Fee Related CN1984025B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2006100783810A CN1984025B (en) 2006-05-17 2006-05-17 Method for releasing invalid-occupied resource and storage converter

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2006100783810A CN1984025B (en) 2006-05-17 2006-05-17 Method for releasing invalid-occupied resource and storage converter

Publications (2)

Publication Number Publication Date
CN1984025A CN1984025A (en) 2007-06-20
CN1984025B true CN1984025B (en) 2012-05-30

Family

ID=38166273

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2006100783810A Expired - Fee Related CN1984025B (en) 2006-05-17 2006-05-17 Method for releasing invalid-occupied resource and storage converter

Country Status (1)

Country Link
CN (1) CN1984025B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101699795B (en) * 2009-10-29 2012-07-18 中兴通讯股份有限公司 Message congestion processing method and system
CN102137293B (en) * 2010-12-31 2015-01-21 华为技术有限公司 Resource allocation method, user business terminal and head end system of streaming media service
CN103077152B (en) * 2012-12-25 2015-09-30 北京四方继保自动化股份有限公司 A kind of communication acceleration method for terminal equipment of intelligent substation chip chamber
CN104461924A (en) * 2014-11-04 2015-03-25 福建星网锐捷网络有限公司 Collection method and system for message memories
CN107634914B (en) * 2016-07-18 2021-01-22 深圳市中兴微电子技术有限公司 Frame stream control method and device
CN110297732B (en) * 2019-06-14 2024-01-23 杭州迪普科技股份有限公司 FPGA state detection method and device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1391771A (en) * 1999-09-17 2003-01-15 艾利森电话股份有限公司 Channel allocation and release for packet data services
CN1708141A (en) * 2004-06-08 2005-12-14 华为技术有限公司 Method for realeasing terminal resource in media gateway

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1391771A (en) * 1999-09-17 2003-01-15 艾利森电话股份有限公司 Channel allocation and release for packet data services
CN1708141A (en) * 2004-06-08 2005-12-14 华为技术有限公司 Method for realeasing terminal resource in media gateway

Also Published As

Publication number Publication date
CN1984025A (en) 2007-06-20

Similar Documents

Publication Publication Date Title
CN1984025B (en) Method for releasing invalid-occupied resource and storage converter
US20180316607A1 (en) Providing non-interrupt failover using a link aggregation mechanism
JP3649580B2 (en) A system for reporting errors in a distributed computer system.
CN103684835B (en) Link fault reporting method and processing method, and transmission node and primary node
US7876769B2 (en) Self-cleaning mechanism for error recovery
US20140050078A1 (en) Communication interruption time reduction method in a packet communication network
CN107508640B (en) Double-ring redundant self-healing optical fiber network construction method based on optical fiber channel technology
CN101729231B (en) Industrial Ethernet in distributed control system
CN101227319B (en) Redundancy switching method
CN102415056A (en) Pon system, station-end apparatus and subscriber-end apparatus
CN1777137A (en) Data translation device and system based on ethernet and serial communication technology
JP4729117B2 (en) Edge switch and forwarding table rewriting method
US20090006650A1 (en) Communication device, communication method, communication interface, and program product
CN103442035A (en) Method for achieving dual-network hot standby redundancy of blank pipe automatic system
JP2000083053A (en) Program including system packet processor
US20090213745A1 (en) Frame monitoring device and frame monitoring method
JP2915939B2 (en) Real-time message exchange system
CN101159494A (en) Service protecting method for automatic exchange optical network
CN101924694A (en) Mail server system and congestion control method
CN101951327B (en) iSCSI network system and network fault detection method
RU2383067C2 (en) Method of storing data packets using pointer technique
US7457238B2 (en) Transmission system with congestion state-based flow control
CN101848165B (en) The method recovered after controlling interrupted communication link and interface board
JPWO2009144824A1 (en) Information processing apparatus, transfer circuit, and error control method for information processing apparatus
CN102752159A (en) Link connectivity detection method and equipment

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
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20120530

Termination date: 20170517

CF01 Termination of patent right due to non-payment of annual fee