WO2013129031A1 - データ転送装置、データ転送方法及びデータ転送プログラム - Google Patents

データ転送装置、データ転送方法及びデータ転送プログラム Download PDF

Info

Publication number
WO2013129031A1
WO2013129031A1 PCT/JP2013/052451 JP2013052451W WO2013129031A1 WO 2013129031 A1 WO2013129031 A1 WO 2013129031A1 JP 2013052451 W JP2013052451 W JP 2013052451W WO 2013129031 A1 WO2013129031 A1 WO 2013129031A1
Authority
WO
WIPO (PCT)
Prior art keywords
read
data
write
transfer
buffer
Prior art date
Application number
PCT/JP2013/052451
Other languages
English (en)
French (fr)
Inventor
佳奈子 山本
Original Assignee
三菱電機株式会社
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 三菱電機株式会社 filed Critical 三菱電機株式会社
Priority to CN201380011490.9A priority Critical patent/CN104145255B/zh
Priority to US14/377,982 priority patent/US9727504B2/en
Priority to DE112013001213.8T priority patent/DE112013001213T5/de
Priority to KR1020147024021A priority patent/KR101593865B1/ko
Priority to JP2014502088A priority patent/JP5769868B2/ja
Priority to TW102106366A priority patent/TWI524267B/zh
Publication of WO2013129031A1 publication Critical patent/WO2013129031A1/ja

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/20Handling requests for interconnection or transfer for access to input/output bus
    • G06F13/28Handling requests for interconnection or transfer for access to input/output bus using burst mode transfer, e.g. direct memory access DMA, cycle steal
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F5/00Methods or arrangements for data conversion without changing the order or content of the data handled
    • G06F5/06Methods or arrangements for data conversion without changing the order or content of the data handled for changing the speed of data flow, i.e. speed regularising or timing, e.g. delay lines, FIFO buffers; over- or underrun control therefor
    • G06F5/08Methods or arrangements for data conversion without changing the order or content of the data handled for changing the speed of data flow, i.e. speed regularising or timing, e.g. delay lines, FIFO buffers; over- or underrun control therefor having a sequence of storage locations, the intermediate ones not being accessible for either enqueue or dequeue operations, e.g. using a shift register
    • G06F5/085Methods or arrangements for data conversion without changing the order or content of the data handled for changing the speed of data flow, i.e. speed regularising or timing, e.g. delay lines, FIFO buffers; over- or underrun control therefor having a sequence of storage locations, the intermediate ones not being accessible for either enqueue or dequeue operations, e.g. using a shift register in which the data is recirculated
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • 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

