CN107357746B - Communication method and system - Google Patents

Communication method and system Download PDF

Info

Publication number
CN107357746B
CN107357746B CN201710618266.6A CN201710618266A CN107357746B CN 107357746 B CN107357746 B CN 107357746B CN 201710618266 A CN201710618266 A CN 201710618266A CN 107357746 B CN107357746 B CN 107357746B
Authority
CN
China
Prior art keywords
remote
local
data
local system
remote system
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.)
Active
Application number
CN201710618266.6A
Other languages
Chinese (zh)
Other versions
CN107357746A (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.)
Zhengzhou Yunhai Information Technology Co Ltd
Original Assignee
Zhengzhou Yunhai Information Technology 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 Zhengzhou Yunhai Information Technology Co Ltd filed Critical Zhengzhou Yunhai Information Technology Co Ltd
Priority to CN201710618266.6A priority Critical patent/CN107357746B/en
Publication of CN107357746A publication Critical patent/CN107357746A/en
Application granted granted Critical
Publication of CN107357746B publication Critical patent/CN107357746B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/14Handling requests for interconnection or transfer
    • G06F13/36Handling requests for interconnection or transfer for access to common bus or bus system
    • G06F13/368Handling requests for interconnection or transfer for access to common bus or bus system with decentralised access control

Abstract

The invention discloses a communication method and a system, wherein the method comprises the following steps: the local system sends data to the remote system and updates the message counting index corresponding to the data in the remote system; and the remote system inquires the message counting index in real time or at regular time and judges whether the message counting index is updated or not, and if so, the remote system receives the data sent by the local system. According to the communication method provided by the invention, the local system sends data to the remote system and updates the message count index corresponding to the data in the remote system, the remote system inquires the message count index of the remote system in real time or at regular time and receives the data sent by the local system under the condition of judging that the message count index is updated, so that the condition that the Doorbell interrupts a register to cause system hang is avoided. The communication method provided by the invention solves the technical problem of how to avoid system hang caused by triggering the Doorbell interrupt register.

Description

