Revision history   OpenPOWER Library

 4.4.7.2. PSL Procedure for Time-Sliced and AFU-Directed Programming Models

Each PSL assigned to service the scheduled processes is configured with a unique identifier and the identifier of the next PSL in the list of PSLs servicing the processes. In addition, each PSL is identified as either the first PSL, the last PSL, both first and last PSL (only one PSL servicing the queue), or neither first or last PSL. The PSL ID Register contains the PSL unique identifier and the settings for first and last.

  Operations Performed by the First PSL (PSL_ID[L,F] = '01')

When the update_element MMIO command is received by the first PSL, the PSL checks to see if the process element being updated is currently running. It performs any operations necessary, and sends the update_element command to the next PSL.

  1. When operating in an AFU-directed programming model, the PSL notifies the AFU of the updated process element. The AFU performs any necessary operations to update the process and then acknowledges the updated process element. When the acknowledgment is received, the PSL continues with the next substep. The AFU is not notified of the updated process element for any other programming models.

  2. If the process is running, the PSL completes any outstanding transactions and does not start any new transactions for the process. The PSL then invalidates the process element state and refetches a new copy from the process element linked list in system memory. If the process element is coherently cached, the update is automatically handled by the coherency protocol.

    • The status field in sw_command_status is set to x'0006' using a caching-inhibited DMA or special memory-update operation that is guaranteed not to corrupt memory if the operation fails. The final value of sw_command_status should be (x'00060006' || first_psl_id || link_of_element_to_update).

    • The PSL does not start any process with a software state of complete, suspend, or terminate. A process element with the suspend flag set can be added to the PSL queue.

  3. If the process element is not running, the PSL writes an update command to the psl_chained_command doubleword for the next PSL.

    • Write the value (x'00060000' || next_psl_id || link_of_element_to_update) to the psl_chained_command.

    • The PSL does not start any process with a software state of complete, suspend, or terminate. A process element with the suspend flag set can be added to the PSL queue.

 Operations Performed by the Next PSL (PSL_ID[L,F] = '00')

When the update_element command is detected by the next PSL, the PSL checks to see if the process element being updated is currently running. It performs any operations necessary, and sends the terminate_element command to the next PSL or sets the completion status in the software command/status word. The update_element command is detected by monitoring the psl_chained_command doubleword.

  1. When operating in an AFU-directed programming model, the PSL notifies the AFU of the updated process element. The AFU performs any necessary operations to update the process and then acknowledges the updated process element. When the acknowledgment is received, the PSL continues with the next substep. The AFU is not notified of the updated process element for any other programming models.

  2. If the process is running, the PSL completes any outstanding transactions and does not start any new transactions for the process. The PSL then invalidates the process element state and refetches a new copy from the process element linked list in system memory. If the process element is coherently cached, the update is automatically handled by the coherency protocol.

    • The status field in sw_command_status is set to x'0006' using a caching-inhibited DMA or special memory-update operation that is guaranteed not to corrupt memory if the operation fails. The final value of sw_command_status should be (x'00060006' || first_psl_id || link_of_element_to_update).

    • The PSL does not start any process with a software state of complete, suspend, or terminate. A process element with the suspend flag set can be added to the PSL queue.

  3. If the process element is not running, the PSL writes a suspend command to the psl_chained_command doubleword for the next PSL.

    • Write the value (x'00060000' || next_psl_id || link_of_element_to_terminate) to the psl_chained_command.

    • The PSL does not start any process with a software state of complete, suspend, or terminate. A process element with the suspend flag set can be added to the PSL queue.

 Operations Performed by the Last PSL (PSL_ID[L] = '1')

When the update_element MMIO command is received or the update_element command is detected by the last PSL, the PSL checks to see if the process element being terminated is currently running. It performs any operations necessary, and sets the completion status in the software command/status word. The suspend_element command is detected by monitoring the psl_chained_command doubleword.

  1. When operating in an AFU-directed programming model, the PSL notifies the AFU of the updated process element. The AFU performs any necessary operations to update the process and then acknowledges the updated process element. When the acknowledgment is received, the PSL continues with the next substep. The AFU is not notified of the updated process element for any other programming models.

  2. If the process is running, the PSL completes any outstanding transactions and does not start any new transactions for the process. The PSL then invalidates the process element state and refetches a new copy from the process element linked list in system memory. If the process element is coherently cached, the update is automatically handled by the coherency protocol.

    • The PSL does not start any process with a software state of complete, suspend, or terminate. A process element with the suspend flag set can be added to the PSL queue.

  3. The PSL sets the completion status in the software command/status field to indicate the process has been successfully suspended.

    • The status field in sw_command_status is set to x'0006' using a caching-inhibited DMA or special memory-update operation that is guaranteed not to corrupt memory if the operation fails. The final value of sw_command_status should be (x'00060006' || first_psl_id || link_of_element_to_update).

    • The PSL does not start any process with a software state of complete, suspend, or terminate. A process element with the suspend flag set can be added to the PSL queue.


loading table of contents...