Definitions

  • This invention relates to a data transfer technique for transferring data stored in a transfer source area to a transfer destination area.
  • DMA Direct Memory Access
  • a CPU Central Processing Unit
  • DMA transfer control device executes transfer processing according to the DMA information set in the register.
  • the DMA transfer control device completes the data transfer for the transfer size set in the register, it asserts a DMA transfer end interrupt to the CPU.
  • the CPU detects a DMA transfer end interrupt, the CPU reads the register information of the DMA transfer control device and checks the DMA transfer result and status.
  • DMA transfer control device While the DMA transfer control device is executing transfer processing, there is no need for transfer control by the CPU. Therefore, in DMA transfer, data transfer can be performed at a higher speed than in the case where data transfer is performed via the CPU. Also, with DMA transfer, the CPU burden can be reduced. In general DMA transfer, necessary data is read for each set size (unit amount), and the subsequent writing is performed. Since the write start timing is after the completion of read, transfer efficiency is not good in transfer to a device with a large latency.
  • the DMA transfer control device using an AXI (Advanced extensible Interface) bus includes a read-only bus and a write-only bus, and parallel data acquisition from the data transfer source area using the read-only bus and data transfer to the data transfer destination area using the write-only bus. Can be executed.
  • the AXI bus has a burst transfer function.
  • the burst transfer function is a function that can acquire a plurality of unit amounts of read data with a single read request and can execute a plurality of unit amounts of write with a single write request.
  • the DMA transfer control device using the AXI bus can perform high-speed transfer by using the read / write dedicated bus and the burst transfer function.
  • An object of the present invention is to prevent the occurrence of data destruction when a data transfer source area and a transfer destination area overlap. In particular, an object is to prevent the occurrence of data destruction even when the transfer is performed using the burst transfer function.
  • the data transfer device is: A data transfer device for transferring data stored in a transfer source area to a transfer destination area; A transfer source read control unit that outputs a read command for reading data stored in the transfer source area; A buffer write control unit that acquires data read by a read command output by the transfer source read control unit and writes the data to a ring buffer; A buffer read control unit that reads data written by the buffer write control unit from the ring buffer and transmits the data to the transfer destination area; A transfer destination write control unit that outputs a write command for writing the data transmitted by the buffer read control unit to the transfer destination region into the transfer destination region; and A write cycle count unit for counting the number of wraparounds by the buffer write control unit; A read cycle count unit that counts the number of wraparounds by the buffer read control unit; A data non-destructive control unit that determines whether or not data writing to the transfer destination area is permitted based on the magnitude relationship between the number of times counted by the write cycle count unit and the number of times counted by the read cycle count
  • the buffer read control unit reads data from the ring buffer when the data nondestructive control unit determines that writing is permitted,
  • the transfer destination write control unit outputs the write command when the data nondestructive control unit determines that writing is permitted, and the buffer read control unit transmits the data transmitted to the transfer destination area. It is characterized by writing to the area.
  • the occurrence of data corruption can be prevented by adjusting the timing of reading data from the buffer area.
  • 1 is a configuration diagram of a DMA transfer system 10 according to a first embodiment.
  • 1 is a configuration diagram of a DMA transfer control device 100 according to Embodiment 1.
  • FIG. FIG. 3 is a configuration diagram of a data nondestructive control unit 160 according to the first embodiment.
  • FIG. 3 is a configuration diagram of a buffer write cycle count unit 170 according to the first embodiment.
  • FIG. 3 is a configuration diagram of a buffer read cycle count unit 180 according to the first embodiment.
  • 4 is a flowchart showing the overall operation of the DMA transfer control apparatus 100 according to the first embodiment.
  • 5 is a flowchart showing an operation of a transfer source read control unit 110 according to the first embodiment.
  • 5 is a flowchart showing the operation of the buffer write control unit 120 according to the first embodiment.
  • 5 is a flowchart showing the operation of a buffer read control unit 140.
  • 5 is a flowchart showing an operation of a transfer destination write control unit 150 according to the first embodiment.
  • 5 is a flowchart showing an operation of a data nondestructive control unit 160 according to the first embodiment.
  • 5 is a flowchart showing the operation of the buffer write cycle count unit 170 according to the first embodiment.
  • 5 is a flowchart showing an operation of a buffer read cycle count unit 180 according to the first embodiment.
  • FIG. 11 is a diagram (1-1) showing a change in data during DMA transfer.
  • FIG. 11 is a diagram (1-1) showing a change in data during DMA transfer.
  • FIG. 12B is a diagram illustrating changes in data during DMA transfer (1-2).
  • FIG. 3 is a diagram (1-3) showing changes in data during DMA transfer.
  • FIG. 14 is a diagram (1-4) showing changes in data during DMA transfer.
  • FIG. 5 is a diagram (1-5) showing a change in data during DMA transfer.
  • FIG. 2A is a diagram (2-1) showing changes in data during DMA transfer.
  • FIG. 2-2 is a diagram showing data change during DMA transfer (2-2).
  • FIG. 2C is a diagram illustrating a change in data during DMA transfer (2-3).
  • FIG. 4D is a diagram (2-4) showing a change in data during DMA transfer.
  • FIG. 5 is a diagram (2-5) showing a change in data during DMA transfer.
  • FIG. 3A is a diagram showing changes in data during DMA transfer (3-1).
  • FIG. 3C is a diagram showing data change during DMA transfer (3-2).
  • FIG. 3-3 is a diagram showing changes in data during DMA transfer.
  • FIG. 4C is a diagram (3-4) showing changes in data during DMA transfer.
  • FIG. 5 is a diagram (3-5) showing data changes during DMA transfer.
  • the block diagram of the data nondestructive control part 160 which concerns on Embodiment 2.
  • FIG. 9 is a flowchart showing the overall operation of the DMA transfer control apparatus 100 according to the second embodiment.
  • FIG. 1 and 2 are explanatory diagrams when data destruction occurs.
  • FIG. 1 is an explanatory diagram when a data transfer source area and a transfer destination area are shifted in the forward direction.
  • FIG. 2 is an explanatory diagram when the data transfer source area and the transfer destination area are shifted in the opposite direction.
  • the transfer source area and the transfer destination area are shifted in the forward direction when the address value of the start address of the transfer source area is smaller than the address value of the start address of the transfer destination area.
  • the transfer source area and the transfer destination area are areas in the same device, and the area B overlaps.
  • the address value of the start address of the area A that is the start address of the transfer source area is smaller than the address value of the start address of the area B that is the start address of the transfer destination area.
  • the area is shifted in the forward direction.
  • FIG. 3 is an explanatory diagram of the order of data transfer when the burst transfer function is used.
  • FIG. 3 shows a case where data transfer in the decrement direction is performed using the burst transfer function.
  • In normal data transfer only one unit amount of data can be transferred with one read / write request.
  • the burst transfer function when the burst transfer function is used, a plurality of unit amounts of data can be transferred with a single read / write request.
  • FIG. 3 it is assumed that data of 8 unit amounts of data 1 to 8 are transferred. Therefore, in normal data transfer, eight read / write requests are required.
  • the burst transfer function is used, transfer is possible with two read / write requests.
  • the order of issuing burst read commands can be in the increment direction or the decrement direction.
  • the data read order in the burst read command can only be in the increment direction. Therefore, as shown in FIG. 3, the burst read command is issued in the decrement direction in order of the first four burst read commands for reading data 5 to 8 and the second four burst read commands for reading data 1 to 4.
  • the data reading order is the order of data 5, 6, 7, 8, 1, 2, 3, 4. That is, the data 8, 7, 6, 5, 4, 3, 2, 1 cannot be read in this order.
  • the burst write command issuance order can be in the increment direction or the decrement direction as in the case of the burst read command.
  • the data write order within the burst write command can only be in the increment direction.
  • FIG. 4 is a configuration diagram of the DMA transfer system 10 according to the first embodiment.
  • the DMA transfer system 10 includes a DMA transfer control device 100 (data transfer device), a CPU 200, and a memory 300.
  • the DMA transfer control device 100 is a device that accesses the memory 300 and transfers data according to DMA information set in a register by a user such as the CPU 200.
  • the CPU 200 transfers the DMA information of the transfer source address specifying the transfer source area, the transfer destination address specifying the transfer destination area, the transfer size specifying the size of the transfer data, and the transfer type (increment transfer or decrement transfer).
  • 100 registers are set to cause the DMA transfer control device 100 to execute data transfer.
  • the CPU 200 sets the DMA information.
  • another device or system may set the DMA information.
  • the memory 300 is a target resource that becomes a transfer source area and a transfer destination area of data transfer.
  • FIG. 5 is a configuration diagram of the DMA transfer control apparatus 100 according to the first embodiment.
  • a solid line represents a data line through which data flows
  • a broken line represents a control line through which a control signal flows.
  • the DMA transfer control device 100 includes a transfer source read control unit 110, a buffer write control unit 120, an internal buffer 130 (ring buffer), a buffer read control unit 140, a transfer destination write control unit 150, a data nondestructive control unit 160, a buffer write.
  • a cycle count unit 170 and a buffer read cycle count unit 180 are provided.
  • the transfer source read control unit 110 outputs to the memory 300 a transfer source read command for reading data stored in the transfer source area of the memory 300.
  • the transfer source read command is information in which a read address, a read address valid signal (or a read request signal), and other (burst size, burst length) signals are collected.
  • the buffer write control unit 120 acquires the transfer source read data read by the transfer source read command output from the transfer source read control unit 110 via the read-only bus. Further, the buffer write control unit 120 outputs the acquired transfer source read data to the internal buffer 130 as buffer write data, and writes the buffer write data at a position specified by the buffer write pointer in the internal buffer 130.
  • the buffer write pointer is information indicating the current buffer write destination.
  • the buffer write control unit 120 notifies the data nondestructive control unit 160 of the position where the writing of the buffer write data is completed as a buffer write completion pointer.
  • the buffer write completion pointer is information indicating a completion area where the read preparation in the internal buffer 130 is completed.
  • the internal buffer 130 is a resource for storing transfer data built in the DMA transfer control device 100.
  • the buffer read control unit 140 reads data as buffer read data from the position specified by the buffer read pointer in the internal buffer 130.
  • the buffer read pointer is information indicating the current buffer read destination. Further, the buffer read control unit 140 outputs the read buffer read data as transfer destination write data to the memory 300 via the write dedicated bus.
  • the buffer read control unit 140 notifies the data non-destructive control unit 160 of the buffer read pointer.
  • the transfer destination write control unit 150 outputs a transfer destination write command to the memory 300 and writes the transfer destination write data output by the buffer read control unit 140 in the transfer destination area.
  • the transfer destination write command is information in which a write address, a write address valid signal (or write request signal), a write data valid signal, and other (burst size, burst length, strobe signal) signals are collected.
  • the data nondestructive control unit 160 notifies the transfer type (increment transfer or decrement transfer) set by the CPU 200 to each control unit and each count unit.
  • the respective control units are the transfer source read control unit 110, the buffer write control unit 120, the buffer read control unit 140, and the transfer destination write control unit 150.
  • Each count unit is a buffer write cycle count unit 170 and a buffer read cycle count unit 180. Further, in the case of decrement transfer, the data non-destructive control unit 160 reads “the number of wraparounds (buffer write cycle counter value) counted by the buffer write cycle count unit 170 and the wraparound times counted by the buffer read cycle count unit 180.
  • data readiness at the position indicated by the buffer read pointer is ready. It is determined whether or not.
  • the data non-destructive control unit 160 determines that the data is ready to be read, the data non-destructive control unit 160 outputs a transfer destination write enable instruction to the buffer read control unit 140 and the transfer destination write control unit 150. Note that, in the case of incremental transfer, the data nondestructive control unit 160 always outputs a transfer destination writable instruction regardless of the buffer write completion pointer and the buffer read pointer.
  • the buffer read control unit 140 When the buffer read control unit 140 receives the transfer destination write enable instruction from the data nondestructive control unit 160, the buffer read control unit 140 reads data from the internal buffer 130. When the transfer destination write control unit 150 receives a transfer destination write enable instruction from the data nondestructive control unit 160, the transfer destination write control unit 150 outputs a transfer destination write command.
  • the buffer write cycle count unit 170 is a counter that counts the number of times the buffer write completion pointer wraps around in the case of decrement transfer.
  • the buffer read cycle count unit 180 is a counter that counts the number of times the buffer read pointer wraps around in the case of decrement transfer.
  • the read-only bus is a bus through which a transfer source read command and transfer source read data flow
  • the write-only bus is a bus through which a transfer destination write command and transfer destination write data flow.
  • the read-only bus and the write-only bus have no dependency and can operate in parallel.
  • FIG. 6 is a configuration diagram of the data nondestructive control unit 160 according to the first embodiment.
  • the data nondestructive control unit 160 includes a transfer type setting register 161, a buffer write completion pointer setting register 162, a buffer read pointer setting register 163, a first buffer preparation completion determination unit 164, a second buffer preparation completion determination unit 165, and a wraparound count.
  • a match determination unit 166 and a selector 167 are provided.
  • a transfer type is set in the transfer type setting register 161 from the CPU 200.
  • the transfer type set in the transfer type setting register 161 is notified from the data nondestructive control unit 160 to each control unit.
  • a buffer write completion pointer is set in the buffer write completion pointer setting register 162 from the buffer write control unit 120.
  • a buffer read pointer is set in the buffer read pointer setting register 163 from the buffer read control unit 140.
  • the first buffer preparation completion determination unit 164 determines whether data read preparation from the internal buffer 130 is completed based on the transfer type, the buffer write completion pointer, and the buffer read pointer. If it is determined that the data read preparation has been completed, it is determined that data destruction does not occur, and a transfer destination write enable instruction (pointer) is output to the selector 167.
  • the second buffer preparation completion determination unit 165 receives data from the internal buffer 130 based on the buffer write cycle counter value obtained from the buffer write cycle count unit 170 and the buffer read cycle counter value obtained from the buffer read cycle count unit 180. It is determined whether the read preparation is completed.
  • a transfer destination write enable instruction (counter) is output to the selector 167.
  • the wraparound count coincidence determination unit 166 determines whether or not the buffer write cycle counter value obtained from the buffer write cycle count unit 170 matches the buffer read cycle counter value obtained from the buffer read cycle count unit 180. .
  • the selector 167 outputs a transfer destination writable instruction (pointer) output from the first buffer preparation completion determination unit 164 and a second buffer preparation completion determination unit 165 based on the determination result of the wraparound count match determination unit 166. Of the designated transfer destination write enable instruction (counter) is selected as the transfer destination write enable instruction.
  • the selector 167 outputs the selected transfer destination write enable instruction to the buffer read control unit 140 and the transfer destination write control unit 150.
  • FIG. 7 is a configuration diagram of the buffer write cycle count unit 170 according to the first embodiment.
  • the buffer write cycle count unit 170 includes a wraparound detection unit 171 and a wraparound frequency count unit 172.
  • the wraparound detection unit 171 detects whether or not the buffer write completion pointer has wrapped around.
  • the wraparound number counting unit 172 increments the buffer write cycle counter value by +1 when the wraparound detecting unit 171 detects wraparound. Then, the wraparound number counting unit 172 outputs the counted buffer write cycle counter value to the data nondestructive control unit 160.
  • FIG. 8 is a configuration diagram of the buffer read cycle count unit 180 according to the first embodiment.
  • the buffer read cycle count unit 180 includes a wraparound detection unit 181 and a wraparound frequency count unit 182.
  • the wraparound detection unit 181 detects whether or not the buffer read pointer has wrapped around.
  • the wraparound number counting unit 182 increments the buffer read cycle counter value by +1 when the wraparound detecting unit 181 detects wraparound. Then, the wraparound count unit 182 outputs the counted buffer read cycle counter value to the data nondestructive control unit 160.
  • FIG. 9 is a flowchart showing the overall operation of the DMA transfer control apparatus 100 according to the first embodiment.
  • the CPU 200 sets DMA information in the register of the DMA transfer control device 100 and activates the DMA transfer control device 100.
  • the data nondestructive control unit 160 of the DMA transfer control device 100 notifies each control unit of the transfer type (increment transfer or decrement transfer) set in the register (transfer type setting register 161). If increment transfer is set in the register, the process proceeds to S13. If decrement transfer is set, the process proceeds to S14.
  • the DMA transfer control device 100 performs incremental transfer to the memory 300.
  • the DMA transfer control device 100 performs decrement transfer to the memory 300.
  • the transfer operation is stopped when there is a DMA transfer stop factor, such as when the DMA transfer control device 100 has finished transferring the specified data length.
  • FIG. 10 is a flowchart showing the operation of the transfer source read control unit 110 according to the first embodiment.
  • FIG. 10 shows the operation of the transfer source read control unit 110 in S13 or S14 in FIG.
  • the transfer source read control unit 110 determines whether the transfer is an increment transfer or a decrement transfer based on the transfer type transmitted from the data nondestructive control unit 160. If it is determined that the transfer is increment transfer, the process proceeds to S22. If it is determined that the transfer is decrement transfer, the process proceeds to S23. In S22 and S23, the transfer source read control unit 110 generates one burst read command as the transfer source read command. As described with reference to FIG.
  • the burst read command is a command for reading out a predetermined number of unit quantities of data for each unit quantity of data in ascending order of address values from the read start address.
  • the transfer source read control unit 110 determines whether or not read access is possible depending on whether or not the internal buffer 130 has a free area for storing data read by the transfer source read command. . If it is determined that read access is possible (YES in S24), the process proceeds to S25. On the other hand, if it is determined that read access is not possible (NO in S24), the process returns to S24, and it is determined again whether read access is possible after a predetermined time has elapsed.
  • a transfer source read command generated by the transfer source read control unit 110 is issued to the memory 300, and data is read from the transfer source area.
  • the transfer source read control unit 110 determines whether or not to terminate the read access to the memory 300 based on whether or not the transfer source read command for reading data corresponding to the transfer size has been transmitted to the memory 300. If it is determined that the read access is to be terminated (YES in S26), the process is terminated. On the other hand, if it is determined not to end the read access (NO in S26), the process returns to S21.
  • the transfer source read control unit 110 In S22, the transfer source read control unit 110 generates a burst read command in the increment direction. That is, the burst read command is generated so that the address values of the read start address of the burst read command are in ascending order.
  • the transfer source read control unit 110 In S23, the transfer source read control unit 110 generates a burst read command in the decrement direction. That is, the burst read command is generated so that the address value of the read start address of the burst read command is in descending order.
  • FIG. 11 is a flowchart showing the operation of the buffer write control unit 120 according to the first embodiment.
  • FIG. 11 shows the operation of the buffer write control unit 120 in S13 or S14 in FIG.
  • the buffer write control unit 120 determines whether the transfer is an increment transfer or a decrement transfer based on the transfer type transmitted from the data nondestructive control unit 160. If it is determined to be increment transfer, the process proceeds to S32. If it is determined to be decrement transfer, the process proceeds to S33. In S32 and S33, the buffer write control unit 120 generates one burst write command corresponding to one transfer source read command as a buffer write command.
  • This buffer write command is a command for writing data in ascending order of address values from the write start address, with the address in the internal buffer 130 corresponding to the read start address of the corresponding transfer source read command as the write start address.
  • the buffer write control unit 120 acquires information such as a read start address and a transfer source read command for reading a unit amount of data from the transfer source read control unit 110 to transfer the data.
  • a buffer write command corresponding to the original read command is generated.
  • the buffer write control unit 120 uses the same logic as that of the transfer source read control unit 110 to issue a read start address and a transfer source read command for the transfer source read control unit 110 to read out a unit amount of data. Or the like, and a buffer write command corresponding to the transfer source read command may be generated.
  • the buffer write control unit 120 sets the buffer write completion pointer in the buffer write completion pointer setting register 162 of the data nondestructive control unit 160. At this time, the buffer write completion pointer indicates an address value obtained by adding an address value corresponding to the data size written by the write command to the address value indicated by the buffer write pointer. Subsequent to S32 and S33, in S34, the buffer write control unit 120 issues a buffer write command to the internal buffer 130. As a result, data read from the transfer source area by one transfer source read command is written to the internal buffer 130. In S35, the buffer write control unit 120 determines whether or not to end the write access to the internal buffer 130 based on whether or not the buffer write command for writing data for the transfer size has been transmitted to the internal buffer 130.
  • the process is terminated. If it is determined that write access is not to be terminated (NO in S35), the process returns to S31. If it is determined in S35 that the write access is to be ended (YES in S35), the buffer write control unit 120 uses the write start address in the last issued burst write command as the buffer write completion pointer, and the buffer write completion pointer setting register. After setting to 162, the process ends.
  • FIG. 12 is a flowchart showing the operation of the buffer read control unit 140.
  • FIG. 12 shows the operation of the buffer read control unit 140 in S13 or S14 in FIG.
  • the buffer read control unit 140 determines whether the transfer is an increment transfer or a decrement transfer based on the transfer type transmitted from the data nondestructive control unit 160. If it is determined to be increment transfer, the process proceeds to S42. If it is determined to be decrement transfer, the process proceeds to S43. In S42 and S43, the buffer read control unit 140 generates one burst read command corresponding to one transfer destination write command as a buffer read command.
  • This buffer read command is a command for reading data in ascending order of address values from the read start address, with the address in the internal buffer 130 corresponding to the write start address of the corresponding transfer destination write command as the read start address.
  • the buffer read control unit 140 obtains information such as a write start address and a transfer destination write command for writing a unit amount of data from the transfer destination write control unit 150 and transfers the information.
  • a buffer read command corresponding to the destination write command is generated.
  • the buffer read control unit 140 uses the same logic as the transfer destination write control unit 150 to issue a write start address and how many unit amounts of data the transfer destination write control unit 150 issues data to be written. Or the like, and a buffer read command corresponding to the transfer destination write command may be generated.
  • the buffer read control unit 140 stores the buffer read pointer indicating the read start address of the buffer read command in the buffer read pointer setting register 163 of the data nondestructive control unit 160. Set. Subsequent to S42 and S43, in S44, the buffer read control unit 140 determines whether or not read access is possible. The buffer read control unit 140 (1) stores data to be written by the transfer destination write command in the internal buffer 130 and (2) receives a transfer destination writable instruction from the data non-destructive control unit 160 In this case, it is determined that read access is possible. If it is determined that read access is possible (YES in S44), the process proceeds to S45.
  • the process returns to S44, and it is determined whether read access is possible again after a predetermined time has elapsed.
  • the buffer read control unit 140 issues a buffer read command to the internal buffer 130.
  • the buffer read control unit 140 determines whether or not to terminate the read access to the internal buffer 130 based on whether or not the buffer read command for reading the data corresponding to the transfer size has been transmitted to the internal buffer 130. . If it is determined that the read access is to be terminated (YES in S46), the process is terminated. If it is determined that the read access is not terminated (NO in S46), the process returns to S41.
  • FIG. 13 is a flowchart showing the operation of the transfer destination write control unit 150 according to the first embodiment.
  • FIG. 13 shows the operation of the transfer destination write control unit 150 in S13 or S14 in FIG.
  • the transfer destination write control unit 150 determines whether the transfer is an increment transfer or a decrement transfer based on the transfer type transmitted from the data nondestructive control unit 160. If it is determined to be increment transfer, the process proceeds to S52. If it is determined to be decrement transfer, the process proceeds to S53. In S52 and S53, the transfer destination write control unit 150 generates one burst write command as the transfer destination write command. As described with reference to FIG.
  • the burst write command is a command for writing data of a predetermined unit amount for each unit amount of data in ascending order of address values from the write start address.
  • the transfer destination write control unit 150 determines whether or not write access is possible under the same conditions as the conditions for determining whether or not the buffer read control unit 140 can perform read access. In other words, the transfer destination write control unit 150 (1) stores data to be written by the transfer destination write command in the internal buffer 130, and (2) instructs the data non-destructive control unit 160 to write the transfer destination. Is received, it is determined that write access is possible. If it is determined that write access is possible (YES in S54), the process proceeds to S55.
  • the process returns to S54, and it is determined whether write access is possible again after a predetermined time has elapsed.
  • the transfer destination write command generated by the transfer destination write control unit 150 is issued to the memory 300, and the data is written to the transfer destination area.
  • the transfer destination write control unit 150 determines whether or not to end the write access to the memory 300 based on whether or not the transfer destination write command for writing the data for the transfer size is transmitted to the memory 300. If it is determined that the write access is to be terminated (YES in S56), the process is terminated. On the other hand, if it is determined not to end the write access (NO in S56), the process returns to S51, the next transfer destination write command is generated, transmitted to the memory 300, and the data is written.
  • the transfer destination write control unit 150 In S52, the transfer destination write control unit 150 generates a burst write command in the increment direction. That is, the burst write command is generated so that the address values of the write start addresses of the burst write command are in ascending order.
  • the transfer destination write control unit 150 In S53, the transfer destination write control unit 150 generates a burst write command in the decrement direction. That is, the burst write command is generated so that the address value of the write start address of the burst write command is in descending order.
  • FIG. 14 is a flowchart showing the operation of the data nondestructive control unit 160 according to the first embodiment.
  • FIG. 14 shows the operation of the data nondestructive control unit 160 in S13 or S14 in FIG.
  • the data nondestructive control unit 160 determines whether the transfer is an increment transfer or a decrement transfer according to the transfer type set in the transfer type setting register 161. If it is determined to be decrement transfer, the process proceeds to S62. If it is determined to be increment transfer, the process proceeds to S66. In S 62, the data nondestructive control unit 160 determines whether or not the buffer write cycle counter value counted by the buffer write cycle counting unit 170 is larger than the buffer read cycle counter value counted by the buffer read cycle counting unit 180.
  • the process proceeds to S63. If the buffer write cycle counter value is greater than the buffer read cycle counter value (YES in S62), the process proceeds to S66. Proceed to In S63, the data nondestructive control unit 160 determines whether or not the buffer write cycle counter value counted by the buffer write cycle count unit 170 is smaller than the buffer read cycle counter value counted by the buffer read cycle count unit 180. If the buffer write cycle counter value is not smaller than the buffer read cycle counter value (NO in S63), the process proceeds to S64. If the buffer write cycle counter value is smaller than the buffer read cycle counter value (YES in S63), the process proceeds to S65.
  • the data non-destructive control unit 160 causes the address value indicated by the buffer write completion pointer set in the buffer write completion pointer setting register 162 to be less than or equal to the address value indicated by the buffer read pointer set in the buffer read pointer setting register 163. It is determined whether or not. If the address value indicated by the buffer write completion pointer is not less than or equal to the address value indicated by the buffer read pointer (NO in S64), the process proceeds to S65. On the other hand, if the address value indicated by the buffer write completion pointer is equal to or less than the address value indicated by the buffer read pointer (YES in S64), the process proceeds to S66.
  • the data nondestructive control unit 160 determines that preparation for buffer reading is incomplete, and does not transmit a transfer destination writable instruction. On the other hand, in S66, the data nondestructive control unit 160 determines that preparation for buffer reading is completed, and transmits a transfer destination write enable instruction to the buffer read control unit 140 and the transfer destination write control unit 150. In S67, the data nondestructive control unit 160 determines whether or not to end the processing depending on whether or not the transfer of the data corresponding to the transfer size is completed. If it is determined that the process is to be terminated (YES in S67), the process is terminated. On the other hand, if it is determined not to end the process (NO in S67), the process returns to S61, and it is determined again whether the buffer preparation is completed.
  • buffer write cycle counter value buffer read cycle counter value
  • buffer write completion pointer When the address value indicated by ⁇ the address value indicated by the buffer read pointer ”is established, it is determined that the buffer preparation is complete.
  • FIG. 15 is a flowchart showing the operation of the buffer write cycle count unit 170 according to the first embodiment.
  • FIG. 15 shows the operation of the buffer write cycle count unit 170 in S13 or S14 in FIG.
  • the buffer write cycle count unit 170 determines whether the transfer is an increment transfer or a decrement transfer based on the transfer type transmitted from the data nondestructive control unit 160. If it is determined to be decrement transfer, the process proceeds to S72. If it is determined to be increment transfer, the process proceeds to S74. In S72, the buffer write cycle count unit 170 determines whether or not the buffer write completion pointer generated by the buffer write control unit 120 has wrapped around.
  • the process proceeds to S73. If it is determined that wrap-around has occurred (YES in S72), the process proceeds to S74. In S73, the buffer write cycle count unit 170 increments the counter by +1. In S74, the buffer write cycle count unit 170 determines whether or not to end the processing depending on whether or not the transfer of the data corresponding to the transfer size has been completed. If it is determined that the process is to be terminated (YES in S74), the process is terminated. On the other hand, if it is determined not to end the process (NO in S74), the process returns to S71, and it is determined whether or not the counter is counted up again.
  • FIG. 16 is a flowchart showing the operation of the buffer read cycle counting unit 180 according to the first embodiment.
  • FIG. 16 shows the operation of the buffer read cycle count unit 180 in S13 or S14 in FIG.
  • the buffer read cycle count unit 180 determines whether the transfer is an increment transfer or a decrement transfer based on the transfer type transmitted from the data nondestructive control unit 160. If it is determined to be decrement transfer, the process proceeds to S82. If it is determined to be increment transfer, the process proceeds to S84. In S82, the buffer read cycle count unit 180 determines whether or not the buffer read pointer generated by the buffer read control unit 140 has wrapped around. If it is determined that wrap-around has occurred (YES in S82), the process proceeds to S83.
  • the process proceeds to S84.
  • the buffer read cycle count unit 180 increments the counter by +1.
  • the buffer read cycle count unit 180 determines whether or not to end the processing depending on whether or not the transfer of the data corresponding to the transfer size has been completed. If it is determined that the process is to be terminated (YES in S84), the process is terminated. On the other hand, if it is determined not to end the process (NO in S84), the process returns to S81, and it is determined whether or not to increment the counter again.
  • FIGS. 17 to 21 are diagrams showing changes in data during DMA transfer when data larger than the size of the internal buffer 130 is DMA-transferred and the buffer write completion pointer wraps around first. That is, FIG. 17 to FIG. 21 are diagrams showing changes in data when “buffer write cycle counter value> buffer read cycle counter value”.
  • the size of the internal buffer 130 is 64 bytes, and one square has 2 bytes.
  • the transfer source and transfer destination in FIGS. 17 to 21 are the same device, and one square indicates 2 bytes. In the example of FIGS.
  • the data in the transfer source addresses 00h to 58h is decrementally transferred to the transfer destination addresses 20h to 78h.
  • the DMA transfer control device 100 issues to the transfer source in the order of read 1 (4 burst read), read 2 (4 burst read), and read 3 (4 burst read). Also, the DMA transfer control device 100 issues to the transfer destination in the order of write 1 (4 burst write), write 2 (4 burst write), and write 3 (4 burst write).
  • the read order shown on the right side of the transfer source in FIGS. 17 to 21 indicates the order in which the DMA transfer control device 100 obtains the read data, receives the read data in the order of R1 to R12, and the internal buffer in the same order. Write to 130.
  • the write order shown on the right side of the transfer destination indicates the order in which the DMA transfer control apparatus 100 outputs data to the transfer destination.
  • the write data is received from the internal buffer 130 in the order of W1 to W12, and the transfer destination in the same order.
  • the buffer write completion pointer in FIGS. 17 to 21 indicates an area where data is prepared in the internal buffer 130
  • the buffer read pointer indicates an area in which data is read in the internal buffer 130.
  • the buffer write cycle counter indicates the number of times the buffer write completion pointer wraps around
  • the buffer read cycle counter indicates the number of times the buffer read pointer wraps around. Both pointers are incremented by +1 every time they wrap around.
  • Source address 00h Forwarding address: 20h Transfer size: 96 bytes Transfer type: Decrement transfer
  • the data nondestructive control unit 160 notifies each control unit and each count unit that decrement transfer is being performed. Then, the process proceeds to S14, and DMA transfer by decrement transfer is executed.
  • the transfer source read control unit 110 issues a read 1 (4 burst read) to the area of the transfer source addresses 40h to 58h.
  • the buffer write control unit 120 issues the buffer write 1 corresponding to the read 1 to the internal buffer 130 and writes the read data in the area of the addresses 20h to 38h.
  • the buffer write control unit 120 updates the buffer write completion pointer to 20h.
  • the buffer read control unit 140 sets the buffer read pointer to 20h (data reading area output by write 1 (4 burst write) issued to the transfer destination).
  • the transfer source read control unit 110 issues a read 2 (4 burst read) to the area of the transfer source addresses 20h to 38h.
  • the buffer write control unit 120 issues the buffer write 2 corresponding to the read 2 to the internal buffer 130 and writes the read data in the area of addresses 00h to 18h.
  • the buffer write control unit 120 updates the buffer write completion pointer to 00h.
  • the buffer read control unit 140 When the buffer read control unit 140 detects the transfer destination write enable instruction, the buffer read control unit 140 issues buffer read 1 to the area of the address 20h to 38h of the internal buffer 130 and reads the transfer destination write data.
  • the transfer destination write control unit 150 issues a write 1 (4 burst write) to the transfer destination addresses 60h to 78h.
  • the transfer source read control unit 110 issues a read 3 (4 burst read) to the area of the transfer source addresses 00h to 18h.
  • the buffer write control unit 120 issues the buffer write 3 corresponding to the read 3 to the internal buffer 130 and writes the read data in the area of the addresses 20h to 38h.
  • the buffer write completion pointer is updated to 20h, and wraparound occurs.
  • the buffer write cycle count unit 170 detects a wraparound of the buffer write completion pointer and increments the buffer write cycle counter value by +1.
  • the buffer read control unit 140 completes the buffer read 1, the buffer read control unit 140 updates the buffer read pointer to 00h.
  • the data non-destructive control unit 160 detects “buffer write cycle counter value> buffer read cycle counter value”, determines that data preparation is complete, and outputs a transfer destination writable instruction.
  • the buffer read control unit 140 detects a transfer destination writable instruction, it issues a buffer read 2 to the area of the address 00h to 18h of the internal buffer 130.
  • the transfer destination write control unit 150 issues a write 2 (4 burst write) to the area to the transfer destination addresses 40h to 58h.
  • the buffer read control unit 140 completes the buffer read 2
  • the buffer read pointer is updated to 20h, and a wraparound occurs.
  • the buffer read cycle count unit 180 detects wraparound and increments the buffer read cycle counter value by +1.
  • the buffer read control unit 140 detects a transfer destination writable instruction, it issues a buffer read 3 to the area of addresses 20h to 38h of the internal buffer 130.
  • the transfer destination write control unit 150 issues a write 3 (4 burst write) to the area to the transfer destination addresses 20h to 38h.
  • the procedure 5 shown in FIG. 21 shows the DMA transfer result. As shown in the transfer destination, the data transfer has been completed without causing data corruption.
  • FIGS. 22 to 26 are diagrams showing changes in data during DMA transfer when data larger than the size of the internal buffer 130 is DMA-transferred and the buffer read pointer wraps around first. That is, FIG. 22 to FIG. 26 are diagrams showing changes in data when “buffer write cycle counter value ⁇ buffer read cycle counter value”.
  • the size of the internal buffer 130 is 64 bytes, and one square is 2 bytes.
  • the transfer source and transfer destination in FIGS. 22 to 26 are the same device, and one square indicates 2 bytes.
  • the data in the transfer source addresses 08h to 58h is decrementally transferred to the transfer destination addresses 20h to 70h.
  • the DMA transfer control device 100 issues to the transfer source in the order of read 1 (4 burst read), read 2 (4 burst read), and read 3 (3 burst read). Also, the DMA transfer control device 100 issues to the transfer destination in the order of write 1 (3 burst write), write 2 (4 burst write), and write 3 (4 burst write). When the read destination and write destination addresses cross a 32-byte boundary, a burst transfer command of 3 bursts or less is issued as a fraction processing.
  • the read order shown on the right side of the transfer source in FIGS. 22 to 26 indicates the order in which the DMA transfer control device 100 obtains the read data, receives the read data in the order of R1 to R11, and the internal buffer in the same order. Write to 130.
  • the write order shown on the right side of the transfer destination indicates the order in which the DMA transfer control device 100 outputs data to the transfer destination.
  • the internal buffer 130 write data is received in the order of W1 to W11, and the transfer order is set in the same order.
  • the buffer write completion pointer indicates an area where data is prepared in the internal buffer 130
  • the buffer read pointer indicates an area read by the internal buffer 130.
  • the buffer write cycle counter indicates the number of times the buffer write completion pointer wraps around
  • the buffer read cycle counter indicates the number of times the buffer read pointer wraps around. Both pointers are incremented by +1 every time they wrap around.
  • the transfer source read control unit 110 issues a read 1 (4 burst read) to the area of the transfer source addresses 40h to 58h.
  • the buffer write control unit 120 issues the buffer write 1 corresponding to the read 1 to the internal buffer 130 and writes the read data in the areas of the addresses 20h to 38h.
  • the buffer write control unit 120 updates the buffer write completion pointer to 20h.
  • the buffer read control unit 140 sets the buffer read pointer in the data read area (28h) output by the write 1 (3 burst write) issued to the transfer destination.
  • the buffer read control unit 140 detects the transfer destination write enable instruction, the buffer read control unit 140 issues buffer read 1 to the area of the address 28h to 38h of the internal buffer 130 and reads the transfer destination write data.
  • the transfer destination write control unit 150 issues write 1 (3-burst write) to the transfer destination addresses 60h to 70h.
  • the transfer source read control unit 110 issues a read 2 (4 burst read) to the area of the transfer source addresses 20h to 38h.
  • the buffer write control unit 120 issues the buffer write 2 corresponding to the read 2 to the internal buffer 130 and writes the read data in the area of addresses 00h to 18h.
  • the buffer write control unit 120 updates the buffer write completion pointer to 00h.
  • the buffer read control unit 140 updates the buffer read pointer to 08h.
  • the buffer read control unit 140 detects the transfer destination write enable instruction
  • the buffer read control unit 140 issues buffer read 2 to the area of the address 08h to 20h of the internal buffer 130 to read the transfer destination write data.
  • the transfer destination write control unit 150 issues a write 2 (4 burst write) to the area of the transfer destination addresses 40h to 58h.
  • the transfer source read control unit 110 issues a read 3 (3 burst read) to the area of the transfer source addresses 08h to 18h.
  • the buffer write control unit 120 issues the buffer write 3 corresponding to the read 3 to the internal buffer 130 and writes the read data in the areas of the addresses 28h to 38h.
  • the buffer write 3 has not been completed and the buffer write completion pointer has not been updated. Since the buffer read control unit 140 has completed buffer read 2, the buffer read pointer is updated to 28h, and wraparound occurs.
  • the buffer read cycle count unit 180 detects wraparound and increments the buffer read cycle counter value by +1.
  • the data non-destructive control unit 160 detects “buffer write cycle counter value ⁇ buffer read cycle counter value”, determines that data preparation is not completed, and does not output a transfer destination write enable instruction (transfer destination write disabled). Since the buffer read control unit 140 does not detect the transfer destination write enable instruction, it does not issue the next buffer read to the internal buffer 130. Similarly, the transfer destination write control unit 150 does not issue the next write 3 (4 burst write) to the transfer destination.
  • buffer write 3 is completed.
  • the buffer write control unit 120 updates the buffer write completion pointer to 28h, and wraparound occurs.
  • the buffer write cycle count unit 170 detects a wraparound of the buffer write completion pointer and increments the buffer write cycle counter value by +1.
  • the buffer read control unit 140 detects the transfer destination write enable instruction, the buffer read control unit 140 issues buffer read 3 to the area of the address 28h to 00h of the internal buffer 130 and reads the transfer destination write data.
  • the transfer destination write control unit 150 issues a write 3 (4 burst write) to the area of the transfer destination addresses 20h to 38h.
  • the procedure 5 shown in FIG. 26 shows the DMA transfer result. As shown in the transfer destination, the data transfer has been completed without causing data corruption.
  • buffer write cycle counter value buffer read cycle counter value”.
  • the size of the internal buffer 130 is 64 bytes, and one square has 2 bytes.
  • the transfer source and transfer destination in FIGS. 27 to 31 are the same device, and one square indicates 2 bytes. In the example of FIGS.
  • the data in the area of the transfer source address 00h to 30h is decrementally transferred to the area of the transfer destination address 18h to 48h.
  • the DMA transfer control device 100 issues to the transfer source in the order of read 1 (3 burst read) and read 2 (4 burst read).
  • the DMA transfer control device 100 issues to the transfer destination in the order of write 1 (4 burst write) and write 2 (3 burst write).
  • write 1 (4 burst write)
  • write 2 (3 burst write).
  • a burst transfer command of 3 bursts or less is issued as a fraction processing.
  • the read order shown on the right side of the transfer source in FIGS. 27 to 31 indicates the order in which the DMA transfer control device 100 obtains the read data.
  • the read data is received in the order of R1 to R7, and the internal buffer is in the same order.
  • the write order shown on the right side of the transfer destination indicates the order in which the DMA transfer control device 100 outputs data to the transfer destination.
  • the write data is received from the internal buffer 130 in the order of W1 to W7, and the transfer destination in the same order.
  • the buffer write completion pointer indicates an area where data is prepared in the internal buffer 130
  • the buffer read pointer indicates an area read by the internal buffer 130.
  • the buffer write cycle counter indicates the number of times the buffer write completion pointer wraps around
  • the buffer read cycle counter indicates the number of times the buffer read pointer wraps around. Both pointers are incremented by +1 every time they wrap around.
  • S11 the following setting information is set in the DMA transfer control device 100.
  • Source address 00h Forwarding address: 30h Transfer size: 56 bytes Transfer type: Decrement transfer
  • S12 the data non-destructive control unit 160 notifies each control unit and each count unit that it is a decrement transfer. Then, the process proceeds to S14, and DMA transfer by decrement transfer is executed.
  • the transfer source read control unit 110 issues a read 1 (3-burst read) to the area of the transfer source addresses 20h to 30h.
  • the buffer write control unit 120 issues the buffer write 1 corresponding to the read 1 to the internal buffer 130 and writes the read data in the areas of the addresses 28h to 38h.
  • the buffer write control unit 120 updates the buffer write completion pointer to 28h.
  • the buffer read control unit 140 sets the buffer read pointer in the data read area (20h) output by the write 1 (4 burst write) issued to the transfer destination.
  • the transfer source read control unit 110 issues a read 2 (4 burst read) to the area of the transfer source addresses 00h to 18h.
  • the buffer write control unit 120 issues the buffer write 2 corresponding to the read 2 to the internal buffer 130 and writes the read data in the area of addresses 08h to 20h.
  • the buffer read control unit 140 Since the buffer read control unit 140 has not detected the transfer destination write enable instruction, it does not issue buffer read 1. Similarly, the transfer destination write control unit 150 does not issue a write 1. In the state of the procedure 2, there is a data amount (4 bursts) necessary for the next write 1, but a necessary data type (data of 13 to 28) is not prepared, so it is determined that data preparation is not completed. .
  • the buffer write 2 is completed, and the buffer write control unit 120 updates the buffer write completion pointer to 08h.
  • the buffer read control unit 140 detects the transfer destination write enable instruction, the buffer read control unit 140 issues buffer read 1 to the area of the address 20h to 38h of the internal buffer 130 and reads the transfer destination write data.
  • the transfer destination write control unit 150 issues a write 1 (4 burst write) to the transfer destination addresses 30h to 48h.
  • the buffer read control unit 140 updates the buffer read pointer to 08h.
  • the buffer read control unit 140 detects the transfer destination write enable instruction, it issues a buffer read 2 to the area of the address 08h to 18h of the internal buffer 130 and reads the transfer destination write data.
  • the transfer destination write control unit 150 issues a write 2 (3 burst write) to the area of the transfer destination addresses 18h to 28h.
  • the procedure 5 shown in FIG. 31 shows the DMA transfer result. As shown in the transfer destination, the data transfer has been completed without causing data corruption.
  • Embodiment 2 the CPU 200 specifies whether to perform increment transfer or decrement transfer. That is, the CPU 200 has to determine whether to perform increment transfer or decrement transfer.
  • the DMA transfer control device 100 appropriately determines whether to perform increment transfer or decrement transfer according to the state of overlap between the transfer source area and the transfer destination area. .
  • the DMA transfer control device 100 according to the second embodiment differs from the DMA transfer control device 100 according to the first embodiment only in the configuration of the data nondestructive control unit 160.
  • FIG. 32 is a configuration diagram of the data nondestructive control unit 160 according to the second embodiment.
  • the data nondestructive control unit 160 according to the second embodiment does not include the transfer type setting register 161 provided in the data nondestructive control unit 160 according to the first embodiment.
  • the data nondestructive control unit 160 according to the second embodiment includes a data nondestructive function ON / OFF setting register 191, a transfer source address setting register 192, a transfer destination address setting register 193, a transfer size setting register 194, a transfer A type determination unit 195 is provided.
  • the data non-destructive function ON / OFF setting register 191 it is set whether the data non-destructive function is ON (valid) or OFF (invalid).
  • the transfer source address setting register 192 the start address of the transfer source area is set.
  • the transfer destination address setting register 193 the start address of the transfer destination area is set.
  • the transfer size setting register 194 the size of transfer data is set.
  • the transfer type determination unit 195 determines the transfer type as follows and notifies each control unit. (A) If the transfer source area and the transfer destination area do not overlap, it is determined that the transfer is increment transfer. (B) When the transfer source area and the transfer destination area overlap, determination is made as in the following (a) to (c). (A) If the transfer source area and the transfer destination area are exactly the same area, it is determined that the transfer is increment transfer.
  • (B) The address value of the address (start address of the transfer source area) set in the transfer source address setting register 192 is greater than the address value of the address (start address of the transfer destination area) set in the transfer destination address setting register 193. If it is smaller, it is judged as decrement transfer.
  • (C) The address value of the address (start address of the transfer source area) set in the transfer source address setting register 192 is greater than the address value of the address (start address of the transfer destination area) set in the transfer destination address setting register 193. If it is larger, it is determined as increment transfer.
  • the transfer type determination unit 195 always notifies increment control and each control unit.
  • FIG. 33 is a flowchart showing the overall operation of the DMA transfer control apparatus 100 according to the second embodiment.
  • S71 is the same as S11 of FIG. At this time, whether to turn the data non-destructive function ON or OFF is also set in the register.
  • the data nondestructive control unit 160 determines whether or not the setting of the register (data nondestructive function ON / OFF setting register 191) is ON. If it is ON, the process proceeds to S73. If it is OFF, the control unit is notified of the incremental transfer, and the process proceeds to S75. In S73, the data nondestructive control unit 160 determines whether the transfer is increment transfer or decrement transfer.
  • decrement transfer the control unit is notified of decrement transfer, and the process proceeds to S74.
  • incremental transfer each control unit is notified that it is incremental transfer, and the process proceeds to S75.
  • S74 the DMA transfer control device 100 performs decrement transfer to the memory 300.
  • S75 the DMA transfer control device 100 performs an incremental transfer to the memory 300.
  • S76 the transfer operation is stopped when there is a DMA transfer stop factor, such as when the DMA transfer control device 100 has finished transferring the specified data length.
  • the CPU 200 determines an appropriate transfer type on the DMA transfer control device 100 side without instructing the transfer type, and then performs data transfer. It can be carried out.
  • each control unit is configured by, for example, a circuit or the like, and “ ⁇ unit” may be replaced with “ ⁇ circuit”.
  • 10 DMA transfer system 100 DMA transfer control device, 110 transfer source read control unit, 120 buffer write control unit, 130 internal buffer, 140 buffer read control unit, 150 transfer destination write control unit, 160 data nondestructive control unit, 161 transfer Type setting register, 162 Buffer write completion pointer setting register, 163 Buffer read pointer setting register, 164 First buffer preparation completion determination unit, 165 Second buffer preparation completion determination unit, 166 Wraparound count match determination unit, 167 selector, 170 buffer Write cycle count unit, 171 wraparound detection unit, 172 wraparound frequency count unit, 180 buffer read cycle count unit, 181 wraparound detection unit, 182 Flop around number count section 191 data nondestructive function ON / OFF setting register 192 transfer source address setting register 193 transfer destination address setting register 194 transfer size setting register, 195 transfer type determination unit, 200 CPU, 300 memory.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Bus Control (AREA)
  • Communication Control (AREA)
  • Information Transfer Systems (AREA)