Communication method and system
Technical Field
The present invention relates to the field of communications technologies, and in particular, to a communication method and system.
Background
A Non-Transparent-Bridge (NTB) is a point-to-point PCI-E bus that connects two systems. The NTB provides one or more read/write windows to the local system, and the read/write operations of the local system to these windows are mapped to the memory of the remote system.
An existing NTB-based communication method includes the following steps:
the local system sends data to be transmitted to the remote system to a local memory mapping window;
the local memory mapping window carries out address translation on the received data and sends the translated data to a memory space corresponding to a remote system;
the local system sends a message to a DoorBell interrupt register of the remote system to trigger the remote system interrupt;
and after receiving the interrupt message, the remote system receives data from the specified area of the memory space of the remote system, thereby completing the data transmission.
However, when the DoorBell interrupt register is used, occasionally, the DoorBell interrupt register causes a system hang (crash), which causes a dual-control storage system to crash and customer service to be interrupted.
In summary, how to avoid the situation that triggering the DoorBell interrupt register causes the system hang-up is a problem to be urgently solved by those skilled in the art at present.
Disclosure of Invention
The invention aims to provide a communication method which can solve the technical problem of how to avoid system hang caused by triggering a Doorbell interrupt register. The invention also provides a communication system.
In order to achieve the above purpose, the invention provides the following technical scheme:
a method of communication, comprising:
a local system sends data to a remote system and updates a message counting index corresponding to the data in the remote system;
and the remote system inquires the message counting index in real time or at regular time and judges whether the message counting index is updated or not, and if so, the data is received.
Preferably, before the local system updates the message count index corresponding to the data in the remote system, the method further includes:
the local system writes a message count index corresponding to the data to the ScrachPad register of the remote system.
Preferably, before the local system updates the message count index corresponding to the data in the remote system, the method further includes:
and the local system writes the message count index corresponding to the data into the memory space of the remote system.
Preferably, the updating, by the local system, the message count index corresponding to the data in the remote system includes:
the local system adds 1 to the index value of the message count index corresponding to the data in the remote system;
the remote system determining whether the message count index is updated comprises:
and the remote system judges whether the index value of the current message counting index is larger than the last index value of the message counting index.
Preferably, before the local system sends data to the remote system, the method further includes:
the local system establishes a communication link for data transmission with the remote system.
Preferably, the establishing, by the local system, a communication link for data transmission with the remote system includes:
the local system and the remote system initialize respective registers to realize the establishment of a communication link, and the local system marks the self state as the register initialization state;
the local system and the remote system respectively store the corresponding data information, the local system modifies the self state from the register initialization state to the initial state, and the data information of the local system comprises: local feature information including a local workspace address and first critical data including a remote system register address, the data information of the remote system including: remote characteristic information comprising a remote workspace address and second critical data comprising a local system register address;
the local system establishes an initial link for data transmission with the remote system, and modifies the self state from an initial state to an initial link establishment state;
the local system writes the local characteristic information into a ScachPad register of the remote system based on the initial link and the first key data, and the local system modifies the self state from the initial link establishment state to a remote characteristic information waiting state;
after the remote system checks the information written by the local system in the ScrachPad register of the remote system, the remote characteristic information is written into the ScrachPad register of the local system based on the initial link and the second key data; after checking information written by a remote system in a ScrachPad register of the local system, the local system sends test data to the remote system based on the initial link and the remote characteristic information, and the local system changes the state of the local system from a state of waiting for the remote characteristic information to a state of waiting for the test data;
the remote system receives test data sent by a local system and then sends the received test data to the local system based on the initial link and the local characteristic information, and the local system modifies the self state from a test data waiting state to a test data transmission completion state;
the local system receives the test data sent by the remote system and judges whether the test data sent by the local system is consistent with the test data sent by the remote system, if so, the local system modifies the self state from the test data transmission completion state to a communication link establishment state, and the establishment of the communication link with the remote system is realized.
Preferably, the establishing, by the local system, a communication link for data transmission with the remote system includes:
the local system establishes an NTB communication link for data transmission with the remote system.
The invention also provides a communication system, which comprises a local system and a remote system;
the local system is used for sending data to the remote system and updating a message counting index corresponding to the data in the remote system;
and the remote system is used for inquiring the message counting index in real time or at regular time and judging whether the message counting index is updated or not, and if so, receiving the data.
Preferably, the local system is further configured to write the message count index corresponding to the data into the ScrachPad register of the remote system before updating the message count index corresponding to the data in the remote system.
Preferably, the local system is further configured to write the message count index corresponding to the data into a memory space of the remote system before updating the message count index corresponding to the data in the remote system.
The communication method provided by the invention comprises the following steps: the local system sends data to the remote system and updates the message counting index corresponding to the data in the remote system; and the remote system inquires the message counting index in real time or at regular time and judges whether the message counting index is updated or not, and if so, the data is received. The invention provides a communication method, a local system sends data to a remote system and updates a message counting index corresponding to the data in the remote system, the remote system inquires the message counting index of the local system in real time or at regular time and judges whether the message counting index is updated, if yes, the local system sends the data; the remote system receives the data sent by the local system under the condition of polling and judging that the message count index is updated, so that the remote system can receive the data without triggering a Doorbell interrupt register of the remote system by the local system, and the condition that the system hang is caused by triggering the Doorbell interrupt register is avoided. In summary, the communication method provided by the present invention solves the technical problem of how to avoid system hang caused by triggering the DoorBell interrupt register. The communication system provided by the invention also solves the corresponding technical problem.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a communication method according to an embodiment of the present invention;
fig. 2 is a flowchart illustrating a local system establishing a communication link for data transmission with a remote system according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of a communication system according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1, fig. 1 is a flowchart of a communication method according to an embodiment of the present invention.
The communication method provided by the embodiment of the invention can comprise the following steps:
step S11: the local system sends data to the remote system and updates the message count index corresponding to the data in the remote system.
Since the remote system is to receive the data transmitted by the local system, the local system is required to transmit the data to the remote system first. The message count index is a flag used to mark that the local system has sent data to the remote system, and the local system updates the message count index to indicate that the local system has sent data to the remote system.
The local system may update the message count index corresponding to the data in the remote system when the local system starts to send the data, or update the message count index corresponding to the data in the remote system after the data is sent, or certainly there may be a sequence in which other local systems send the data and the local system updates the message count index, for example, the local system updates the message count index in the process of sending the data, and the present invention is not limited specifically here.
Step S12: and the remote system inquires the message counting index in real time or at regular time and judges whether the message counting index is updated or not, and if so, the data is received.
Since the local system indicates that the local system transmits data to the remote system by updating the message count index, the remote system can determine whether the local system transmits data to the remote system by querying and determining whether the message count index is updated, if the message count index is updated, the local system transmits data to the remote system, and if the message count index is not updated, the local system does not transmit data to the remote system.
And the remote system inquires the message count index by inquiring, judges whether the message count index is updated by the local system, receives data sent by the local system if the message count index is updated by the local system, and continues to inquire the message count index if the message count index is updated by the local system.
In practical application, the remote system can inquire the message count index in real time, so that the remote system can know that the local system updates the message count index in the shortest time and can receive data in advance, and the time interval between the local system sending the data and the remote system receiving the data is shortened; the message count index may also be periodically queried according to a preset time interval, and since the message count index does not need to be queried in real time by the remote system, the service pressure of the remote system may be reduced, which is not specifically limited herein.
The communication method provided by the invention comprises the following steps: the local system sends data to the remote system and updates the message counting index corresponding to the data in the remote system; and the remote system inquires the message counting index in real time or at regular time and judges whether the message counting index is updated or not, and if so, the data is received. The invention provides a communication method, a local system sends data to a remote system and updates a message counting index corresponding to the data in the remote system, the remote system inquires the message counting index of the local system in real time or at regular time and judges whether the message counting index is updated, if yes, the local system sends the data; the remote system receives the data sent by the local system under the condition of polling and judging that the message count index is updated, so that the remote system can receive the data sent by the local system without triggering a Doorbell interrupt register of the remote system by the local system, and the condition that the system hang is caused by triggering the Doorbell interrupt register is avoided. In summary, the communication method provided by the present invention solves the technical problem of how to avoid system hang caused by triggering the DoorBell interrupt register.
In a communication method provided in an embodiment of the present invention, before the local system updates a message count index corresponding to data in the remote system, the method may further include:
the local system writes the message count index corresponding to the data to the ScrachPad register of the remote system.
In practical application, under the condition that the message count index corresponding to the data is less, the local system can write the message count index into the ScrachPad register of the remote system, so that the remote system only needs to query the message count index in the ScrachPad register, and the time for retrieving and querying the message count index by the remote system can be shortened and the efficiency is improved because the space of the ScrachPad register is smaller.
In a communication method provided in an embodiment of the present invention, before the local system updates a message count index corresponding to data in the remote system, the method may further include:
and the local system writes the message count index corresponding to the data into the memory space of the remote system.
In practical application, under the condition that the message count index corresponding to the data occupies a larger memory, the local system can select to write the message count index into the memory space of the remote system, so that the remote system can accommodate more message count indexes.
In practical application, the local system may write the message count index into a memory space of the remote system in the form of a structure, where the structure refers to a set of message count indexes, so that the remote system may conveniently query the message count index, and certainly there may be other methods for the local system to write the message count index into the remote system, which is not limited in this disclosure.
In a communication method provided in an embodiment of the present invention, updating, by a local system, a message count index corresponding to data in a remote system may include:
the local system adds 1 to the index value of the message count index corresponding to the data in the remote system;
the determining, by the remote system, whether the message count index is updated may comprise:
the remote system determines whether the index value of the current message count index is greater than the last index value of the message count index.
In practical application, when the local system updates the message count index corresponding to the data in the remote system, the local system may choose to add 1 to the index value of the message count index, and correspondingly, the remote system may determine whether the message count index is updated by determining whether the index value of the current message count index is greater than the last index value of the message count index, if the index value of the current message count index is greater than the last index value of the message count index, the message count index is updated, and if the index value of the current message count index is not greater than the last index value of the message count index, the message count index is not updated. Therefore, the process of updating the message index by the local system and judging whether the message count index is updated by the remote system is simple and easy to implement, and certainly, other methods for updating the message count index and judging whether the message count index is updated can be provided, and the invention is not particularly limited herein. The remote system may further determine the number of times the last message count index of the current message count index was updated by determining that the index value of the current message count index is greater than the last index value of the message count index, for example, if the index value of the current message count index is greater than the last index value of the message count index by 3, it indicates that the last message count index of the current message count index was updated by 3 times.
In the communication method provided in the embodiment of the present invention, before the local system sends data to the remote system, the method may further include:
the local system establishes a communication link for data transmission with the remote system.
In practical applications, for a local system and a remote system that do not establish a communication link for data transmission, the local system needs to establish a communication link for data transmission with the remote system to implement data transmission between the local system and the remote system.
Referring to fig. 2, fig. 2 is a flowchart illustrating a local system establishing a communication link for data transmission with a remote system according to an embodiment of the present invention.
In a communication method provided in an embodiment of the present invention, establishing, by a local system, a communication link for data transmission with a remote system may include:
step S21: the local system and the remote system initialize respective registers to realize the establishment of the communication link, and the local system marks the self state as the register initialization state.
In practical application, before a communication link is established, the local system and the remote system are required to initialize respective registers according to requirements, and then the local system can mark the self state as the register initialization state. At the beginning of system startup, the register is not initialized as required, at this time, the local system can mark its own state as uninitialized state, and after the local system and remote system initialize their own registers, the local system can change its own state from uninitialized state to register initialized state.
Step S22: the local system and the remote system respectively store the corresponding data information, the local system modifies the self state from the register initialization state to the initial state, and the data information of the local system comprises: the data information of the remote system comprises local characteristic information comprising a local working space address and first key data comprising a remote system register address: remote characteristic information including a remote workspace address and second critical data including a local system register address.
The local system stores the remote system register address to facilitate writing of data to the remote system register by the local system based on the stored remote system register address.
In practical applications, the local feature information may further include local protocol version information, a local workspace address, and the like, and the remote feature information may further include remote protocol version information, a remote workspace address, and the like.
Step S23: the local system establishes an initial link for data transmission with the remote system, and the local system modifies the self state from an initial state to an initial link establishment state.
After the local system and the remote system initialize the registers, the local system can automatically establish an initial link for data transmission with the remote system, and establish a basic link for data transmission between the local system and the remote system.
Step S24: the local system writes the local characteristic information into a ScachPad register of the remote system based on the initial link and the first key data, and the local system modifies the self state from the initial link establishment state to a remote characteristic information waiting state.
Step S25: after the remote system checks the information written by the local system in the ScrachPad register of the remote system, the remote system writes the remote characteristic information into the ScrachPad register of the local system based on the initial link and the second key data; after checking the information written by the remote system in the ScrachPad register of the local system, the local system sends test data to the remote system based on the initial link and the remote characteristic information, and the local system changes the state of the local system from a state of waiting for the remote characteristic information to a state of waiting for the test data.
The local system writes the local feature information into the ScrachPad register of the remote system, so that the remote system can write the local feature information into the memory space of the local system according to the local feature information, for example, the remote system can write data into a working space corresponding to the local working space address in the local system according to the local working space address in the local feature information. The principle of writing the remote characteristic information into the scatchpad register of the local system by the remote system is the same as the principle of writing the local characteristic information into the scatchpad register of the remote system by the local system, and details are not described here. Of course, the local system may write the local feature information into other registers of the remote system, and the remote system may also write the remote feature information into other registers of the local system, which is not limited herein.
The local system writes the local characteristic information into the ScrachPad register of the remote system, and can also verify whether the local system can write the ScrachPad register of the remote system, if the remote system checks the information written by the local system in the ScrachPad register of the remote system, the local system can write the ScrachPad register of the remote system, otherwise, the local system cannot write the ScrachPad register of the remote system. Similarly, the remote system writes the remote feature information into the scatchpad register of the local system, and can also verify whether the remote system can write the scatchpad register of the local system, if the local system checks that the scatchpad register of the local system is written by the remote system, the remote system can write the scatchpad register of the local system, otherwise, the remote system cannot write the scatchpad register of the local system.
Step S26: the remote system receives the test data sent by the local system and then sends the received test data to the local system based on the initial link and the local characteristic information, and the local system modifies the self state from the state of waiting for the test data to the state of completing the transmission of the test data.
The local system sends test data to the remote system, and the remote system sends the test data to the local system in order to verify whether the local system and the remote system can send data to each other.
Step S27: the local system receives the test data sent by the remote system and judges whether the test data sent by the local system is consistent with the test data sent by the remote system, if so, the local system modifies the self state from the test data transmission completion state to a communication link establishment state, and the establishment of the communication link with the remote system is realized.
The local system judges the accuracy of data transmission between the local system and the remote system by judging whether the test data sent by the local system is consistent with the test data sent by the remote system, if the test data sent by the local system is inconsistent with the test data sent by the remote system, the accuracy of the data transmission between the local system and the remote system is not 100%, because the accuracy of the data transmission between the local system and the remote system is 100% in the communication process, at this time, a communication link can be selected to be reestablished, if the test data sent by the local system is consistent with the test data sent by the remote system, the accuracy of the data transmission between the local system and the remote system is 100%, and the local system and the remote system can transmit the data by applying the established communication data. Therefore, the accuracy of data transmission of the communication link can be ensured.
The method marks and modifies the state of the local system, namely marks and modifies the state of each process of establishing the communication link between the local system and the remote system, so that the process of establishing the communication link between the local system and the remote system can be conveniently checked by the outside, and the outside can conveniently carry out corresponding operation according to the state of the local system.
In practical application, after the communication link is established, whether the communication link is normal or not can be periodically detected, if the communication link is normal, the local system and the remote system transmit, receive and process data, after the data processing is finished, the communication link is returned to the establishment state, and if the communication link is abnormal, the communication link can be re-established. In addition, in the establishing process of the communication link, whether an error occurs in each state of the local system can be inquired, for example, whether the local system waits for a data remote characteristic information state and a data waiting test state for timeout or not, if the local system is inquired to have an error in a certain state, the corresponding state is subjected to error processing, and after the error processing is completed, the local system returns to the initial state to perform subsequent steps until the local system has no error in each state, and if the local system is not inquired to have an error in a certain state, the success of the establishing process of the communication link can be prompted.
In a communication method provided in an embodiment of the present invention, establishing, by a local system, a communication link for data transmission with a remote system includes:
the local system establishes an NTB communication link for data transmission with the remote system.
The communication method provided by the invention can be applied to the communication fields of Ethernet communication, optical fiber communication and the like, and preferably, the communication method provided by the invention is applied to the NTB communication field, and can solve the problem of system hang caused by triggering a remote system DoorBell interrupt register by a local system in NTB communication.
The invention also provides a communication system which has the corresponding effect of the communication method provided by the invention. Referring to fig. 3, fig. 3 is a schematic structural diagram of a communication system according to an embodiment of the present invention.
The communication system provided by the embodiment of the invention can comprise a local system A1 and a remote system A2;
the local system A1 is used for sending data to the remote system and updating the message count index corresponding to the data in the remote system;
and the remote system A2 is used for inquiring the message count index in real time or at regular time and judging whether the message count index is updated or not, and if so, receiving the data.
In a communication system provided in an embodiment of the present invention, the local system may be further configured to write the message count index corresponding to the data into the ScrachPad register of the remote system before updating the message count index corresponding to the data in the remote system.
In a communication system provided in an embodiment of the present invention, the local system may be further configured to write the message count index corresponding to the data into a memory space of the remote system before updating the message count index corresponding to the data in the remote system.
In a communication system provided in an embodiment of the present invention, a local system may include:
the updating module is used for adding 1 to the index value of the message counting index corresponding to the data in the remote system;
the remote system may include:
and the judging module is used for judging whether the index value of the current message counting index is larger than the last index value of the message counting index.
In a communication system provided in an embodiment of the present invention, the local system may be further configured to establish a communication link for data transmission with the remote system before sending data to the remote system.
In a communication system provided in an embodiment of the present invention, a local system may include:
and the establishing module is used for establishing an NTB communication link for data transmission with a remote system.
For a description of a relevant part in a communication system provided in an embodiment of the present invention, reference is made to detailed descriptions of a corresponding part in a communication method provided in an embodiment of the present invention, which are not described herein again. In addition, parts of the above technical solutions provided in the embodiments of the present invention that are consistent with the implementation principles of the corresponding technical solutions in the prior art are not described in detail, so as to avoid redundant description.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (8)

