English
Language : 

SII3124A Datasheet, PDF (46/88 Pages) Silicon image – PCI-X to Serial ATA Controller
PCI-X to Serial ATA Controller
Data Sheet
Silicon Image, Inc.
To recover from a Command Error condition, it is necessary to initialize the port by one of the Port Reset methods described in
section 5.4.2 Reset and Initialization. It might not be necessary to reset the device in all error cases. In fact, to properly
recover from native queued error conditions, it may be necessary to send additional commands to the device in error to obtain
additional error information. At the minimum, it will be necessary to assert a Port Initialize and wait for Port Ready before
additional commands may be issued.
Errors may be grouped into three categories to determine the proper recovery action:
• Recoverable errors. Error codes 1 and 2 are device specific errors. These errors occur when the device returns an
error bit in the final register FIS or in a Set Device Bits FIS. Depending upon the severity of the error type reported by
the device, it might not be necessary to reset the device. If the error code is 1, the register FIS received from the
device is available in the command slot PRB. The host may determine the error reported by the device by examining
the error register field of this structure. Please see section 5.4.13for more information regarding error recovery
procedures.
• Locally detected data errors. Error code 3 is a unique error type. It indicates that the SiI3124 detected an error
during command execution but the device failed to report the error upon command completion. For non-queued
commands, this error type may be treated the same as a recoverable error. If queued commands are outstanding,
the device must be reset since it is necessary to make sure that all queued commands are flushed from the device
upon an error condition. Since the device did not report an error, it is unlikely that the queue has been flushed in the
device.
• Fatal Errors. All other error codes indicate that an error condition has occurred that requires both the device and the
internal operational state of the SiI3124 to be reset. The most common method to perform this function is to issue a
Device Reset as described in section 5.4.2 Reset and Initialization.
5.4.13 Error recovery procedures
When a device returns error status for an outstanding command, the SiI3124 will halt command processing, post an error type
of 1 or 2 in the Port Command Error register, set the command error bit in the interrupt status register and, if enabled, assert
an interrupt to the host. The host driver may wish to attempt error recovery without resetting the device that issued the error.
Note that error recovery procedures should only be attempted for error types 1 and 2. Error type 3 is also recoverable if no
queued commands are outstanding. It is recommended that all other error types result in a reset of the affected device(s).
If the device in error is directly attached to the SiI3124 device port, the host may simply issue a Port Initialize by setting bit 2 in
the Port Control Set register and waiting for a Port Ready condition. The host may then re-issue any commands that were
outstanding when the error occurred. If native queued commands were outstanding, the host should issue a READ LOG
EXTENDED for Log Page 10h to determine the details of the error condition. Refer to the Serial ATA II specification for further
details on error handling with native queuing.
If the device in error is attached to a port multiplier, it is necessary for the host driver to wait until all outstanding commands to
other devices attached to the port multiplier have completed before issuing the Port Initialize function. This is accomplished
through a series of steps:
1. The host driver must note the PM port number for the device in error by extracting the PMP field (bit[8:5]) from the
Port Context Register (port offset 0x1e04). The PMP field contains the PM port number for the device in error. It is
then necessary to determine if any commands are outstanding for non-error devices. If there are no commands
outstanding for non-error devices, the host driver may simply proceed to step 4 to issue a Port Initialize and wait for a
Port Ready condition before reissuing commands.
2. If commands are outstanding to non-error devices, the host should set the Port Resume bit (bit 6) in the Port Control
Set Register. Setting this bit will cause the following actions:
a. Force a Device Busy condition for the currently selected PM port (the port to which the device in error is
attached) so that no additional issued commands will be sent to the device in error.
b. Continue processing of commands that have been issued.
3. The host driver must monitor command completion progress and determine when all commands for non-error devices
have completed. Please note that the Port Slot Status register will still have a bit set for each outstanding command
on the device in error. These bits will not be cleared and the host must ignore them while waiting for command
completion on non-error devices. If another recoverable error occurs while waiting for commands to complete, the
host driver must follow the same recovery steps for the new device in error, starting with step 1 above. It is possible
to have multiple devices in an error recovery state concurrently. When the host driver has detected that all
commands for non-error devices have completed, it must perform the following steps.
a. Clear Port Resume (Port Control Clear Register, Bit 6).
b. Clear bit[16:13] in the Port Device Status Register for the device(s) in error ((port*0x2000) + 0xf80 + (PM
port of device in error * 8)). This action clears the device_busy, native_queue, legacy_queue, and
service_pending bits to ready the device for further command processing.
© 2006 Silicon Image, Inc.
46
SiI-DS-0160-C