The following is a description of the preferred embodiment of the present invention by referring to
The disk array control apparatus 100 shown by
The disk array control apparatus 100 according to the present embodiment comprises at least an apparatus control unit 101 for controlling the entirety of the apparatus, a peripheral apparatus control unit 102 for carrying out a data transmission and reception to and from another disk array control apparatus 107 based on a request of the apparatus control unit 101, an instruction storage unit 103 for storing an execution instruction and data at the time of carrying out a disk cache, and an interrupt control information storage unit 104 for storing interrupt control information.
The apparatus control unit 101 carries out data reading and writing processing from and to the disk array 106 based on a request from the host computer 105.
The apparatus control unit 101 also makes the peripheral apparatus control unit 102 carry out a data transmission and reception to and from another disk array control apparatus 107. In this event, the apparatus control unit 101 writes an instruction to be executed to an instruction storage unit 103, followed by requesting the peripheral apparatus control unit 102 for executing the instruction.
Simultaneously, the apparatus control unit 101 determines an interrupt processing method performed on the unit itself based on a load state thereof, and stores the determined interrupt processing method as interrupt control information in the interrupt control information storage unit 104.
The peripheral apparatus control unit 102, having received a request for an execution from the apparatus control unit 101, reads an instruction from the instruction storage unit 103 and executes the instruction and carries out a data transmission and reception to and from another disk array control apparatus 107, for example, and such. Then, upon completion of the execution of the instruction, carries out interrupt processing on the apparatus control unit 101 for a notification of the completion.
As shown in
The disk array apparatus 201 comprises a disk array 201a constituted by one or two or more disks, and a Controller Module (CM) 201b for data reading and writing from and to the disk array 201a.
Likewise, the disk array apparatuses 202 through 204 respectively comprise disk arrays 202a, 203a and 204a; and CM 202b, CM 203b and CM 204b.
Meanwhile, the disk array apparatuses 201 and 204 are connected to the host computers respectively.
Having received a READ instruction for example from the host computer, the CM 201b reads applicable data from the disk array 201a and transmits it to the host computer.
Having received a WRITE instruction, the CM 201b writes, to disk array 201a, the data received from the host computer. Furthermore, if the disk array apparatuses 201 and 202 constitute a duplex, the CM 201b transmits data to the disk array apparatus 202. Having received the data, the CM 202b stores it in the disk array 202a. A similar process is carried out in the disk array apparatuses 203 and 204.
Note that
As shown in
In the case of transferring data between disk array apparatuses, the DMA 302 reads an instruction (e.g., a READ or WRITE instruction) stored in a predetermined position of the memory 304 and execute the instruction based on a request from the CPU 303.
The DMA 302 comprises an instruction execution unit 302a for executing an instruction in compliance with a request from the CPU 303, and an interrupt control unit 302b for controlling an interrupt to the CPU 303.
The instruction execution unit 302a retains an instruction execution pointer and an instruction end pointer, both of which store an address of the instruction continuously written to the memory 304, with the instruction execution pointer storing the address of the initial instruction to be executed and the instruction end pointer storing the address of the instruction at the tail end of the continuous instruction.
The DMA 302 also executes an instruction starting from one indicated by the instruction execution pointer sequentially to the one indicated by the instruction end pointer.
The CPU 303 retains an instruction completion pointer and an instruction end pointer, both of which store the address of an instruction continuously written to the memory 304, with the instruction completion pointer storing the address of the previously executed instruction, and the instruction end pointer storing the address of the instruction at the tail end of a list.
In the case of carrying out a DMA transfer between CMs, the CPU 303 writes an instruction to be executed by the DMA 302 to the memory 304 (i.e., adds at the end of the instruction) and also updates an instruction end pointer. The example 4 shown in
Having written a desired instruction to the memory 304, the CPU 303 requests the DMA 302 for an execution of the instruction. In this event, the instruction end pointer retained by the DMA 302 is also updated. In the example shown in
Having received the execution request of the instruction from the CPU 303, the DMA 302 starts an execution of the instruction. First, the DMA 302 reads an instruction of an address indicated by the instruction execution pointer from the memory 304 and executes the instruction, i.e., the instruction-2 according to the example shown in
Upon completing the execution of the instruction, the DMA 302 refers to an interrupt control flag of the present instruction and, if the interrupt control flag is set to Off, the DMA 302 carries out an interrupt to the CPU 303 for notifying the completion of the execution of the instruction. Then, it updates the instruction execution pointer and reads the next instruction. In the example of
Meanwhile, having received the notification of the execution completion from the DMA 302, the CPU 303 updates the instruction completion pointer, that is, increments it by one instruction and set to the address of the instruction-3.
If the interrupt control flag of the present instruction is set to On, the DMA 302 updates the instruction execution pointer and reads the next instruction without carrying out an interrupt to the CPU 303 (i.e., without notifying the CPU 303 of an completion of executing the instruction).
The DMA 302 carries out the process described above until the instruction execution pointer matches with an instruction end pointer.
The instruction 500 shown by
The command is a category of an instruction (i.e., processing content) such as READ and WRITE. The interrupt control flag set by the CPU 303 based on a load state of the CPU itself, and the like, is one for controlling interrupt processing performed on the CPU 303.
The present embodiment is configured to check a processing condition in a prescribed sampling interval (e.g., one millisecond), judge to be a Busy state if the CPU 303 is in a kind of processing for example, and an Idle state if it is not in processing. And the case of Busy state is counted (a count value in this event is named as “Busy count value”) so as to calculate a Busy ratio by the following expression:
(Busy ratio)=(Busy count value/Total sampling number)*100 (%)
If the Busy ratio exceeds a 70%, the load is judged to be high and the interrupt control flag is accordingly set to On. Note that the present embodiment is configured to use a 70% for the threshold value of the Busy ratio; it is of course discretionary, however, and an appropriate value may be set as a threshold value.
The data length indicates a size of data to be processed based on a command. The transfer origin address indicates a head address where data to be transferred is stored, and the transfer destination address indicates a head address for data to be transferred to and stored therein.
The DMA 302 changes over a method of interrupt processing on the CPU 303 based on a setting to On or Off of an interrupt control flag. That is, if the interrupt control flag is set to On, the delayed interrupt processing is performed, while if the interrupt control flag is set to Off, the instant interrupt processing is performed.
(1) If a load on the CPU 303 is large, the CPU 303 writes an instructional setting the interrupt control flag to On to the memory 304, and requests the DMA 302 for an execution.
(2) Having received the execution request from the CPU 303, the DMA 302 reads the instruction-1 from the memory 304 and executes the instruction. And, since the interrupt control flag of the present instruction is set to On, the DMA 302 refrains from carrying out interrupt processing on the CPU 303 until a certain time elapses after the instruction is executed, followed by carrying out interrupt processing on the CPU 303 after the certain time elapses, and notifying of the completion.
(3) If the load on the CPU 303 is small, the CPU 303 writes an instruction-2 setting the interrupt control flag to Off to the memory 304, and requests the DMA 302 for an execution.
(4) Having received the execution request from the CPU 303, the DMA 302 reads the instruction-2 from the memory 304 and executes the instruction. And, since the interrupt control flag of the present instruction is set to Off, the DMA 302 carries out interrupt processing on the CPU 303 immediately after the instruction is executed and notifies of the completion.
(5) Likewise the above paragraph (1), when the CPU 303 writes an instruction-3 setting the interrupt control flag to On to the memory 304 and requests the DMA 302 for an execution, the DMA 302 reads the instruction-3 from the memory 304 and executes the instruction. In this event, the interrupt control flag of the present instruction is set to On, the DMA 302 refrains from carrying out interrupt processing on the CPU 303 until a certain time elapses.
(6) Furthermore as the above paragraph (1), when the CPU 303 writes an instruction-4 setting the interrupt control flag to On to the memory 304 and requests the DMA 302 for an execution, the DMA 302 executes the instruction-4 without notifying of the completion of the instruction-3.
(7) The DMA 302 carries out interrupt processing on the CPU 303 after the certain time has elapsed and notifies of the completion of the instructions (i.e., the instructions-3 and -4) executed within the present certain time.
Having received a request for execution from the CPU 303, the instruction execution unit 302a shifts the process to the step S701 in which the instruction execution unit 302a reads an instruction execution pointer and an instruction end pointer from an internally comprised register for example. Then it compares the addresses of both of the pointers. If both pointers are identical as a result of the comparison, the instruction execution unit 302a judges that there is no instruction to be executed, and shifts the process to the step S701.
Contrarily, if both pointers are not identical as a result of comparison in the step S701, it judges that there is an instruction to be executed, and shifts the process to the step S702.
In the step S702, the instruction execution unit 302a reads an instruction from the address in the memory 304 indicated by the instruction execution pointer, followed by shifting the process to the step S703 and executing the present instruction.
Upon completing an execution of the instruction, the instruction execution unit 302a shifts the process to the step S704. And the instruction execution unit 302a increments the instruction execution pointer by only one (“1”) (i.e., by one instruction sentence).
Upon completion of the execution of one instruction by the above described process, the instruction execution unit 302a shifts the process to the step S705. It then requests the interrupt control unit 302b to carry out interrupt processing for notifying the CPU 303 of the completion,
Upon completion of the processes described above, the instruction execution unit 302a shifts the process to the step S701 and carries out the processes of the steps S701 through S705 until the execution of all instructions completes.
In the step S705 shown in
In the step S801, the interrupt control unit 302b checks an interrupt control flag of the instruction executed in the step S703 shown in
In the step S802, the interrupt control unit 302b reads a wait flag provided in a register or such (simply named as “wait flag” hereinafter) in the inside of the DMA 302, and check the wait flag. Note that the wait flag is one for indicating a presence or absence of a timer function, indicating that a timer is in activation if the wait flag is set to On.
If the wait flag is set to On in the step S802, the interrupt control unit 302b shifts the process to the step S806 and ends the process without carrying out interrupt processing.
Contrarily, if the wait flag is set to Off in the step S802, the interrupt control unit 302b shifts the process to the step S803. Then it sets the wait flag to On and activates a timer at the same time for shifting to a standby (i.e., a sleep) state for a certain time.
In this state, if the interrupt control unit 302b (i.e., a process) is further called up by the instruction execution unit 302a, the present interrupt control unit 302b shifts the process to the step S806 from the S802, and ends the process.
Upon returning from a standby state after a certain time elapses by means of the timer function, the interrupt control unit 302b shifts the process to the step S805, and carries out interrupt processing on the CPU 303 for a notification of a completion of the instruction, followed by shifting the process to the step S803 and ending the process.
Meanwhile, if the interrupt control flag indicates an Off in the step S801, the interrupt control unit 302b shifts the process to the step S804.
In the step S804, the interrupt control unit 302b reads the wait flag. If the wait flag is set to On, it turns Off the present wait flag and simultaneously cancels the timer, followed by shifting the process to the step S805.
In the step S805, the interrupt control unit 302b carries out interrupt processing on the CPU 303 for a notification of completing the instruction of the step S703 shown in
Here, the embodiment described above has described the case of applying the interrupt processing method of the present embodiment to the disk array control apparatus 100; the similar effect can be obtained, however, by an application to an apparatus using interrupt processing in the case of a CPU controlling a peripheral apparatus such as an information processing apparatus for example.
As described above, the disk array control apparatus 100 according to the present embodiment is configured such that the CPU 303 stores (i.e., sets) an interrupt processing method based on a load state of the CPU 302 itself as interrupt control information in the interrupt control information storage unit 104 and the DMA 302 carries out interrupt processing on the CPU 303 by using the interrupt processing method set up as the interrupt control information.
If a Busy ratio is low, setting the instant interrupt processing in the interrupt control information makes it possible to complete one I/O processing quickly, enabling an improvement of an I/O response.
Contrarily, if the Busy ratio is high, setting the delayed interrupt processing in the interrupt control information makes it possible to complete a plurality of interrupt processing within a single time of interrupt processing, thus reducing a load on the CPU 303 and improving the number of times of I/O processing in the CPU 303.
As a result, what is realized is a benefit of enabling an improvement in the performance of an I/O response and of the number of times of I/O processing at the same time.
Number | Date | Country | Kind |
---|---|---|---|
2006-263783 | Sep 2006 | JP | national |