Abstract

 データの転送元領域と転送先領域とが重なった場合において、バースト転送機能を用いて転送を行った場合であっても、データ破壊の発生を防止することを目的とする。転送元領域から読み出したデータをリングバッファへ一旦書き込み、リングバッファに書き込まれたデータを転送先領域へ書き込む。この際、リングバッファにおけるデータの書き込みによるラップアラウンドの回数と、データを読み出しによるラップアラウンドの回数との大小関係に基づき、リングバッファからのデータ読み出しを制御する。

Description

データ転送装置、データ転送方法及びデータ転送プログラム
 この発明は、転送元領域に記憶されたデータを転送先領域へ転送するデータ転送技術に関する。
 データ転送技術には、DMA(Direct Memory Access)転送と呼ばれる技術がある。
 DMA転送では、まず、CPU(Central Processing Unit)が、データ転送元アドレス、データ転送先アドレス、データ転送サイズ等の転送に必要なDMA情報をDMA転送制御装置のレジスタに設定する。そして、CPUがDMA転送制御装置へ転送開始を指示すると、DMA転送制御装置はレジスタに設定されたDMA情報に従い転送処理を実行する。DMA転送制御装置は、レジスタに設定された転送サイズ分のデータ転送を完了したら、DMA転送終了割込みをCPUへアサートする。CPUは、DMA転送終了割込みを検知すると、DMA転送制御装置のレジスタの情報を読み込んで、DMA転送の結果やステータスを確認する。
 DMA転送制御装置が転送処理を実行している間、CPUによる転送制御の必要はない。そのため、DMA転送では、CPUを経由してデータ転送を行う場合に比べて高速にデータ転送を行うことができる。また、DMA転送では、CPUの負担を減らすことができる。
 一般的なDMA転送では、設定されたサイズ(単位量)ごとに必要なデータの読み出しを行ない、その後の書き込みを行う。書き込みの開始タイミングが読み出しの完了後になるため、レイテンシが大きなデバイスへの転送では、転送効率が良くない。
 AXI(Advanced eXtensible Interface)バスを使用したDMA転送制御装置がある。
 AXIバスは、リード専用バスとライト専用バスとを備えており、リード専用バスを使ったデータ転送元領域からのデータ取得と、ライト専用バスを使ったデータ転送先領域へのデータ転送とをパラレルに実行できる。
 また、AXIバスは、バースト転送機能を備えている。バースト転送機能は、1回のリード要求で複数の単位量のリードデータを取得でき、1回のライト要求で複数の単位量のライトが実行できる機能である。
 AXIバスを使用したDMA転送制御装置では、上記のリード/ライト専用バスやバースト転送機能を用いることにより、高速転送が可能である。