1. A method of communication, comprising:
a local system sends data to a remote system and updates a message counting index corresponding to the data in the remote system;
the remote system inquires the message counting index in real time or at regular time and judges whether the message counting index is updated or not, if so, the data is received;
before the local system sends data to the remote system, the method further comprises:
the local system establishes a communication link for data transmission with the remote system;
the local system establishing a communication link for data transmission with a remote system comprises:
the local system and the remote system initialize respective registers to realize the establishment of a communication link, and the local system marks the self state as the register initialization state;
the local system and the remote system respectively store the corresponding data information, the local system modifies the self state from the register initialization state to the initial state, and the data information of the local system comprises: local feature information including a local workspace address and first critical data including a remote system register address, the data information of the remote system including: remote characteristic information comprising a remote workspace address and second critical data comprising a local system register address;
the local system establishes an initial link for data transmission with the remote system, and modifies the self state from an initial state to an initial link establishment state;
the local system writes the local characteristic information into a ScachPad register of the remote system based on the initial link and the first key data, and the local system modifies the self state from the initial link establishment state to a remote characteristic information waiting state;
after the remote system checks the information written by the local system in the ScrachPad register of the remote system, the remote characteristic information is written into the ScrachPad register of the local system based on the initial link and the second key data; after checking information written by a remote system in a ScrachPad register of the local system, the local system sends test data to the remote system based on the initial link and the remote characteristic information, and the local system changes the state of the local system from a state of waiting for the remote characteristic information to a state of waiting for the test data;
the remote system receives test data sent by a local system and then sends the received test data to the local system based on the initial link and the local characteristic information, and the local system modifies the self state from a test data waiting state to a test data transmission completion state;
the local system receives the test data sent by the remote system and judges whether the test data sent by the local system is consistent with the test data sent by the remote system, if so, the local system modifies the self state from the test data transmission completion state to a communication link establishment state, and the establishment of the communication link with the remote system is realized.
2. The method of claim 1, wherein before the local system updating the message count index corresponding to the data in the remote system, further comprising:
the local system writes a message count index corresponding to the data to the ScrachPad register of the remote system.
3. The method of claim 1, wherein before the local system updating the message count index corresponding to the data in the remote system, further comprising:
and the local system writes the message count index corresponding to the data into the memory space of the remote system.
4. The method of claim 1, wherein the local system updating a message count index corresponding to the data in the remote system comprises:
the local system adds 1 to the index value of the message count index corresponding to the data in the remote system;
the remote system determining whether the message count index is updated comprises:
and the remote system judges whether the index value of the current message counting index is larger than the last index value of the message counting index.
5. The method of claim 4, wherein the local system establishing a communication link for data transmission with a remote system comprises:
the local system establishes an NTB communication link for data transmission with the remote system.
6. A communication system comprising a local system and a remote system;
the local system is used for sending data to the remote system and updating a message counting index corresponding to the data in the remote system;
the remote system is used for inquiring the message counting index in real time or at regular time and judging whether the message counting index is updated or not, if so, the data is received;
the local system is also used for establishing a communication link for data transmission with the remote system before sending data to the remote system;
the local system establishing a communication link for data transmission with a remote system comprises:
the local system and the remote system initialize respective registers to realize the establishment of a communication link, and the local system marks the self state as the register initialization state;
the local system and the remote system respectively store the corresponding data information, the local system modifies the self state from the register initialization state to the initial state, and the data information of the local system comprises: local feature information including a local workspace address and first critical data including a remote system register address, the data information of the remote system including: remote characteristic information comprising a remote workspace address and second critical data comprising a local system register address;
the local system establishes an initial link for data transmission with the remote system, and modifies the self state from an initial state to an initial link establishment state;
the local system writes the local characteristic information into a ScachPad register of the remote system based on the initial link and the first key data, and the local system modifies the self state from the initial link establishment state to a remote characteristic information waiting state;
after the remote system checks the information written by the local system in the ScrachPad register of the remote system, the remote characteristic information is written into the ScrachPad register of the local system based on the initial link and the second key data; after checking information written by a remote system in a ScrachPad register of the local system, the local system sends test data to the remote system based on the initial link and the remote characteristic information, and the local system changes the state of the local system from a state of waiting for the remote characteristic information to a state of waiting for the test data;
the remote system receives test data sent by a local system and then sends the received test data to the local system based on the initial link and the local characteristic information, and the local system modifies the self state from a test data waiting state to a test data transmission completion state;
the local system receives the test data sent by the remote system and judges whether the test data sent by the local system is consistent with the test data sent by the remote system, if so, the local system modifies the self state from the test data transmission completion state to a communication link establishment state, and the establishment of the communication link with the remote system is realized.
7. The system of claim 6,
the local system is further configured to write the message count index corresponding to the data to a ScrachPad register of the remote system before updating the message count index corresponding to the data in the remote system.
8. The system of claim 6,
the local system is further configured to write the message count index corresponding to the data into a memory space of the remote system before updating the message count index corresponding to the data in the remote system.
CN201710618266.6A 2017-07-26 2017-07-26 Communication method and system Active CN107357746B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710618266.6A CN107357746B (en) 2017-07-26 2017-07-26 Communication method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710618266.6A CN107357746B (en) 2017-07-26 2017-07-26 Communication method and system