特開平10-116245号公報 特開2008-83911号公報
 DMA転送では、データの転送元領域と転送先領域とが重なった場合、データ破壊が発生する場合がある。特に、バースト転送機能を用いて転送を行った場合、データ破壊を防止することが困難である。
 この発明は、データの転送元領域と転送先領域とが重なった場合におけるデータ破壊の発生を防止することを目的とする。特に、バースト転送機能を用いて転送を行った場合であっても、データ破壊の発生を防止することを目的とする。
 この発明に係るデータ転送装置は、
 転送元領域に記憶されたデータを転送先領域へ転送するデータ転送装置であり、
 前記転送元領域に記憶されたデータを読み出すリードコマンドを出力する転送元リード制御部と、
 前記転送元リード制御部が出力したリードコマンドによって読み出されたデータを取得してリングバッファへ書き込むバッファライト制御部と、
 前記バッファライト制御部が書き込んだデータを前記リングバッファから読み出して、前記転送先領域へ送信するバッファリード制御部と、
 前記バッファリード制御部が前記転送先領域へ送信したデータを、前記転送先領域へ書き込むライトコマンドを出力する転送先ライト制御部と、
 前記バッファライト制御部によるラップアラウンドの回数をカウントするライト周期カウント部と、
 前記バッファリード制御部によるラップアラウンドの回数をカウントするリード周期カウント部と、
 前記ライト周期カウント部がカウントした回数と、前記リード周期カウント部がカウントした回数との大小関係から、前記転送先領域へのデータ書き込みを許可するか否かを判定するデータ非破壊制御部と
を備え、
 前記バッファリード制御部は、書き込みを許可すると前記データ非破壊制御部が判定した場合に、データを前記リングバッファから読み出し、
 前記転送先ライト制御部は、書き込みを許可すると前記データ非破壊制御部が判定した場合に、前記ライトコマンドを出力して、前記バッファリード制御部が前記転送先領域へ送信したデータを前記転送先領域へ書き込む
ことを特徴とする。
 この発明に係るデータ転送装置によれば、バッファ領域からのデータ読み出しのタイミングを調整することにより、データ破壊の発生を防ぐことができる。
データ破壊が発生する場合の説明図。 データ破壊が発生する場合の説明図。 バースト転送機能を用いた場合におけるデータ転送の順序の説明図。 実施の形態1に係るDMA転送システム10の構成図。 実施の形態1に係るDMA転送制御装置100の構成図。 実施の形態1に係るデータ非破壊制御部160の構成図。 実施の形態1に係るバッファライト周期カウント部170の構成図。 実施の形態1に係るバッファリード周期カウント部180の構成図。 実施の形態1に係るDMA転送制御装置100全体の動作を示すフローチャート。 実施の形態1に係る転送元リード制御部110の動作を示すフローチャート。 実施の形態1に係るバッファライト制御部120の動作を示すフローチャート。 バッファリード制御部140の動作を示すフローチャート。 実施の形態1に係る転送先ライト制御部150の動作を示すフローチャート。 実施の形態1に係るデータ非破壊制御部160の動作を示すフローチャート。 実施の形態1に係るバッファライト周期カウント部170の動作を示すフローチャート。 実施の形態1に係るバッファリード周期カウント部180の動作を示すフローチャート。 DMA転送時におけるデータの変化を示す図(1-1)。 DMA転送時におけるデータの変化を示す図(1-2)。 DMA転送時におけるデータの変化を示す図(1-3)。 DMA転送時におけるデータの変化を示す図(1-4)。 DMA転送時におけるデータの変化を示す図(1-5)。 DMA転送時におけるデータの変化を示す図(2-1)。 DMA転送時におけるデータの変化を示す図(2-2)。 DMA転送時におけるデータの変化を示す図(2-3)。 DMA転送時におけるデータの変化を示す図(2-4)。 DMA転送時におけるデータの変化を示す図(2-5)。 DMA転送時におけるデータの変化を示す図(3-1)。 DMA転送時におけるデータの変化を示す図(3-2)。 DMA転送時におけるデータの変化を示す図(3-3)。 DMA転送時におけるデータの変化を示す図(3-4)。 DMA転送時におけるデータの変化を示す図(3-5)。 実施の形態2に係るデータ非破壊制御部160の構成図。 実施の形態2に係るDMA転送制御装置100全体の動作を示すフローチャート。
 実施の形態1.
 図1、図2は、データ破壊が発生する場合の説明図である。特に、図1は、データの転送元領域と転送先領域とが順方向にずれている場合の説明図である。図2は、データの転送元領域と転送先領域とが逆方向にずれている場合の説明図である。
 図1に基づき、データの転送元領域と転送先領域との一部が重なりつつ、データの転送元領域と転送先領域とが順方向にずれている場合について説明する。転送元領域と転送先領域とが順方向にずれているとは、転送元領域の先頭アドレスのアドレス値が、転送先領域の先頭アドレスのアドレス値よりも小さい場合である。
 図1では、転送元領域と転送先領域とが同じデバイスにおける領域であり、領域Bが重なっている。また、図1では、転送元領域の先頭アドレスである領域Aの先頭アドレスのアドレス値は、転送先領域の先頭アドレスである領域Bの先頭アドレスのアドレス値よりも小さく、転送元領域と転送先領域とが順方向にずれている。
 この場合、アドレス値の昇順方向(インクリメント方向)へ順次データ転送を行うと、まず、領域Aのデータが領域Bへ書き込まれ、その後、領域Bのデータが領域Cへ書き込まれることになる。この場合、領域Bのデータが領域Cへ書き込まれる前に、領域Bへ領域Aのデータが書き込まれてしまい、元々領域Bに記憶されていたデータが破壊されてしまう。
 そこで、この場合、アドレス値の降順方向(デクリメント方向)へ順次データ転送を行うようにする。すると、まず、領域Bのデータが領域Cへ書き込まれ、その後、領域Aのデータが領域Bへ書き込まれる。そのため、データが破壊されることなく、転送が行える。
 図2に基づき、データの転送元領域と転送先領域との一部が重なりつつ、データの転送元領域と転送先領域とが逆方向にずれている場合について説明する。転送元領域と転送先領域とが逆方向にずれているとは、転送元領域の先頭アドレスのアドレス値が、転送先領域の先頭アドレスのアドレス値よりも大きい場合である。
 図2でも、図1と同様に、転送元領域と転送先領域とが同じデバイスにおける領域であり、領域Bが重なっている。しかし、図2では、転送元領域の先頭アドレスである領域Bの先頭アドレスのアドレス値は、転送先領域の先頭アドレスである領域Aの先頭アドレスのアドレス値よりも大きく、転送元領域と転送先領域とが逆方向にずれている。
 この場合、アドレス値の降順方向(デクリメント方向)へ順次データ転送を行うと、まず、領域Cのデータが領域Bへ書き込まれ、その後、領域Bのデータが領域Aへ書き込まれることになる。この場合、領域Bのデータが領域Aへ書き込まれる前に、領域Bへ領域Cのデータが書き込まれてしまい、元々領域Bに記憶されていたデータが破壊されてしまう。
 そこで、この場合、アドレス値の昇順方向(インクリメント方向)へ順次データ転送を行うようにする。すると、まず、領域Bのデータが領域Aへ書き込まれ、その後、領域Cのデータが領域Bへ書き込まれる。そのため、データが破壊されることなく、転送が行える。
 つまり、転送元領域と転送先領域とが順方向にずれている場合には、アドレス値の降順方向へ順次データ転送を行うデクリメント転送を行えばデータ破壊は発生しない。一方、転送元領域と転送先領域とが逆方向にずれている場合には、アドレス値の昇順方向へ順次データ転送を行うインクリメント転送を行えばデータ破壊は発生しない。
 図3は、バースト転送機能を用いた場合におけるデータ転送の順序の説明図である。図3では、バースト転送機能を用いてデクリメント方向のデータ転送を行う場合を示している。
 通常のデータ転送では、1回のリード/ライト要求で1個の単位量のデータの転送のみ可能である。これに対して、バースト転送機能を用いた場合、1回のリード/ライト要求で複数個の単位量のデータの転送が可能である。
 図3では、データ1~8の8個の単位量のデータの転送を行うことを想定している。そのため、通常のデータ転送では、8回のリード/ライト要求が必要となる。これに対して、バースト転送機能を用いた場合、2回のリード/ライト要求で転送が可能である。なお、ここでは、1回のリード/ライト要求で4個の単位量のデータの転送が可能な4バースト転送を想定している。
 ここで、バーストリードコマンド(トランザクション)の発行順序は、インクリメント方向にもデクリメント方向にもできる。しかし、バーストリードコマンド内におけるデータの読み出し順序は、インクリメント方向にしかできない。そのため、図3に示すように、データ5~8を読み出す4バーストリードコマンドを1個目、データ1~4を読み出す4バーストリードコマンドを2個目というデクリメント方向の順にバーストリードコマンドを発行しても、データの読み出し順序は、データ5,6,7,8,1,2,3,4の順になってしまう。つまり、データ8,7,6,5,4,3,2,1の順に読み出すことはできない。
 したがって、転送元領域と転送先領域とが順方向にずれている場合において、バースト転送機能を用いてデータ転送を行うと、デクリメント転送を用いてもデータ破壊を防止することはできない。
 なお、バーストライトコマンドの場合も、バーストリードコマンドの場合と同様に、バーストライトコマンドの発行順序は、インクリメント方向にもデクリメント方向にもできる。しかし、バーストライトコマンド内におけるデータの書き込み順序は、インクリメント方向にしかできない。
 図4は、実施の形態1に係るDMA転送システム10の構成図である。
 DMA転送システム10は、DMA転送制御装置100(データ転送装置)、CPU200、メモリ300を備える。
 DMA転送制御装置100は、CPU200等の使用者によってレジスタに設定されたDMA情報に従い、メモリ300にアクセスしてデータ転送を行う装置である。
 CPU200は、転送元領域を指定する転送元アドレス、転送先領域を指定する転送先アドレス、転送データのサイズを指定する転送サイズ、転送タイプ(インクリメント転送又はデクリメント転送)のDMA情報をDMA転送制御装置100のレジスタに設定し、DMA転送制御装置100にデータ転送を実行させる。ここでは、CPU200がDMA情報を設定するとしたが、CPU200ではなく、他の装置やシステムがDMA情報を設定してもよい。
 メモリ300は、データ転送の転送元領域及び転送先領域となる対象リソースである。
 図5は、実施の形態1に係るDMA転送制御装置100の構成図である。
 なお、図5において、実線はデータが流れるデータ線を表し、破線は制御信号が流れる制御線を表す。
 DMA転送制御装置100は、転送元リード制御部110、バッファライト制御部120、内部バッファ130(リングバッファ)、バッファリード制御部140、転送先ライト制御部150、データ非破壊制御部160、バッファライト周期カウント部170、バッファリード周期カウント部180を備える。
 転送元リード制御部110は、メモリ300の転送元領域に記憶されたデータを読み出す転送元リードコマンドをメモリ300へ出力する。
 転送元リードコマンドは、リードアドレス、リードアドレス有効信号(もしくは、リード要求信号)、その他(バーストサイズ、バースト長)の信号をまとめた情報である。
 バッファライト制御部120は、転送元リード制御部110が出力した転送元リードコマンドによって読み出された転送元リードデータをリード専用バスを介して取得する。
 また、バッファライト制御部120は、取得した転送元リードデータをバッファライトデータとして内部バッファ130へ出力し、内部バッファ130におけるバッファライトポインタによって指定した位置にバッファライトデータを書き込む。バッファライトポインタは、現在のバッファライト先を示した情報である。
 バッファライト制御部120は、バッファライトデータの書き込みが完了した位置をバッファライト完了ポインタとして、データ非破壊制御部160へ通知する。バッファライト完了ポインタは、言い替えれば、内部バッファ130における読み出し準備が完了した完了領域を示した情報である。
 内部バッファ130は、DMA転送制御装置100に内蔵された転送データ格納用のリソースである。
 バッファリード制御部140は、内部バッファ130におけるバッファリードポインタによって指定した位置からデータをバッファリードデータとして読み出す。バッファリードポインタは、現在のバッファリード先を示した情報である。
 また、バッファリード制御部140は、読み出したバッファリードデータを転送先ライトデータとしてライト専用バスを介してメモリ300へ出力する。
 バッファリード制御部140は、バッファリードポインタをデータ非破壊制御部160へ通知する。
 転送先ライト制御部150は、メモリ300へ転送先ライトコマンドを出力して、バッファリード制御部140が出力した転送先ライトデータを転送先領域に書き込む。
 転送先ライトコマンドは、ライトアドレス、ライトアドレス有効信号(もしくは、ライト要求信号)、ライトデータ有効信号、その他(バーストサイズ、バースト長、ストローブ信号)の信号をまとめた情報である。
 データ非破壊制御部160は、CPU200によって設定された転送タイプ(インクリメント転送又はデクリメント転送)を各制御部、各カウント部へ通知する。なお、各制御部とは、転送元リード制御部110、バッファライト制御部120、バッファリード制御部140、転送先ライト制御部150のことである。また、各カウント部とは、バッファライト周期カウント部170、バッファリード周期カウント部180のことである。
 また、データ非破壊制御部160は、デクリメント転送の場合、「バッファライト周期カウント部170がカウントしたラップアラウンドの回数(バッファライト周期カウンタ値)と、バッファリード周期カウント部180がカウントしたラップアラウンドの回数(バッファリード周期カウンタ値)との大小関係」と、「バッファライト完了ポインタの値と、バッファリードポインタの値の大小関係」とに基づき、バッファリードポインタが示す位置のデータ読み出し準備ができているか否かを判定する。そして、データ非破壊制御部160は、データ読み出し準備ができていると判定した場合に、転送先ライト可能指示をバッファリード制御部140、転送先ライト制御部150へ出力する。なお、データ非破壊制御部160は、インクリメント転送の場合、バッファライト完了ポインタやバッファリードポインタに関わらず、常に転送先ライト可能指示を出力する。
 バッファリード制御部140は、データ非破壊制御部160から転送先ライト可能指示を受信すると、内部バッファ130からデータを読み出す。また、転送先ライト制御部150は、データ非破壊制御部160から転送先ライト可能指示を受信すると、転送先ライトコマンドを出力する。
 バッファライト周期カウント部170は、デクリメント転送の場合、バッファライト完了ポインタがラップアラウンドした回数をカウントするカウンタである。
 バッファリード周期カウント部180は、デクリメント転送の場合、バッファリードポインタがラップアラウンドした回数をカウントするカウンタである。
 なお、リード専用バスは、転送元リードコマンド、転送元リードデータを流すバスであり、ライト専用バスは、転送先ライトコマンド、転送先ライトデータを流すバスである。リード専用バスとライト専用バスとには依存関係がなく、パラレルに動作可能である。
 図6は、実施の形態1に係るデータ非破壊制御部160の構成図である。
 データ非破壊制御部160は、転送タイプ設定レジスタ161、バッファライト完了ポインタ設定レジスタ162、バッファリードポインタ設定レジスタ163、第1バッファ準備完了判断部164、第2バッファ準備完了判断部165、ラップアラウンド回数一致判断部166、セレクタ167を備える。
 転送タイプ設定レジスタ161には、CPU200から転送タイプが設定される。転送タイプ設定レジスタ161に設定された転送タイプがデータ非破壊制御部160から各制御部へ通知される。
 バッファライト完了ポインタ設定レジスタ162には、バッファライト制御部120からバッファライト完了ポインタが設定される。
 バッファリードポインタ設定レジスタ163には、バッファリード制御部140からバッファリードポインタが設定される。
 第1バッファ準備完了判断部164は、転送タイプ、バッファライト完了ポインタ、バッファリードポインタに基づき、内部バッファ130からのデータ読み出し準備が完了しているか否かを判断する。データ読み出し準備が完了していると判定した場合、データ破壊が発生しないと判定し、セレクタ167へ転送先ライト可能指示(ポインタ)を出力する。
 第2バッファ準備完了判断部165は、バッファライト周期カウント部170から得たバッファライト周期カウンタ値と、バッファリード周期カウント部180から得たバッファリード周期カウンタ値とに基づき、内部バッファ130からのデータ読み出し準備が完了しているか否かを判断する。データ読み出し準備完了していると判定した場合、データ破壊が発生しないと判定し、セレクタ167へ転送先ライト可能指示(カウンタ)を出力する。
 ラップアラウンド回数一致判断部166は、バッファライト周期カウント部170から得たバッファライト周期カウンタ値と、バッファリード周期カウント部180から得たバッファリード周期カウンタ値とが一致しているか否かを判断する。
 セレクタ167は、ラップアラウンド回数一致判断部166の判断結果に基づいて、第1バッファ準備完了判断部164から出力された転送先ライト可能指示(ポインタ)と、第2バッファ準備完了判断部165から出力された転送先ライト可能指示(カウンタ)とのどちらを転送先ライト可能指示として出力するかを選択する。セレクタ167は、選択した転送先ライト可能指示を、バッファリード制御部140と転送先ライト制御部150とへ出力する。
 図7は、実施の形態1に係るバッファライト周期カウント部170の構成図である。
 バッファライト周期カウント部170は、ラップアラウンド検出部171、ラップアラウンド回数カウント部172を備える。
 ラップアラウンド検出部171は、デクリメント転送の場合、バッファライト完了ポインタがラップアラウンドしたか否かを検出する。
 ラップアラウンド回数カウント部172は、ラップアラウンド検出部171がラップアラウンドを検出した場合にバッファライト周期カウンタ値を+1カウントアップする。そして、ラップアラウンド回数カウント部172は、カウントアップしたバッファライト周期カウンタ値をデータ非破壊制御部160へ出力する。
 図8は、実施の形態1に係るバッファリード周期カウント部180の構成図である。
 バッファリード周期カウント部180は、ラップアラウンド検出部181、ラップアラウンド回数カウント部182を備える。
 ラップアラウンド検出部181は、デクリメント転送の場合、バッファリードポインタがラップアラウンドしたか否かを検出する。
 ラップアラウンド回数カウント部182は、ラップアラウンド検出部181がラップアラウンドを検出した場合にバッファリード周期カウンタ値を+1カウントアップする。そして、ラップアラウンド回数カウント部182は、カウントアップしたバッファリード周期カウンタ値をデータ非破壊制御部160へ出力する。
 次に、DMA転送制御装置100の動作について説明する。
 図9は、実施の形態1に係るDMA転送制御装置100全体の動作を示すフローチャートである。
 S11では、CPU200がDMA転送制御装置100のレジスタにDMA情報を設定し、DMA転送制御装置100を起動する。すると、S12では、DMA転送制御装置100のデータ非破壊制御部160がレジスタ(転送タイプ設定レジスタ161)に設定された転送タイプ(インクリメント転送、又は、デクリメント転送)を各制御部へ通知する。レジスタにインクリメント転送が設定された場合、処理をS13へ進め、デクリメント転送が設定された場合、処理をS14へ進める。
 S13では、DMA転送制御装置100がメモリ300に対してインクリメント転送を行う。一方、S14では、DMA転送制御装置100がメモリ300に対してデクリメント転送を行う。
 そして、S15では、DMA転送制御装置100が指定されたデータ長のデータを転送し終えた場合等、DMA転送停止要因があったときに転送動作を停止する。
 図10は、実施の形態1に係る転送元リード制御部110の動作を示すフローチャートである。なお、図10は、図9におけるS13又はS14における転送元リード制御部110の動作を示す。
 S21では、転送元リード制御部110がデータ非破壊制御部160から送信された転送タイプに基づき、インクリメント転送かデクリメント転送かを判定する。インクリメント転送と判定した場合、処理をS22へ進め、デクリメント転送と判定した場合、処理をS23へ進める。
 S22及びS23では、転送元リード制御部110が1つのバーストリードコマンドを転送元リードコマンドとして生成する。バーストリードコマンドは、図3に基づき説明したように、単位量のデータづつ所定個の単位量のデータをリード開始アドレスからアドレス値の昇順に読み出すコマンドである。
 S22,S23に続いて、S24では、転送元リード制御部110が、転送元リードコマンドによって読み出されるデータを格納する空き領域が内部バッファ130にあるか否かによって、リードアクセス可能か否か判定する。リードアクセス可能と判定した場合(S24でYES)、処理をS25へ進める。一方、リードアクセス不可能と判定した場合(S24でNO)、S24へ処理を戻し、所定の時間経過後再びリードアクセス可能か否か判定する。
 S25では、転送元リード制御部110が生成した転送元リードコマンドをメモリ300に対して発行して、転送元領域からデータを読み出す。
 そして、S26では、転送元リード制御部110が、転送サイズ分のデータを読み出す転送元リードコマンドをメモリ300へ送信したか否かにより、メモリ300へのリードアクセスを終了するか否か判定する。リードアクセスを終了すると判定した場合(S26でYES)、処理を終了する。一方、リードアクセスを終了しないと判定した場合(S26でNO)、処理をS21へ戻す。
 なお、S22では、転送元リード制御部110は、インクリメント方向にバーストリードコマンドを生成する。つまり、バーストリードコマンドのリード開始アドレスのアドレス値が昇順になるように、バーストリードコマンドを生成する。
 一方、S23では、転送元リード制御部110は、デクリメント方向にバーストリードコマンドを生成する。つまり、バーストリードコマンドのリード開始アドレスのアドレス値が降順になるように、バーストリードコマンドを生成する。
 図11は、実施の形態1に係るバッファライト制御部120の動作を示すフローチャートである。なお、図11は、図9におけるS13又はS14におけるバッファライト制御部120の動作を示す。
 S31では、バッファライト制御部120がデータ非破壊制御部160から送信された転送タイプに基づき、インクリメント転送かデクリメント転送かを判定する。インクリメント転送と判定した場合、処理をS32へ進め、デクリメント転送と判定した場合、処理をS33へ進める。
 S32及びS33では、バッファライト制御部120が1つの転送元リードコマンドに対応する1つのバーストライトコマンドをバッファライトコマンドとして生成する。このバッファライトコマンドは、対応する転送元リードコマンドのリード開始アドレスに対応する、内部バッファ130におけるアドレスをライト開始アドレスとして、ライト開始アドレスからアドレス値の昇順にデータを書き込むコマンドである。
 なお、この際、バッファライト制御部120は、リード開始アドレスや、何個の単位量のデータを読み出す転送元リードコマンドを発行するかなどの情報を転送元リード制御部110から取得して、転送元リードコマンドに対応するバッファライトコマンドを生成する。あるいは、バッファライト制御部120は、転送元リード制御部110と同様のロジックにより、リード開始アドレスや、転送元リード制御部110が何個の単位量のデータを読み出す転送元リードコマンドを発行するかなどを判定して、転送元リードコマンドに対応するバッファライトコマンドを生成してもよい。
 また、S33では、バッファライト制御部120は、バッファライト完了ポインタをデータ非破壊制御部160のバッファライト完了ポインタ設定レジスタ162に設定する。この際、バッファライト完了ポインタは、バッファライトポインタが示すアドレス値に、そのライトコマンドで書き込むデータサイズ分のアドレス値を加えたアドレス値を示すものとする。
 S32,S33に続いて、S34では、バッファライト制御部120が内部バッファ130に対してバッファライトコマンドを発行する。これにより、1つの転送元リードコマンドによって転送元領域から読み出されたデータを、内部バッファ130に書き込む。
 そして、S35では、バッファライト制御部120が、転送サイズ分のデータを書き込むバッファライトコマンドを内部バッファ130へ送信したか否かにより、内部バッファ130へのライトアクセスを終了するか否かを判定する。ライトアクセスを終了すると判定した場合(S35でYES)、処理を終了し、ライトアクセスを終了しないと判定した場合(S35でNO)、処理をS31へ戻す。
 なお、S35では、ライトアクセスを終了すると判定した場合(S35でYES)、バッファライト制御部120は、最後に発行したバーストライトコマンドにおけるライト開始アドレスをバッファライト完了ポインタとして、バッファライト完了ポインタ設定レジスタ162に設定した上で、処理を終了する。
 図12は、バッファリード制御部140の動作を示すフローチャートである。なお、図12は、図9におけるS13又はS14におけるバッファリード制御部140の動作を示す。
 S41では、バッファリード制御部140がデータ非破壊制御部160から送信された転送タイプに基づき、インクリメント転送かデクリメント転送かを判定する。インクリメント転送と判定した場合、処理をS42へ進め、デクリメント転送と判定した場合、処理をS43へ進める。
 S42及びS43では、バッファリード制御部140が、1つの転送先ライトコマンドに対応する1つのバーストリードコマンドをバッファリードコマンドとして生成する。このバッファリードコマンドは、対応する転送先ライトコマンドのライト開始アドレスに対応する、内部バッファ130におけるアドレスをリード開始アドレスとして、リード開始アドレスからアドレス値の昇順にデータを読み出すコマンドである。
 なお、この際、バッファリード制御部140は、ライト開始アドレスや、何個の単位量のデータを書き込む転送先ライトコマンドを発行するかなどの情報を転送先ライト制御部150から取得して、転送先ライトコマンドに対応するバッファリードコマンドを生成する。あるいは、バッファリード制御部140は、転送先ライト制御部150と同様のロジックにより、ライト開始アドレスや、転送先ライト制御部150が何個の単位量のデータを書き込む転送先ライトコマンドを発行するかなどを判定して、転送先ライトコマンドに対応するバッファリードコマンドを生成してもよい。
 また、S42及びS43では、バッファリード制御部140は、バッファリードコマンドの生成の際、そのバッファリードコマンドのリード開始アドレスを示すバッファリードポインタをデータ非破壊制御部160のバッファリードポインタ設定レジスタ163に設定する。
 S42,S43に続いて、S44では、バッファリード制御部140が、リードアクセス可能か否か判定する。バッファリード制御部140は、(1)転送先ライトコマンドによって書き込まれるだけのデータが内部バッファ130に格納されており、かつ、(2)データ非破壊制御部160から転送先ライト可能指示を受信した場合に、リードアクセス可能と判定する。リードアクセス可能と判定した場合(S44でYES)、処理をS45へ進める。一方、リードアクセス不可能と判定した場合(S44でNO)、S44へ処理を戻し、所定の時間経過後再びリードアクセス可能か否か判定する。
 S45では、バッファリード制御部140が内部バッファ130に対してバッファリードコマンドを発行する。これにより、1つの転送先ライトコマンドによって転送先領域へ書き込まれるデータを、内部バッファ130から読み出し、メモリ300へ送信する。
 そして、S46では、バッファリード制御部140が、転送サイズ分のデータを読み出すバッファリードコマンドを内部バッファ130へ送信したか否かにより、内部バッファ130へのリードアクセスを終了するか否かを判定する。リードアクセスを終了すると判定した場合(S46でYES)、処理を終了し、リードアクセスを終了しないと判定した場合(S46でNO)、処理をS41へ戻す。
 図13は、実施の形態1に係る転送先ライト制御部150の動作を示すフローチャートである。なお、図13は、図9におけるS13又はS14における転送先ライト制御部150の動作を示す。
 S51では、転送先ライト制御部150がデータ非破壊制御部160から送信された転送タイプに基づき、インクリメント転送かデクリメント転送かを判定する。インクリメント転送と判定した場合、処理をS52へ進め、デクリメント転送と判定した場合、処理をS53へ進める。
 S52及びS53では、転送先ライト制御部150が1つのバーストライトコマンドを転送先ライトコマンドとして生成する。バーストライトコマンドは、図3に基づき説明したように、単位量のデータづつ所定個の単位量のデータをライト開始アドレスからアドレス値の昇順に書き込むコマンドである。
 S52,S53に続いて、S54では、転送先ライト制御部150が、バッファリード制御部140がリードアクセス可能か否か判定する条件と同じ条件により、ライトアクセス可能か否か判定する。つまり、転送先ライト制御部150は、(1)転送先ライトコマンドによって書き込まれるだけのデータが内部バッファ130に格納されており、かつ、(2)データ非破壊制御部160から転送先ライト可能指示を受信した場合に、ライトアクセス可能と判定する。ライトアクセス可能と判定した場合(S54でYES)、処理をS55へ進める。一方、ライトアクセス不可能と判定した場合(S54でNO)、S54へ処理を戻し、所定の時間経過後再びライトアクセス可能か否か判定する。
 S55では、転送先ライト制御部150が生成した転送先ライトコマンドをメモリ300に対して発行して、転送先領域へデータを書き込む。
 そして、S56では、転送先ライト制御部150が、転送サイズ分のデータを書き込む転送先ライトコマンドをメモリ300へ送信したか否かにより、メモリ300へのライトアクセスを終了するか否か判定する。ライトアクセスを終了すると判定した場合(S56でYES)、処理を終了する。一方、ライトアクセスを終了しないと判定した場合(S56でNO)、処理をS51へ戻し、次の転送先ライトコマンドを生成し、メモリ300へ送信して、データを書き込む。
 なお、S52では、転送先ライト制御部150は、インクリメント方向にバーストライトコマンドを生成する。つまり、バーストライトコマンドのライト開始アドレスのアドレス値が昇順になるように、バーストライトコマンドを生成する。
 一方、S53では、転送先ライト制御部150は、デクリメント方向にバーストライトコマンドを生成するということである。つまり、バーストライトコマンドのライト開始アドレスのアドレス値が降順になるように、バーストライトコマンドを生成する。
 図14は、実施の形態1に係るデータ非破壊制御部160の動作を示すフローチャートである。なお、図14は、図9におけるS13又はS14におけるデータ非破壊制御部160の動作を示す。
 S61では、データ非破壊制御部160が、転送タイプ設定レジスタ161に設定された転送タイプに従い、インクリメント転送かデクリメント転送かを判定する。デクリメント転送と判定した場合、処理をS62へ進め、インクリメント転送と判定した場合、処理をS66へ進める。
 S62では、データ非破壊制御部160が、バッファライト周期カウント部170がカウントしたバッファライト周期カウンタ値が、バッファリード周期カウント部180がカウントしたバッファリード周期カウンタ値より大きいか否かを判定する。バッファライト周期カウンタ値がバッファリード周期カウンタ値より大きくない場合(S62でNO)、処理をS63へ進め、バッファライト周期カウンタ値がバッファリード周期カウンタ値より大きい場合(S62でYES)、処理をS66へ進める。
 S63では、データ非破壊制御部160が、バッファライト周期カウント部170がカウントしたバッファライト周期カウンタ値が、バッファリード周期カウント部180がカウントしたバッファリード周期カウンタ値より小さいか否かを判定する。バッファライト周期カウンタ値がバッファリード周期カウンタ値より小さくない場合(S63でNO)、処理をS64へ進める。バッファライト周期カウンタ値がバッファリード周期カウンタ値より小さい場合(S63でYES)、処理をS65へ進める。
 S64では、データ非破壊制御部160が、バッファライト完了ポインタ設定レジスタ162に設定されたバッファライト完了ポインタが示すアドレス値が、バッファリードポインタ設定レジスタ163に設定されたバッファリードポインタが示すアドレス値以下か否かを判定する。バッファライト完了ポインタが示すアドレス値がバッファリードポインタが示すアドレス値以下でない場合(S64でNO)、処理をS65へ進める。一方、バッファライト完了ポインタが示すアドレス値がバッファリードポインタが示すアドレス値以下である場合(S64でYES)、処理をS66へ進める。
 S65では、データ非破壊制御部160は、バッファ読み出しの準備が未完了であると判定し、転送先ライト可能指示を送信しない。一方、S66では、データ非破壊制御部160は、バッファ読み出しの準備が完了したと判定し、バッファリード制御部140と転送先ライト制御部150とへ転送先ライト可能指示を送信する。
 S67では、データ非破壊制御部160は、転送サイズ分のデータの転送が完了したか否かにより、処理を終了するか否か判定する。処理を終了すると判定した場合(S67でYES)、処理を終了する。一方、処理を終了しないと判定した場合(S67でNO)、処理をS61へ戻し、再びバッファの準備が完了したか否かを判定する。
 つまり、インクリメント転送の場合、常にバッファ準備完了と判定される。
 一方、デクリメント転送の場合、
(1)「バッファライト周期カウンタ値>バッファリード周期カウンタ値」が成立したとき、及び、(2)「バッファライト周期カウンタ値=バッファリード周期カウンタ値」が成立し、かつ、「バッファライト完了ポインタが示すアドレス値≦バッファリードポインタが示すアドレス値」が成立したとき、バッファ準備完了と判定される。
 図15は、実施の形態1に係るバッファライト周期カウント部170の動作を示すフローチャートである。なお、図15は、図9におけるS13又はS14におけるバッファライト周期カウント部170の動作を示す。
 S71では、バッファライト周期カウント部170が、データ非破壊制御部160から送信された転送タイプに基づき、インクリメント転送かデクリメント転送かを判定する。デクリメント転送と判定した場合、処理をS72へ進め、インクリメント転送と判定した場合、処理をS74へ進める。
 S72では、バッファライト周期カウント部170が、バッファライト制御部120が生成したバッファライト完了ポインタがラップアラウンドしたか否かを判定する。ラップアラウンドしたと判定した場合(S72でYES)、処理をS73に進める。ラップアラウンドしなかったと判定した場合(S72でNO)、処理をS74へ進める。
 S73では、バッファライト周期カウント部170が、カウンタを+1カウントアップする。
 S74では、バッファライト周期カウント部170が、転送サイズ分のデータの転送が完了したか否かにより、処理を終了するか否か判定する。処理を終了すると判定した場合(S74でYES)、処理を終了する。一方、処理を終了しないと判定した場合(S74でNO)、処理をS71へ戻し、再びカウンタをカウントアップするか否かを判定する。
 図16は、実施の形態1に係るバッファリード周期カウント部180の動作を示すフローチャートである。なお、図16は、図9におけるS13又はS14におけるバッファリード周期カウント部180の動作を示す。
 S81では、バッファリード周期カウント部180が、データ非破壊制御部160から送信された転送タイプに基づき、インクリメント転送かデクリメント転送かを判定する。デクリメント転送と判定した場合、処理をS82へ進め、インクリメント転送と判定した場合、処理をS84へ進める。
 S82では、バッファリード周期カウント部180が、バッファリード制御部140が生成したバッファリードポインタがラップアラウンドしたか否かを判定する。ラップアラウンドしたと判定した場合(S82ではYES)、処理をS83に進める。ラップアラウンドしなかったと判定した場合(S82ではNO)、処理をS84へ進める。
 S83では、バッファリード周期カウント部180が、カウンタを+1カウントアップする。
 S84では、バッファリード周期カウント部180が、転送サイズ分のデータの転送が完了したか否かにより、処理を終了するか否か判定する。処理を終了すると判定した場合(S84でYES)、処理を終了する。一方、処理を終了しないと判定した場合(S84でNO)、処理をS81へ戻し、再びカウンタをカウントアップするか否かを判定する。
 次に、DMA転送制御装置100の具体的な動作例を説明する。
 図17から図21は、内部バッファ130のサイズより大きいサイズのデータをDMA転送し、バッファライト完了ポインタが先にラップアラウンドしたときのDMA転送時におけるデータの変化を示す図である。つまり、図17から図21は、「バッファライト周期カウンタ値>バッファリード周期カウンタ値」となる場合におけるデータの変化を示す図である。
 図17から図21の例では、内部バッファ130のサイズを64バイトとし、1マス2バイトを示す。また、図17から図21の転送元と転送先は同じデバイスとし、1マスは2バイトを示す。
 図17から図21の例では、転送元のアドレス00h~58hの領域のデータを転送先のアドレス20hから78hの領域にデクリメント転送する。DMA転送制御装置100が転送元へ、リード1(4バーストリード)、リード2(4バーストリード)、リード3(4バーストリード)の順番で発行する。また、DMA転送制御装置100が転送先へ、ライト1(4バーストライト)、ライト2(4バーストライト)、ライト3(4バーストライト)の順番で発行する。
 図17から図21の転送元の右横に示すリード順番は、DMA転送制御装置100がリードデータを取得する順番を示し、R1~R12の順番にリードデータを受信し、同様の順番に内部バッファ130に書き込む。転送先の右横に示すライト順番は、DMA転送制御装置100が転送先にデータを出力する順番を示し、W1~W12の順番に内部バッファ130からライトデータを受信し、同様の順番に転送先に書き込む。
 図17から図21のバッファライト完了ポインタは内部バッファ130でデータが準備できた領域を、バッファリードポインタは内部バッファ130でリードする領域を示す。バッファライト周期カウンタはバッファライト完了ポインタのラップアラウンド回数を、バッファリード周期カウンタはバッファリードポインタのラップアラウンド回数を示す。両ポインタとも、ラップアラウンドするたびに+1づつカウントアップする。
 まず、S11で、DMA転送制御装置100には、以下の設定情報が設定される。
転送元アドレス:00h
転送先アドレス:20h
転送サイズ:96バイト
転送タイプ:デクリメント転送
 次に、S12で、データ非破壊制御部160により各制御部及び各カウント部へデクリメント転送であることが通知される。そして、S14へ進み、デクリメント転送によるDMA転送が実行される。
 図17に示す手順1では、転送元リード制御部110が、転送元のアドレス40h~58hの領域に対してリード1(4バーストリード)を発行する。転送元からリードデータを受信したら、バッファライト制御部120は内部バッファ130へ、リード1に対応するバッファライト1を発行し、アドレス20h~38hの領域にリードデータを書き込む。バッファライト制御部120は、バッファライト1が完了したら、バッファライト完了ポインタを20hに更新する。
 バッファリード制御部140は、バッファリードポインタを、20h(転送先へ発行するライト1(4バーストライト)で出力するデータの読み出し領域)に設定する。
 図18に示す手順2では、転送元リード制御部110は、転送元のアドレス20h~38hの領域に対してリード2(4バーストリード)を発行する。転送元からリードデータを受信したら、バッファライト制御部120は内部バッファ130へ、リード2に対応するバッファライト2を発行し、アドレス00h~18hの領域にリードデータを書き込む。バッファライト制御部120は、バッファライト2が完了したら、バッファライト完了ポインタを00hに更新する。
 上記の転送元リードと並列に、データ非破壊制御部160は、「バッファライト周期カウンタ値=バッファリード周期カウンタ値」かつ「バッファライト完了ポインタ値≦バッファリードポインタ値」を検出し、転送先ライト可能指示を出力する。バッファリード制御部140は、転送先ライト可能指示を検出したら、内部バッファ130のアドレス20h~38hの領域に対してバッファリード1を発行して転送先ライトデータを読み出す。転送先ライト制御部150は、転送先のアドレス60h~78hの領域に対してライト1(4バーストライト)を発行する。
 図19に示す手順3では、転送元リード制御部110は、転送元のアドレス00h~18hの領域に対して、リード3(4バーストリード)を発行する。転送元からリードデータを受信したら、バッファライト制御部120は内部バッファ130へ、リード3に対応するバッファライト3を発行し、アドレス20h~38hの領域にリードデータを書き込む。バッファライト3が完了したら、バッファライト完了ポインタが20hに更新し、ラップアラウンドが発生する。バッファライト周期カウント部170は、バッファライト完了ポインタのラップアラウンドを検出し、バッファライト周期カウンタ値を+1カウントアップする。
 バッファリード制御部140は、バッファリード1を完了したら、バッファリードポインタを00hに更新する。データ非破壊制御部160は、「バッファライト周期カウンタ値>バッファリード周期カウンタ値」を検出し、データ準備完了と判定し、転送先ライト可能指示を出力する。バッファリード制御部140は、転送先ライト可能指示を検出したら、内部バッファ130のアドレス00h~18hの領域に対してバッファリード2を発行する。転送先ライト制御部150は、転送先のアドレス40h~58hへの領域に対してライト2(4バーストライト)を発行する。
 図20に示す手順4では、バッファリード制御部140は、バッファリード2を完了したら、バッファリードポインタを20hに更新し、ラップアラウンドが発生する。バッファリード周期カウント部180はラップアラウンドを検出し、バッファリード周期カウンタ値を+1カウントアップする。データ非破壊制御部160は、「バッファライト周期カウンタ値=バッファリード周期カウンタ値」かつ「バッファライト完了ポインタ値≦バッファリードポインタ値」を検出し、データ準備完了と判定し、転送先ライト可能指示を出力する。バッファリード制御部140は、転送先ライト可能指示を検出したら、内部バッファ130のアドレス20h~38hの領域に対してバッファリード3を発行する。転送先ライト制御部150は、転送先のアドレス20h~38hへの領域に対してライト3(4バーストライト)を発行する。
 図21に示す手順5では、DMA転送結果を示す。転送先に示すように、データ破壊が発生することなく、データの転送が完了している。
 図22から図26は、内部バッファ130のサイズより大きいサイズのデータをDMA転送し、バッファリードポインタが先にラップアラウンドしたときのDMA転送時におけるデータの変化を示す図である。つまり、図22から図26は、「バッファライト周期カウンタ値<バッファリード周期カウンタ値」となる場合におけるデータの変化を示す図である。
 図22から図26の例では、内部バッファ130のサイズを64バイトとし、1マス2バイトを示す。また、図22から図26の転送元と転送先は同じデバイスとし、1マスは2バイトを示す。
 図22から図26の例では、転送元のアドレス08h~58hの領域のデータを転送先のアドレス20hから70hの領域にデクリメント転送する。DMA転送制御装置100が転送元へ、リード1(4バーストリード)、リード2(4バーストリード)、リード3(3バーストリード)の順番で発行する。また、DMA転送制御装置100が転送先へ、ライト1(3バーストライト)、ライト2(4バーストライト)、ライト3(4バーストライト)の順番で発行する。なお、リード先、ライト先のアドレスが32バイト境界を跨いだ場合、端数処理として3バースト以下のバースト転送コマンドを発行する。
 図22から図26の転送元の右横に示すリード順番は、DMA転送制御装置100がリードデータを取得する順番を示し、R1~R11の順番にリードデータを受信し、同様の順番に内部バッファ130に書き込む。転送先の右横に示すライト順番は、DMA転送制御装置100が転送先にデータを出力する順番を示し、W1~W11の順番に内部バッファ130ライトデータを受信し、同様の順番に転送先に書き込む。
 図22から図26のバッファライト完了ポインタは内部バッファ130でデータが準備できた領域を、バッファリードポインタは内部バッファ130でリードする領域を示す。バッファライト周期カウンタはバッファライト完了ポインタのラップアラウンド回数を、バッファリード周期カウンタはバッファリードポインタのラップアラウンド回数を示す。両ポインタとも、ラップアラウンドするたびに+1づつカウントアップする。
 まず、S11で、DMA転送制御装置100には、以下の設定情報が設定される。
転送元アドレス:08h
転送先アドレス:20h
転送サイズ:88バイト
転送タイプ:デクリメント転送
 次に、S12で、データ非破壊制御部160により各制御部及び各カウント部へデクリメント転送であることが通知される。そして、S14へ進み、デクリメント転送によるDMA転送が実行される。
 図22に示す手順1では、転送元リード制御部110が、転送元のアドレス40h~58hの領域に対してリード1(4バーストリード)を発行する。転送元からリードデータを受信したら、バッファライト制御部120は、内部バッファ130へリード1に対応するバッファライト1を発行し、アドレス20h~38hの領域にリードデータを書き込む。バッファライト1が完了したら、バッファライト制御部120は、バッファライト完了ポインタを20hに更新する。
 バッファリード制御部140は、バッファリードポインタを、転送先へ発行するライト1(3バーストライト)で出力するデータの読み出し領域(28h)に設定する。データ非破壊制御部160は、「バッファライト周期カウンタ値=バッファリード周期カウンタ値」かつ「バッファライト完了ポインタ値≦バッファリードポインタ値」を検出し、転送先ライト可能指示を出力する。バッファリード制御部140は、転送先ライト可能指示を検出したら、内部バッファ130のアドレス28h~38hの領域に対してバッファリード1を発行して転送先ライトデータを読み出す。転送先ライト制御部150は、転送先のアドレス60h~70hの領域に対してライト1(3バーストライト)を発行する。
 図23に示す手順2では、転送元リード制御部110は、転送元のアドレス20h~38hの領域に対してリード2(4バーストリード)を発行する。転送元からリードデータを受信したら、バッファライト制御部120は、内部バッファ130へリード2に対応するバッファライト2を発行し、アドレス00h~18hの領域にリードデータを書き込む。バッファライト2が完了したら、バッファライト制御部120は、バッファライト完了ポインタを00hに更新する。
 バッファリード制御部140は、バッファリード1が完了したら、バッファリードポインタを08hに更新する。データ非破壊制御部160は、「バッファライト周期カウンタ値=バッファリード周期カウンタ値」かつ「バッファライト完了ポインタ値≦バッファリードポインタ値」を検出し、転送先ライト可能指示を出力する。バッファリード制御部140は、転送先ライト可能指示を検出したら、内部バッファ130のアドレス08h~20hの領域に対してバッファリード2を発行して転送先ライトデータを読み出す。転送先ライト制御部150は、転送先のアドレス40h~58hの領域に対してライト2(4バーストライト)を発行する。
 図24に示す手順3では、転送元リード制御部110は、転送元のアドレス08h~18hの領域に対して、リード3(3バーストリード)を発行する。転送元からリードデータを受信したら、バッファライト制御部120は、内部バッファ130へリード3に対応するバッファライト3を発行し、アドレス28h~38hの領域にリードデータを書き込む。ここでは、バッファライト3が未完了であり、バッファライト完了ポインタは更新されていないとする。
 バッファリード制御部140は、バッファリード2を完了したので、バッファリードポインタを28hに更新し、ラップアラウンドが発生する。バッファリード周期カウント部180はラップアラウンドを検出し、バッファリード周期カウンタ値を+1カウントアップする。データ非破壊制御部160は、「バッファライト周期カウンタ値<バッファリード周期カウンタ値」を検出し、データ準備未完了と判定し、転送先ライト可能指示を出力しない(転送先ライト不許可)。バッファリード制御部140は、転送先ライト可能指示を検出しないので、内部バッファ130に対する次のバッファリードを発行しない。転送先ライト制御部150も同様に、転送先に対して次のライト3(4バーストライト)を発行しない。
 図25に示す手順4では、バッファライト3が完了する。そして、バッファライト制御部120は、バッファライト完了ポインタを28hに更新し、ラップアラウンドが発生する。バッファライト周期カウント部170は、バッファライト完了ポインタのラップアラウンドを検出し、バッファライト周期カウンタ値を+1カウントアップする。
 データ非破壊制御部160は、「バッファライト周期カウンタ値=バッファリード周期カウンタ値」かつ「バッファライト完了ポインタ値≦バッファリードポインタ値」を検出し、データ準備完了と判定し、転送先ライト可能指示を出力する。バッファリード制御部140は、転送先ライト可能指示を検出したら、内部バッファ130のアドレス28h~00hの領域に対してバッファリード3を発行して転送先ライトデータを読み出す。転送先ライト制御部150は、転送先のアドレス20h~38hの領域に対してライト3(4バーストライト)を発行する。
 図26に示す手順5では、DMA転送結果を示す。転送先に示すように、データ破壊が発生することなく、データの転送が完了している。
 図27から図31は、内部バッファ130のサイズより小さいサイズのデータをDMA転送し、両ポインタがラップアラウンドしなかったときのDMA転送時におけるデータの変化を示す図である。つまり、図27から図31は、「バッファライト周期カウンタ値=バッファリード周期カウンタ値」となる場合におけるデータの変化を示す図である。なお、ここでは、簡略化のため、両ポインタがラップアラウンドしなかったときを具体例として挙げているが、両ポインタが同じ回数のラップアラウンドした場合でも同様の効果が得られる。
 図27から図31の例では、内部バッファ130のサイズを64バイトとし、1マス2バイトを示す。また、図27から図31の転送元と転送先は同じデバイスとし、1マスは2バイトを示す。
 図27から図31の例では、転送元のアドレス00h~30hの領域のデータを転送先のアドレス18h~48hの領域にデクリメント転送する。DMA転送制御装置100が転送元へ、リード1(3バーストリード)、リード2(4バーストリード)の順番で発行する。DMA転送制御装置100が転送先へ、ライト1(4バーストライト)、ライト2(3バーストライト)の順番で発行する。なお、リード先、ライト先のアドレスが32バイト境界を跨いだ場合、端数処理として3バースト以下のバースト転送コマンドを発行する。
 図27から図31の転送元の右横に示すリード順番は、DMA転送制御装置100がリードデータを取得する順番を示し、R1~R7の順番にリードデータを受信し、同様の順番に内部バッファ130に書き込む。転送先の右横に示すライト順番は、DMA転送制御装置100が転送先にデータを出力する順番を示し、W1~W7の順番に内部バッファ130からライトデータを受信し、同様の順番に転送先に書き込む。
 図27から図31のバッファライト完了ポインタは内部バッファ130でデータが準備できた領域を、バッファリードポインタは内部バッファ130でリードする領域を示す。バッファライト周期カウンタはバッファライト完了ポインタのラップアラウンド回数を、バッファリード周期カウンタはバッファリードポインタのラップアラウンド回数を示す。両ポインタとも、ラップアラウンドするたびに+1づつカウントアップする。
 まず、S11で、DMA転送制御装置100には、以下の設定情報が設定される。
転送元アドレス:00h
転送先アドレス:30h
転送サイズ:56バイト
転送タイプ:デクリメント転送
 次に、S12で、データ非破壊制御部160により各制御部及び各カウント部へデクリメント転送であることが通知される。そして、S14へ進み、デクリメント転送によるDMA転送が実行される。
 図27に示す手順1では、転送元リード制御部110が、転送元のアドレス20h~30hの領域に対してリード1(3バーストリード)を発行する。転送元からリードデータを受信したら、バッファライト制御部120は内部バッファ130へ、リード1に対応するバッファライト1を発行し、アドレス28h~38hの領域にリードデータを書き込む。バッファライト1が完了したら、バッファライト制御部120は、バッファライト完了ポインタを28hに更新する。
 バッファリード制御部140は、バッファリードポインタを、転送先へ発行するライト1(4バーストライト)で出力するデータの読み出し領域(20h)に設定する。
 図28に示す手順2では、転送元リード制御部110は、転送元のアドレス00h~18hの領域に対してリード2(4バーストリード)を発行する。転送元からリードデータを受信したら、バッファライト制御部120は、内部バッファ130へリード2に対応するバッファライト2を発行し、アドレス08h~20hの領域にリードデータを書き込む。ここでは、バッファライト2が未完了であり、バッファライト制御部120は、バッファライト完了ポインタは更新されていないとする。
 データ非破壊制御部160は、「バッファライト周期カウンタ値=バッファリード周期カウンタ値」かつ「バッファライト完了ポインタ値>バッファリードポインタ値」を検出し、データ準備未完了と判定し、転送先ライト可能指示を出力しない。バッファリード制御部140は、転送先ライト可能指示を未検出なので、バッファリード1を発行しない。転送先ライト制御部150も同様に、ライト1を発行しない。なお、手順2の状態では、次のライト1に必要なデータ量(4バースト分)はあるが、必要なデータ種類(13~28のデータ)は揃っていないので、データ準備未完了と判断する。
 図29に示す手順3では、バッファライト2が完了し、バッファライト制御部120は、バッファライト完了ポインタを08hに更新する。
 データ非破壊制御部160は、「バッファライト周期カウンタ値=バッファリード周期カウンタ値」かつ「バッファライト完了ポインタ値≦バッファリードポインタ値」を検出し、データ準備完了と判定し、転送先ライト可能指示を出力する。バッファリード制御部140は、転送先ライト可能指示を検出したら、内部バッファ130のアドレス20h~38hの領域に対してバッファリード1を発行して転送先ライトデータを読み出す。転送先ライト制御部150は、転送先のアドレス30h~48hの領域に対してライト1(4バーストライト)を発行する。
 図30に示す手順4では、バッファリード制御部140は、バッファリード1が完了すると、バッファリードポインタを08hに更新する。データ非破壊制御部160は、「バッファライト周期カウンタ値=バッファリード周期カウンタ値」かつ「バッファライト完了ポインタ値≦バッファリードポインタ値」を検出し、データ準備完了と判定し、転送先ライト可能指示を出力する。バッファリード制御部140は、転送先ライト可能指示を検出したら、内部バッファ130のアドレス08h~18hの領域に対してバッファリード2を発行して転送先ライトデータを読み出す。転送先ライト制御部150は、転送先のアドレス18h~28hの領域に対してライト2(3バーストライト)を発行する。
 図31に示す手順5では、DMA転送結果を示す。転送先に示すように、データ破壊が発生することなく、データの転送が完了している。
 実施の形態2.
 実施の形態1では、CPU200がインクリメント転送を行うか、デクリメント転送を行うかを指定した。つまり、CPU200側でインクリメント転送を行うべきか、デクリメント転送を行うべきかの判断をする必要があった。
 実施の形態2では、DMA転送制御装置100が転送元領域と転送先領域との重なりの状態に応じて、インクリメント転送を行うべきか、デクリメント転送を行うべきかを適切に判断する方法について説明する。
 実施の形態2に係るDMA転送制御装置100は、実施の形態1に係るDMA転送制御装置100と、データ非破壊制御部160の構成のみ異なる。
 図32は、実施の形態2に係るデータ非破壊制御部160の構成図である。実施の形態2に係るデータ非破壊制御部160は、実施の形態1に係るデータ非破壊制御部160が備える転送タイプ設定レジスタ161を備えていない。その代わりに、実施の形態2に係るデータ非破壊制御部160は、データ非破壊機能ON/OFF設定レジスタ191、転送元アドレス設定レジスタ192、転送先アドレス設定レジスタ193、転送サイズ設定レジスタ194、転送タイプ判断部195を備える。
 データ非破壊機能ON/OFF設定レジスタ191には、データ非破壊機能をON(有効)にするか、OFF(無効)にするかが設定される。
 転送元アドレス設定レジスタ192には、転送元領域の先頭アドレスが設定される。転送先アドレス設定レジスタ193には、転送先領域の先頭アドレスが設定される。転送サイズ設定レジスタ194には、転送データのサイズが設定される。
 転送タイプ判断部195は、データ非破壊機能ON/OFF設定レジスタ191にONと設定されている場合、以下のように転送タイプを判断し、各制御部へ通知する。
(A)転送元領域と転送先領域とが重ならない場合、インクリメント転送と判断する。
(B)転送元領域と転送先領域とが重なる場合、以下の(a)から(c)のように判断する。
(a)転送元領域と転送先領域とが全く同じ領域ならインクリメント転送と判断する。
(b)転送元アドレス設定レジスタ192に設定されたアドレス(転送元領域の先頭アドレス)のアドレス値が、転送先アドレス設定レジスタ193に設定されたアドレス(転送先領域の先頭アドレス)のアドレス値より小さいならデクリメント転送と判断する。
(c)転送元アドレス設定レジスタ192に設定されたアドレス(転送元領域の先頭アドレス)のアドレス値が、転送先アドレス設定レジスタ193に設定されたアドレス(転送先領域の先頭アドレス)のアドレス値より大きいならインクリメント転送と判断する。
 一方、転送タイプ判断部195は、データ非破壊機能ON/OFF設定レジスタ191にOFFと設定されている場合、常にインクリメント転送と各制御部へ通知する。
 図33は、実施の形態2に係るDMA転送制御装置100全体の動作を示すフローチャートである。
 S71は、図9のS11と同様である。この際、データ非破壊機能をONとするかOFFとするかもレジスタに設定される。
 S72では、データ非破壊制御部160がレジスタ(データ非破壊機能ON/OFF設定レジスタ191)の設定がONか否かを判定する。ONである場合、処理をS73へ進め、OFFである場合、インクリメント転送であることを各制御部へ通知して、処理をS75へ進める。
 S73では、データ非破壊制御部160がインクリメント転送であるか、デクリメント転送であるかを判定する。デクリメント転送である場合、デクリメント転送であることを各制御部へ通知して、処理をS74へ進める。一方、インクリメント転送である場合、インクリメント転送であることを各制御部へ通知して、処理をS75へ進める。
 S74では、DMA転送制御装置100がメモリ300に対してデクリメント転送を行う。一方、S75では、DMA転送制御装置100がメモリ300に対してインリメント転送を行う。
 そして、S76では、DMA転送制御装置100が指定されたデータ長のデータを転送し終えた場合等、DMA転送停止要因があったときに転送動作を停止する。
 以上のように、実施の形態2に係るDMA転送制御装置100によれば、CPU200が転送タイプを指示することなく、DMA転送制御装置100側で適切な転送タイプを判断した上で、データ転送を行うことができる。
 なお、以上の説明において、各制御部は、例えば、回路等によって構成されており、「~部」を「~回路」と読み代えても構わない。
 10 DMA転送システム、100 DMA転送制御装置、110 転送元リード制御部、120 バッファライト制御部、130 内部バッファ、140 バッファリード制御部、150 転送先ライト制御部、160 データ非破壊制御部、161 転送タイプ設定レジスタ、162 バッファライト完了ポインタ設定レジスタ、163 バッファリードポインタ設定レジスタ、164 第1バッファ準備完了判断部、165 第2バッファ準備完了判断部、166 ラップアラウンド回数一致判断部、167 セレクタ、170 バッファライト周期カウント部、171 ラップアラウンド検出部、172 ラップアラウンド回数カウント部、180 バッファリード周期カウント部、181 ラップアラウンド検出部、182 ラップアラウンド回数カウント部、191 データ非破壊機能ON/OFF設定レジスタ、192 転送元アドレス設定レジスタ、193 転送先アドレス設定レジスタ、194 転送サイズ設定レジスタ、195 転送タイプ判断部、200 CPU、300 メモリ。

Claims (7)

  1.  転送元領域に記憶されたデータを転送先領域へ転送するデータ転送装置であり、
     前記転送元領域に記憶されたデータを読み出すリードコマンドを出力する転送元リード制御部と、
     前記転送元リード制御部が出力したリードコマンドによって読み出されたデータを取得してリングバッファへ書き込むバッファライト制御部と、
     前記バッファライト制御部が書き込んだデータを前記リングバッファから読み出して、前記転送先領域へ送信するバッファリード制御部と、
     前記バッファリード制御部が前記転送先領域へ送信したデータを、前記転送先領域へ書き込むライトコマンドを出力する転送先ライト制御部と、
     前記バッファライト制御部によるラップアラウンドの回数をカウントするライト周期カウント部と、
     前記バッファリード制御部によるラップアラウンドの回数をカウントするリード周期カウント部と、
     前記ライト周期カウント部がカウントした回数と、前記リード周期カウント部がカウントした回数との大小関係から、前記転送先領域へのデータ書き込みを許可するか否かを判定するデータ非破壊制御部と
    を備え、
     前記バッファリード制御部は、書き込みを許可すると前記データ非破壊制御部が判定した場合に、データを前記リングバッファから読み出し、
     前記転送先ライト制御部は、書き込みを許可すると前記データ非破壊制御部が判定した場合に、前記ライトコマンドを出力して、前記バッファリード制御部が前記転送先領域へ送信したデータを前記転送先領域へ書き込む
    ことを特徴とするデータ転送装置。
  2.  前記データ非破壊制御部は、さらに、前記バッファライト制御部がデータの書き込みを完了した前記リングバッファにおけるアドレス値と、前記バッファリード制御部がデータを読み出そうとしている前記リングバッファにおけるアドレス値との大小関係から、前記転送先領域へのデータ書き込みを許可するか否かを判定する
    ことを特徴とする請求項1に記載のデータ転送装置。
  3.  前記転送元リード制御部は、単位量のデータづつ所定個の単位量のデータをリード開始アドレスからアドレス値の昇順に読み出すリードコマンドを、前記リード開始アドレスのアドレス値が降順になるように複数個生成して順に出力し、
     前記バッファライト制御部は、前記転送元リード制御部が出力した各リードコマンドについて、前記転送元リード制御部がリードコマンドを出力した順に、そのリードコマンドによって読み出されたデータを単位量づつ取得して、そのリードコマンドにおけるリード開始アドレスに対応するリングバッファにおけるアドレスからアドレス値の昇順に書き込むとともに、そのリードコマンドによって読み出されたデータの前記リングバッファへの書き込みが終了した場合に、前記リード開始アドレスに対応するリングバッファにおけるアドレスにライト完了ポインタを設定し、
     前記転送先ライト制御部は、単位量のデータづつ所定個の単位量のデータをライト開始アドレスからアドレス値の昇順に書き込むライトコマンドを、前記ライト開始アドレスのアドレス値が降順になるように複数個生成して順に出力し、
     前記バッファリード制御部は、前記転送先ライト制御部が次に出力するライトコマンドにおけるライト開始アドレスに対応する、前記リングバッファにおけるアドレスにリードポインタを設定し、
     前記データ非破壊制御部は、前記ライト周期カウント部がカウントした回数が前記リード周期カウント部がカウントした回数よりも多い場合と、前記ライト周期カウント部がカ
    ウントした回数と前記リード周期カウント部がカウントした回数とが同じであり、前記リードポインタが設定されたアドレスのアドレス値が、前記ライト完了ポインタに設定されたアドレスのアドレス値以上である場合とに、書き込みを許可すると判定し、
     前記バッファリード制御部は、書き込みを許可すると前記データ非破壊制御部が判定した場合に、前記リードポインタが設定されたアドレスからアドレス値の昇順に単位量づつデータを読み出し、
     前記転送先ライト制御部は、書き込みを許可すると前記データ非破壊制御部が判定した場合に、次のライトコマンドを出力する
    ことを特徴とする請求項2に記載のデータ転送装置。
  4.  前記データ非破壊制御部は、前記転送元領域と前記転送先領域とが重複する場合であって、前記転送元領域の先頭位置を表す先頭アドレスのアドレス値が前記転送先領域の先頭位置を表す先頭アドレスのアドレス値以下である場合には、デクリメント転送を行い、他の場合には、インクリメント転送を行うと判定し、
     前記転送元リード制御部は、デクリメント転送を行うと前記データ非破壊制御部が判定した場合、前記リード開始アドレスのアドレス値が降順になるように前記リードコマンドを複数個生成して順に出力し、インクリメント転送を行うと前記データ非破壊制御部が判定した場合、前記リード開始アドレスのアドレス値が昇順になるように前記リードコマンドを複数個生成して順に出力し、
     前記転送先ライト制御部は、デクリメント転送を行うと前記データ非破壊制御部が判定した場合、前記ライト開始アドレスのアドレス値が降順になるように前記ライトコマンドを複数個生成して順に出力し、インクリメント転送を行うと前記データ非破壊制御部が判定した場合、前記ライト開始アドレスのアドレス値が昇順になるように前記ライトコマンドを複数個生成して順に出力し、
     前記データ非破壊制御部は、デクリメント転送を行うと判定した場合、前記ライト周期カウント部がカウントした回数が前記リード周期カウント部がカウントした回数よりも多い場合と、前記ライト周期カウント部がカウントした回数と前記リード周期カウント部がカウントした回数とが同じであり、前記リードポインタが設定されたアドレスのアドレス値が、前記ライト完了ポインタに設定されたアドレスのアドレス値以上である場合とに、書き込みを許可すると判定し、インクリメント転送を行うと判定した場合、前記リードポインタと前記ライト完了ポインタとに設定されたアドレスに関わらず、書き込みを許可すると判定する
    ことを特徴とする請求項3に記載のデータ転送装置。
  5.  前記バッファライト制御部は、リードコマンドによって読み出されたデータをリード用バスを介して取得し、
     前記バッファリード制御部は、前記リングバッファから読み出したデータを前記リード用バスとは異なるライト用バスを介して転送先領域へ送信する
    ことを特徴とする請求項1から4までのいずれかに記載のデータ転送装置。
  6.  転送元領域に記憶されたデータを転送先領域へ転送するデータ転送方法であり、
     前記転送元領域に記憶されたデータを読み出すリードコマンドを出力する転送元リード制御ステップと、
     前記転送元リード制御ステップで出力したリードコマンドによって読み出されたデータを取得してリングバッファへ書き込むバッファライト制御ステップと、
     前記バッファライト制御ステップで書き込んだデータを前記リングバッファから読み出して、前記転送先領域へ送信するバッファリード制御ステップと、
     前記バッファリード制御ステップで前記転送先領域へ送信したデータを、前記転送先領域へ書き込むライトコマンドを出力する転送先ライト制御ステップと、
     前記バッファライト制御ステップによるラップアラウンドの回数をカウントするライト
    周期カウントステップと、
     前記バッファリード制御ステップによるラップアラウンドの回数をカウントするリード周期カウントステップと、
     前記ライト周期カウントステップでカウントした回数と、前記リード周期カウントステップでカウントした回数との大小関係から、前記転送先領域へのデータ書き込みを許可するか否かを判定するデータ非破壊制御ステップと
    を備え、
     前記バッファリード制御ステップでは、書き込みを許可すると前記データ非破壊制御ステップで判定した場合に、データを前記リングバッファから読み出し、
     前記転送先ライト制御ステップでは、書き込みを許可すると前記データ非破壊制御ステップで判定した場合に、前記ライトコマンドを出力して、前記バッファリード制御ステップで前記転送先領域へ送信したデータを前記転送先領域へ書き込む
    ことを特徴とするデータ転送方法。
  7.  転送元領域に記憶されたデータを転送先領域へ転送するデータ転送プログラムであり、
     前記転送元領域に記憶されたデータを読み出すリードコマンドを出力する転送元リード制御処理と、
     前記転送元リード制御処理で出力したリードコマンドによって読み出されたデータを取得してリングバッファへ書き込むバッファライト制御処理と、
     前記バッファライト制御処理で書き込んだデータを前記リングバッファから読み出して、前記転送先領域へ送信するバッファリード制御処理と、
     前記バッファリード制御処理で前記転送先領域へ送信したデータを、前記転送先領域へ書き込むライトコマンドを出力する転送先ライト制御処理と、
     前記バッファライト制御処理によるラップアラウンドの回数をカウントするライト周期カウント処理と、
     前記バッファリード制御処理によるラップアラウンドの回数をカウントするリード周期カウント処理と、
     前記ライト周期カウント処理でカウントした回数と、前記リード周期カウント処理でカウントした回数との大小関係から、前記転送先領域へのデータ書き込みを許可するか否かを判定するデータ非破壊制御処理と
    をコンピュータに実行させ、
     前記バッファリード制御処理では、書き込みを許可すると前記データ非破壊制御処理で判定した場合に、データを前記リングバッファから読み出し、
     前記転送先ライト制御処理では、書き込みを許可すると前記データ非破壊制御処理で判定した場合に、前記ライトコマンドを出力して、前記バッファリード制御処理で前記転送先領域へ送信したデータを前記転送先領域へ書き込む
    ことを特徴とするデータ転送プログラム。
PCT/JP2013/052451 2012-02-29 2013-02-04 データ転送装置、データ転送方法及びデータ転送プログラム WO2013129031A1 (ja)

Priority Applications (6)

Application Number Priority Date Filing Date Title
CN201380011490.9A CN104145255B (zh) 2012-02-29 2013-02-04 数据传输装置、数据传输方法及数据传输程序
US14/377,982 US9727504B2 (en) 2012-02-29 2013-02-04 Data transfer apparatus, data transfer method, and data transfer program
DE112013001213.8T DE112013001213T5 (de) 2012-02-29 2013-02-04 Datentransfereinrichtung, Datentransferverfahren und Datentransferprogramm
KR1020147024021A KR101593865B1 (ko) 2012-02-29 2013-02-04 데이터 전송 장치, 데이터 전송 방법 및 데이터 전송 프로그램
JP2014502088A JP5769868B2 (ja) 2012-02-29 2013-02-04 データ転送装置、データ転送方法及びデータ転送プログラム
TW102106366A TWI524267B (zh) 2012-02-29 2013-02-23 Data transfer devices, data transfer methods and data transfer program products

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2012043994 2012-02-29
JP2012-043994 2012-02-29

Publications (1)

Publication Number Publication Date
WO2013129031A1 true WO2013129031A1 (ja) 2013-09-06

Family

ID=49082235

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2013/052451 WO2013129031A1 (ja) 2012-02-29 2013-02-04 データ転送装置、データ転送方法及びデータ転送プログラム

Country Status (7)

Country Link
US (1) US9727504B2 (ja)
JP (1) JP5769868B2 (ja)
KR (1) KR101593865B1 (ja)
CN (1) CN104145255B (ja)
DE (1) DE112013001213T5 (ja)
TW (1) TWI524267B (ja)
WO (1) WO2013129031A1 (ja)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017167644A (ja) * 2016-03-14 2017-09-21 日本電気株式会社 データ転送装置、データ転送方法、プログラム
US12001365B2 (en) 2020-07-07 2024-06-04 Apple Inc. Scatter and gather streaming data through a circular FIFO

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10841297B2 (en) 2013-12-16 2020-11-17 Amazon Technologies, Inc. Providing multi-factor authentication credentials via device notifications
US10362026B2 (en) 2013-12-16 2019-07-23 Amazon Technologies, Inc. Providing multi-factor authentication credentials via device notifications
US9473491B1 (en) * 2014-12-16 2016-10-18 Amazon Technologies, Inc. Computing device with integrated authentication token
US10866711B1 (en) 2013-12-16 2020-12-15 Amazon Technologies, Inc. Providing account information to applications
US9819673B1 (en) 2015-06-24 2017-11-14 Amazon Technologies, Inc. Authentication and authorization of a privilege-constrained application
US9864852B2 (en) 2015-07-27 2018-01-09 Amazon Technologies, Inc. Approaches for providing multi-factor authentication credentials
TWI615770B (zh) * 2015-11-17 2018-02-21 群聯電子股份有限公司 資料存取方法、記憶體控制電路單元與記憶體儲存裝置
US10162751B2 (en) * 2016-04-26 2018-12-25 Macronix International Co., Ltd. Nested wrap-around memory access with fixed offset
US20180018999A1 (en) * 2016-07-12 2018-01-18 Mediatek Inc. Video processing system using ring buffer and racing-mode ring buffer access control scheme
CN112098770A (zh) * 2020-08-20 2020-12-18 深圳市宏旺微电子有限公司 针对动态耦合故障模拟极端环境下的测试方法和装置

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS61214047A (ja) * 1985-03-20 1986-09-22 Fujitsu Ltd メモリデ−タ転送回路
JPH08292874A (ja) * 1995-04-25 1996-11-05 Nec Eng Ltd メモリ状態検出回路
JP2000293480A (ja) * 1999-04-12 2000-10-20 Oki Data Corp Dma転送装置
JP2001142841A (ja) * 1999-11-12 2001-05-25 Nec Corp Dma転送制御方式
JP2008083911A (ja) * 2006-09-27 2008-04-10 Matsushita Electric Ind Co Ltd Dma転送制御装置および半導体集積回路装置

Family Cites Families (23)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH083850B2 (ja) * 1985-03-20 1996-01-17 キヤノン株式会社 画像処理装置
JP2703417B2 (ja) 1991-04-05 1998-01-26 富士通株式会社 受信バッファ
JP3176236B2 (ja) * 1994-11-30 2001-06-11 株式会社ソニー・コンピュータエンタテインメント 信号再生装置及び信号再生方法
JP3181515B2 (ja) * 1996-09-11 2001-07-03 株式会社沖データ データ転送方法及びその方法を用いたデータ転送装置
JPH10116245A (ja) 1996-10-14 1998-05-06 Fujitsu Ltd Dma制御装置
US6311237B1 (en) 1998-01-05 2001-10-30 Canon Kabushiki Kaisha System including single host buffer for transmit and receive data and reception buffer in interface device having stand-by area for use by host buffer when abnormal state is detected
JP3768668B2 (ja) 1998-01-05 2006-04-19 キヤノン株式会社 インターフェース装置及び制御方法及び印刷装置
JP4292598B2 (ja) 1998-08-26 2009-07-08 富士通マイクロエレクトロニクス株式会社 Fifo回路及びマルチプロセッサシステム
US6571301B1 (en) 1998-08-26 2003-05-27 Fujitsu Limited Multi processor system and FIFO circuit
JP3765931B2 (ja) * 1998-10-15 2006-04-12 富士通株式会社 バッファ制御方法及びバッファ制御装置
EP1152342B1 (en) * 1999-01-12 2009-01-07 Fujitsu Limited Access control device and method for controlling access to recording medium
JP3461327B2 (ja) 2000-05-17 2003-10-27 Necマイクロシステム株式会社 トレースメモリに制限されない長時間トレースシステム
JP2002342262A (ja) 2001-05-11 2002-11-29 Fujitsu Ltd ダイレクトメモリアクセス制御装置およびダイレクトメモリアクセス制御方法
JP4749657B2 (ja) * 2003-03-20 2011-08-17 パナソニック株式会社 Dma制御装置
US7519747B1 (en) * 2003-09-11 2009-04-14 Xilinx, Inc. Variable latency buffer and method of operation
US20050289254A1 (en) * 2004-06-28 2005-12-29 Chih-Feng Chien Dynamic buffer allocation method
US20060129714A1 (en) 2004-12-10 2006-06-15 Fujitsu Limited Method and apparatus for transferring data
JP4451837B2 (ja) 2004-12-10 2010-04-14 富士通株式会社 データ転送装置およびデータ転送方法
US20070204076A1 (en) * 2006-02-28 2007-08-30 Agere Systems Inc. Method and apparatus for burst transfer
US7721018B2 (en) * 2006-08-24 2010-05-18 Microchip Technology Incorporated Direct memory access controller with flow control
FR2913785B1 (fr) * 2007-03-13 2009-06-12 St Microelectronics Sa Gestion de memoire tampon circulaire
US9032113B2 (en) * 2008-03-27 2015-05-12 Apple Inc. Clock control for DMA busses
WO2011155096A1 (ja) * 2010-06-11 2011-12-15 パナソニック株式会社 データ転送制御装置とその集積回路とデータ転送制御方法、データ転送終了通知装置とその集積回路とデータ転送終了通知方法、およびデータ転送制御システム

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS61214047A (ja) * 1985-03-20 1986-09-22 Fujitsu Ltd メモリデ−タ転送回路
JPH08292874A (ja) * 1995-04-25 1996-11-05 Nec Eng Ltd メモリ状態検出回路
JP2000293480A (ja) * 1999-04-12 2000-10-20 Oki Data Corp Dma転送装置
JP2001142841A (ja) * 1999-11-12 2001-05-25 Nec Corp Dma転送制御方式
JP2008083911A (ja) * 2006-09-27 2008-04-10 Matsushita Electric Ind Co Ltd Dma転送制御装置および半導体集積回路装置

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017167644A (ja) * 2016-03-14 2017-09-21 日本電気株式会社 データ転送装置、データ転送方法、プログラム
US12001365B2 (en) 2020-07-07 2024-06-04 Apple Inc. Scatter and gather streaming data through a circular FIFO

Also Published As

Publication number Publication date
JPWO2013129031A1 (ja) 2015-07-30
DE112013001213T5 (de) 2014-12-04
KR101593865B1 (ko) 2016-02-12
CN104145255A (zh) 2014-11-12
KR20140128370A (ko) 2014-11-05
TW201403461A (zh) 2014-01-16
TWI524267B (zh) 2016-03-01
CN104145255B (zh) 2017-03-08
JP5769868B2 (ja) 2015-08-26
US20150039803A1 (en) 2015-02-05
US9727504B2 (en) 2017-08-08

Similar Documents

Publication Publication Date Title
JP5769868B2 (ja) データ転送装置、データ転送方法及びデータ転送プログラム
US10108372B2 (en) Methods and apparatuses for executing a plurality of queued tasks in a memory
US7159048B2 (en) Direct memory access (DMA) transfer buffer processor
US20090271536A1 (en) Descriptor integrity checking in a dma controller
KR950009455A (ko) 디지탈 신호처리 프로세서
JP6633119B2 (ja) 自律的メモリの方法及びシステム
US20070162637A1 (en) Method, apparatus and program storage device for enabling multiple asynchronous direct memory access task executions
US20180157443A1 (en) Microcontroller with integrated interface enabling reading data randomly from serial flash memory
TWI534615B (zh) 串列周邊介面控制器、串列周邊介面快閃記憶體及其存取方法和存取控制方法
WO2001006363A1 (en) A method for improving interrupt response time
JP2006338538A (ja) ストリームプロセッサ
KR20080012233A (ko) 버스트 메모리 액세스를 제어하는 메모리 인터페이스, 및그를 제어하는 방법
US8918680B2 (en) Trace queue for peripheral component
JPH0332818B2 (ja)
JP2006113689A (ja) バスブリッジ装置およびデータ転送方法
US6738837B1 (en) Digital system with split transaction memory access
JP3824122B2 (ja) Dma装置
JP2008059565A (ja) バーストメモリアクセスを制御するメモリインターフェース装置及びその制御方法
JP2011070372A (ja) Dma転送制御装置
JP5656589B2 (ja) データ転送装置、データ転送方法及びデータ転送プログラム
US20190121761A1 (en) Bit Manipulation Capable Direct Memory Access
JP4985599B2 (ja) Dma転送制御システム
US20070198754A1 (en) Data transfer buffer control for performance
JP2679440B2 (ja) 情報処理装置
JPH03158952A (ja) Dmaコントローラおよび情報処理システム

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 13755261

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2014502088

Country of ref document: JP

Kind code of ref document: A

WWE Wipo information: entry into national phase

Ref document number: 14377982

Country of ref document: US

ENP Entry into the national phase

Ref document number: 20147024021

Country of ref document: KR

Kind code of ref document: A

WWE Wipo information: entry into national phase

Ref document number: 1120130012138

Country of ref document: DE

Ref document number: 112013001213

Country of ref document: DE

122 Ep: pct application non-entry in european phase

Ref document number: 13755261

Country of ref document: EP

Kind code of ref document: A1