Publications (2)

Publication Number Publication Date
CN107357746A CN107357746A (en) 2017-11-17
CN107357746B true CN107357746B (en) 2020-05-29

Family

ID=60285133

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710618266.6A Active CN107357746B (en) 2017-07-26 2017-07-26 Communication method and system

Country Status (1)

Country Link
CN (1) CN107357746B (en)

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4776307B2 (en) * 2005-08-31 2011-09-21 株式会社日立製作所 Storage system, data transfer method and program
CN104486365B (en) * 2014-09-28 2018-02-02 浪潮(北京)电子信息产业有限公司 Communication means and system between dual control
CN106569736B (en) * 2015-10-10 2018-10-19 北京忆芯科技有限公司 NVMe protocol processors and its processing method
CN106209974B (en) * 2016-06-21 2019-03-12 浪潮电子信息产业股份有限公司 A kind of method of data synchronization, equipment and system

Also Published As

Publication number Publication date
CN107357746A (en) 2017-11-17

Similar Documents

Publication Publication Date Title
CN103514173B (en) The method and node device of data processing
CN107357595B (en) Bus-based multi-driver firmware online updating system
CN103546467A (en) Method for transmitting Modbus RTU protocol on TCP/IP network
US8364872B2 (en) Slave and communicating method between a master and the same
CN106603359B (en) The communicating control method and device of PLC system
US11212658B2 (en) Method for providing near filed communication device information for user and system therefor
US20230412742A1 (en) Apparatus, method, and system for monitoring image-forming apparatus, and storage medium
CN107528747B (en) Method and device for diagnosing communication state of master station and slave station and computer readable storage medium
EP2398190B1 (en) Field communication system
CN107357746B (en) Communication method and system
CN112636987B (en) Cross-chain gateway determination method and system for block chain and terminal equipment
CN103217956A (en) Industrial control system as well as control method and control device thereof
CN105281944B (en) Method for setting network protocol address and service management system
CN106789304B (en) Network equipment configuration synchronization method and device
JP3730545B2 (en) Service control application execution method and system
KR20160147373A (en) Sata host bus adaptor using light signal and method for connecting sata storage using the same
CN110661869B (en) Node online method, system, device, equipment and computer storage medium
EP3955524A1 (en) Method for managing remote storage device by means of management device
CN111431668B (en) Baud rate switching method based on multi-node UART communication, air conditioning system and processor
CN110990313B (en) Method, equipment and storage medium for processing clock stretching of I3C bus
CN109753461B (en) DMA device and data transmission method
CN107547329B (en) NTB-based double-control data transmission method and system
JP2016146605A (en) On-vehicle communication device
KR20210054939A (en) Apparatus for controlling a vehicle, system having the same and method thereof
CN116756078B (en) Notification method and device of pcie data packet and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant